nikita54421 Posted April 22, 2018 Posted April 22, 2018 Hello, friends! Where can I find an open pvp script behind cities at a specific time here? For example, pvp only works at night, at all locations except cities The search did not help me! Thank you Quote
1 pajodex Posted April 22, 2018 Posted April 22, 2018 1 hour ago, nikita54421 said: Hello, friends! Where can I find an open pvp script behind cities at a specific time here? For example, pvp only works at night, at all locations except cities The search did not help me! Thank you https://github.com/rathena/rathena/blob/master/conf/battle/misc.conf // PK Server Mode. Turns entire server pvp(excluding towns). Experience loss is doubled if killed by another player. // When players hunt monsters over 20 levels higher, they will receive 15% additional exp., and 25% chance of receiving more items. // There is a nopvp.txt for setting up maps not to have pk on in this mode. Novices cannot be attacked and cannot attack. // Normal pvp counter and rank display are disabled as well. // Note: If pk_mode is set to 2 instead of 1 (yes), players will receive a // manner penalty of 5 each time they kill another player (see manner_system // config to adjust how this will affect players) pk_mode: 0 1 Quote
0 pajodex Posted April 22, 2018 Posted April 22, 2018 (edited) To add up because I didn't read your post carefully: (not tested) - script nighttime#pvp -1,{ OnInit: if(isnight()) setBattleFlag "pk_mode",1,true; else if (isday()) setBattleFlag "pk_mode",0,true; end; } @nikita54421 Edited April 22, 2018 by pajodex 1 Quote
0 nikita54421 Posted April 22, 2018 Author Posted April 22, 2018 3 minutes ago, pajodex said: To add up because I didn't read your post carefully: (not tested) - script nighttime#pvp -1,{ OnInit: if(isnight()) setBattleFlag "pk_mode",1,true; else if (isday()) setBattleFlag "pk_mode",0,true; end; } @nikita54421 Thank you so much! It helped me Quote
0 llchrisll Posted April 22, 2018 Posted April 22, 2018 You should also move these lines on the day/night script. Without it it will only set's the pk when the server starts or at @reloadscript. Regards, Chris 2 Quote
0 pajodex Posted April 22, 2018 Posted April 22, 2018 @llchrisll is right.. I just made the code right away without thinking xd. As long as you get the main point @nikita54421 Quote
Question
nikita54421
Hello, friends!
Where can I find an open pvp script behind cities at a specific time here?
For example, pvp only works at night, at all locations except cities
The search did not help me!
Thank you
5 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.