PewN Posted January 15, 2012 Group: Members Topic Count: 209 Topics Per Day: 0.04 Content Count: 892 Reputation: 27 Joined: 12/09/11 Last Seen: April 16, 2016 Share 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 Link to comment Share on other sites More sharing options...
goddameit Posted January 19, 2012 Group: Members Topic Count: 60 Topics Per Day: 0.01 Content Count: 562 Reputation: 219 Joined: 11/22/11 Last Seen: August 3, 2024 Share 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 Link to comment Share on other sites More sharing options...
llchrisll Posted January 15, 2012 Group: Members Topic Count: 12 Topics Per Day: 0.00 Content Count: 626 Reputation: 189 Joined: 11/19/11 Last Seen: March 25 Share 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 Link to comment Share on other sites More sharing options...
Emistry Posted January 16, 2012 Group: Forum Moderator Topic Count: 93 Topics Per Day: 0.02 Content Count: 10017 Reputation: 2369 Joined: 10/28/11 Last Seen: 2 hours ago Share 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 Link to comment Share on other sites More sharing options...
Arcenciel Posted January 16, 2012 Group: Members Topic Count: 69 Topics Per Day: 0.01 Content Count: 1315 Reputation: 372 Joined: 12/10/11 Last Seen: August 31, 2013 Share 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 Link to comment Share on other sites More sharing options...
llchrisll Posted January 16, 2012 Group: Members Topic Count: 12 Topics Per Day: 0.00 Content Count: 626 Reputation: 189 Joined: 11/19/11 Last Seen: March 25 Share 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 Link to comment Share on other sites More sharing options...
Emistry Posted January 17, 2012 Group: Forum Moderator Topic Count: 93 Topics Per Day: 0.02 Content Count: 10017 Reputation: 2369 Joined: 10/28/11 Last Seen: 2 hours ago Share 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 Link to comment Share on other sites More sharing options...
Ice Bear Posted January 22, 2012 Group: Members Topic Count: 27 Topics Per Day: 0.01 Content Count: 166 Reputation: 27 Joined: 11/20/11 Last Seen: Tuesday at 12:35 AM Share 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 Link to comment Share on other sites More sharing options...
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
Link to comment
Share on other sites
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.