merlini Posted February 17, 2013 Group: Members Topic Count: 10 Topics Per Day: 0.00 Content Count: 26 Reputation: 0 Joined: 02/09/13 Last Seen: September 22, 2014 Share Posted February 17, 2013 - script PVPdropitem -1,{ OnPCDieEvent: setarray @PVPdropitem$[0],"Ws_town"; setarray @dropitem[0],2301; getmapxy(.@mapname$,.@mapx,.@mapy,0,strcharinfo(0)); for(set .@p,0; .@p<getarraysize(@PVPdropitem$); set .@p,.@p+1){ if( .@mapname$ == @PVPdropitem$[.@p] ){ end; } } makeitem @dropitem[rand(getarraysize(@dropitem))],1,.@mapname$,.@mapx,.@mapy; end; }I'm trying to make it so when player dies by Player, their equipment is dropped or random item from backpack. Quote Link to comment Share on other sites More sharing options...
Emistry Posted February 17, 2013 Group: Forum Moderator Topic Count: 93 Topics Per Day: 0.02 Content Count: 10018 Reputation: 2369 Joined: 10/28/11 Last Seen: Sunday at 05:32 PM Share Posted February 17, 2013 since it only happen during PK...why not try add this mapflag ? trunk/conf/mapflag/nightmare.txt //===== Description: ========================================= //= Players drop items/equipment on death. //= pvp_nightmaredrop id,type,percent //= id: Drop a specific item ID or "random" //= type: "inventory", "equip", or "all" //= percent: Rate of item drop. 1 Quote Link to comment Share on other sites More sharing options...
Capuche Posted February 17, 2013 Group: Developer Topic Count: 10 Topics Per Day: 0.00 Content Count: 2407 Reputation: 616 Joined: 07/05/12 Last Seen: March 20 Share Posted February 17, 2013 (edited) when player dies by Player pvp_nightmaredrop also works when kill by monster ( but a small edit in pc.c...) Edited February 17, 2013 by Capuche Quote Link to comment Share on other sites More sharing options...
merlini Posted February 18, 2013 Group: Members Topic Count: 10 Topics Per Day: 0.00 Content Count: 26 Reputation: 0 Joined: 02/09/13 Last Seen: September 22, 2014 Author Share Posted February 18, 2013 well, thats alot more easier/better Quote Link to comment Share on other sites More sharing options...
Question
merlini
OnPCDieEvent:
setarray @PVPdropitem$[0],"Ws_town";
setarray @dropitem[0],2301;
getmapxy(.@mapname$,.@mapx,.@mapy,0,strcharinfo(0));
for(set .@p,0; .@p<getarraysize(@PVPdropitem$); set .@p,.@p+1){
if( .@mapname$ == @PVPdropitem$[.@p] ){ end; }
}
makeitem @dropitem[rand(getarraysize(@dropitem))],1,.@mapname$,.@mapx,.@mapy;
end;
}
I'm trying to make it so when player dies by Player, their equipment is dropped or random item from backpack.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.