Jump to content
  • 0

Ghost PVP Ladder GM Reset.


Question

Posted

Hi guys can you help me make a GM Reset menu of this ladder? I want a gm level 99 can globally reset all the records. i try it using the sql query, deleting all the fields in the table but the problem is when the players kills again, it continues the last records he got. i also tried deleting the fields and restart the server, but still the same. Thank you in advance.

5 answers to this question

Recommended Posts

  • 0
Posted
On 2/16/2013 at 6:48 PM, Unholy Touch said:

Actually Empty the pvp_rank table wont solve the issue, because Ghost uses a variable global variable, which can be reset by assigning another value which in my case set it to 0. I just made a script in which when the player login his/her statistics in ladder will be reset to 0.


 


-    script    Playerresetladder_Login    -1,{
OnPCLoginEvent:
if(chkifresetladder >= 1) goto chk_kungtaposna;
query_sql "DELETE FROM `pvp_rank` WHERE `pvp_rank`.`char_id` = "+getcharid(0)+"";
callsub OnPvPReset;
set chkifresetladder,1;
end;
OnPvPReset:
set Kill, 0;
set Death, 0;
set KillingStreak, 0; 
set MultiKill, 0;
set KillingSpree, 0;
set Dominating, 0;
set MegaKill, 0;
set Unstoppable, 0;
set WickedSick, 0;
set MonsterKill, 0;
set Godlike, 0;
set BeyondGodlike, 0;
set DoubleKill, 0;
set TripleKill, 0;
set UltraKill, 0;
set Rampage, 0;
set Ownage, 0;
set NemesisKill, 0;
set FeedCount, 0;
return;
chk_kungtaposna:
end;
}

 


im not really good at scripting so in my case i need to use another variable for "chkifresetladder" every month. thank you.

is it possible to make a npc where gm can click and it reset this table, i try manually but this sql require char id i want reset for all, plus i have use for first time. So it wont reset again for the 2nd time

Posted

you are asking others to create a new ladder script for you ? or modify your current ladder script ?

if you are requesting a new ladder...then make it in details..

else...show your scripts...

Posted (edited)

create a gm menu

create an option for you to reset the ladder

TRUNCATE TABLE `pvp_rank`

since ghost's pvp system uses `pvp_rank` table in your database you just only need to empty the table

Edited by icabit
Posted (edited)

Actually Empty the pvp_rank table wont solve the issue, because Ghost uses a variable global variable, which can be reset by assigning another value which in my case set it to 0. I just made a script in which when the player login his/her statistics in ladder will be reset to 0.


 

-    script    Playerresetladder_Login    -1,{
OnPCLoginEvent:
if(chkifresetladder >= 1) goto chk_kungtaposna;
query_sql "DELETE FROM `pvp_rank` WHERE `pvp_rank`.`char_id` = "+getcharid(0)+"";
callsub OnPvPReset;
set chkifresetladder,1;
end;
OnPvPReset:
set Kill, 0;
set Death, 0;
set KillingStreak, 0; 
set MultiKill, 0;
set KillingSpree, 0;
set Dominating, 0;
set MegaKill, 0;
set Unstoppable, 0;
set WickedSick, 0;
set MonsterKill, 0;
set Godlike, 0;
set BeyondGodlike, 0;
set DoubleKill, 0;
set TripleKill, 0;
set UltraKill, 0;
set Rampage, 0;
set Ownage, 0;
set NemesisKill, 0;
set FeedCount, 0;
return;
chk_kungtaposna:
end;
}

 


im not really good at scripting so in my case i need to use another variable for "chkifresetladder" every month. thank you.
Edited by Capuche
Insert the script in Code
  • Like 1

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Answer this question...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...