PewN Posted January 15, 2012 Posted January 15, 2012 can anyone give me a script in pvp when u die u will go @alive and when u kill u will get cash points Quote
goddameit Posted January 19, 2012 Posted January 19, 2012 (edited) @Emistry and for OnPCKillEvent i not sure on this...what would happen if a players use self-damaging skills like Grand Cross ? I was killed by myself. so killedrid = killerrid = me - script PvPCasher -1,{ end; OnPCKillEvent: dispbottom "OnPCKillEvent:"+killedrid; end; OnPCDieEvent: dispbottom "OnPCDieEvent:"+killerrid; end; } http://i.imgur.com/EkS9v.jpg >> OnPCKillEvent: if(killedrid==getcharid(3)||!killedrid)end; set #CASHPOINTS,#CASHPOINTS + 2; dispbottom "You have recieved 2 Cash Points for killing "+rid2name(killedrid)+"."; dispbottom "Your Balance is now: "+#CASHPOINTS; set killedrid,0; end; Edited January 19, 2012 by goddameit Quote
llchrisll Posted January 15, 2012 Posted January 15, 2012 Something like this? - script PvPCasher -1,{ end; OnPCKillEvent: set #CASHPOINTS,#CASHPOINTS + 2; dispbottom "You have recieved 2 Cash Points for killing "+rid2name(killedrid)+"."; dispbottom "Your Balance is now: "+#CASHPOINTS; end; OnPCDieEvent: sleep2 1300; if(killerrid != getcharid(3)) { warp strcharinfo(3),0,0; if(HP == 0) atcommand "@alive"; percentheal 100,100; } else warp "SavePoint",0,0; end; } Change the amount of Cash Points after the "OnPCKillEvent" and also in the text . Untested btw. Regards, Chris Quote
Emistry Posted January 16, 2012 Posted January 16, 2012 i guess you should add in the map checking inside the script for the OnPCDieEvent part.... otherwise the player will using the @alive command upon killed by Monster and for OnPCKillEvent i not sure on this...what would happen if a players use self-damaging skills like Grand Cross ? they could kill them self right ? perhap they might get the Cash Point also ? erm..if those above situation does exist..then you should add in more condition checking.. like check whether the killed users is the Killer Himself and check for is they inside the PVP map... Quote
Arcenciel Posted January 16, 2012 Posted January 16, 2012 Also there's a problem where after a certain time, you'd be ported out of the PvP room automatically. Quote
llchrisll Posted January 16, 2012 Posted January 16, 2012 OnPCKillEvent: As far as I understand the text in the script_commands.txt this event will only execute when an player kills an other player. As for the OnPCDIeEvent Map Check Mapflag check would be possible ^^. if(getmapflag(strcharinfo(0),mf_pvp) == 0) end; @Arcenciel: I know about that, but as far as I have tested that, as long as the "sleep2" is not too long, you won't be warped outside which would happen after you get killed 3 times ^^. If I'm wrong with that, then I need to find a another way . Regards, Chris Quote
Emistry Posted January 17, 2012 Posted January 17, 2012 remove this /src/map/pc.c if( sd->pvp_point < 0 ) { add_timer(tick+1000, pc_respawn_timer,sd->bl.id,0); return 1|8; } then the auto respawn i guess it should be disabled by now... Quote
Ice Bear Posted January 22, 2012 Posted January 22, 2012 Maybe This Helps Need an Item for Resurection - script Reviver -1,{ OnUsed: menu "Resurection",Resu,"Cancel",Canceled; Resu: sleep2 200; atcommand "@alive"; close; Canceled: message strcharinfo(0),"Ok Your Choice Master."; getitem 501,1; //501 = red potion just test//Set ITEM ID for your Resurection Script close; } - script Revived -1,{ end; OnPCDieEvent: if(countitem(501)<1) goto L_DHAVE; // ITEM CHECK IF HAVE TOKEN if( strcharinfo(3) == "prontera" ) { // MAP DISABALER message strcharinfo(0),"Cant Use In PVP MAPS"; close; } doevent "Reviver::OnUsed"; goto D_eleter; close; D_eleter: message strcharinfo(0),"Resurection Stone Used"; delitem 501,1; //501 = red potion just test//Set ITEM ID for your Resurection Script close; L_DHAVE: message strcharinfo(0),"You Dont Have Resurection Stone."; close; } Quote
Question
PewN
can anyone give me a script in pvp when u die u will go @alive and when u kill u will get cash points
7 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.