Sallycantdance Posted April 13, 2021 Group: Members Topic Count: 224 Topics Per Day: 0.14 Content Count: 796 Reputation: 12 Joined: 12/04/20 Last Seen: Saturday at 01:08 PM Share Posted April 13, 2021 Goodmorning guys i would to ask how to put limit in this pvp script so it wont be abuse by players heres the script: - script asdahjhla -1,{ OnPCKillEvent: if ( inarray(.map$, strcharinfo(3)) != -1 ) { if ( rand(100) <= .chance && killedrid != getcharid(3) ) { getitem 7960, 1; } } end; OnInit: .chance = 100; // chance to get something setarray .map$, "pvp_y_1-2"; // map list } Thanks in advance Quote Link to comment Share on other sites More sharing options...
0 buraquera Posted April 18, 2021 Group: Members Topic Count: 3 Topics Per Day: 0.00 Content Count: 68 Reputation: 8 Joined: 05/12/20 Last Seen: 6 hours ago Share Posted April 18, 2021 (edited) On 4/15/2021 at 10:11 PM, chadness said: example i will make the chance 100% sure then they only can get 20 coins per day There same ways of doing this. try this - script asdahjhla -1,{ OnPCKillEvent: if (countinarray(.map$,strcharinfo(3)) && $pkscore[getcharid(0)] < 21 && rand(100) <= .chance && killedrid != getcharid(3)){ getitem 7960, 1; $pkscore[getcharid(0)]++; } end; OnInit: .chance = 100; // chance to get something setarray .map$, "pvp_y_1-2"; // map list end; OnHour00: deletearray($pkscore); end; } Edited April 18, 2021 by buraquera 1 Quote Link to comment Share on other sites More sharing options...
0 buraquera Posted April 16, 2021 Group: Members Topic Count: 3 Topics Per Day: 0.00 Content Count: 68 Reputation: 8 Joined: 05/12/20 Last Seen: 6 hours ago Share Posted April 16, 2021 Specify what you want to limit ...?It may be a delay, or if the dead player is the same as last time ...... Quote Link to comment Share on other sites More sharing options...
0 Sallycantdance Posted April 16, 2021 Group: Members Topic Count: 224 Topics Per Day: 0.14 Content Count: 796 Reputation: 12 Joined: 12/04/20 Last Seen: Saturday at 01:08 PM Author Share Posted April 16, 2021 On 4/16/2021 at 8:11 AM, buraquera said: Specify what you want to limit ...?It may be a delay, or if the dead player is the same as last time ...... example i will make the chance 100% sure then they only can get 20 coins per day On 4/18/2021 at 11:52 PM, buraquera said: There same ways of doing this. try this - script asdahjhla -1,{ OnPCKillEvent: if (countinarray(.map$,strcharinfo(3)) && $pkscore[getcharid(0)] < 21 && rand(100) <= .chance && killedrid != getcharid(3)){ getitem 7960, 1; $pkscore[getcharid(0)]++; } end; OnInit: .chance = 100; // chance to get something setarray .map$, "pvp_y_1-2"; // map list end; OnHour00: deletearray($pkscore); end; } thank you i will try it later Quote Link to comment Share on other sites More sharing options...
Question
Sallycantdance
Goodmorning guys i would to ask how to put limit in this pvp script so it wont be abuse by players
heres the script:
- script asdahjhla -1,{
OnPCKillEvent:
if ( inarray(.map$, strcharinfo(3)) != -1 ) {
if ( rand(100) <= .chance && killedrid != getcharid(3) ) {
getitem 7960, 1;
}
}
end;
OnInit:
.chance = 100; // chance to get something
setarray .map$, "pvp_y_1-2"; // map list
}
Thanks in advance
Link to comment
Share on other sites
3 answers to this question
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.