As title says, can someone convert this script to be compatible with Hercules. Thanks in advance.
It's an old eA script I dug up. It's GM Oceans script IIRC.
- script CDR -1,{ //whisper npc:CDR anything to activate the GM Menu,OnWhisperGlobal:if(getgmlevel() < 80){end;}menu "Add Monster to System",iAddMob,"Change Drop Rate",iChangeDrop,"Cancel",iCancel;iAddMob:if(getarraysize(.MobOkay_ID)>=128){next; mes "You cannot add any more mobs to this system."; close;}next;mes "Please input the Monster ID you wish to add to this system";input .@id;next;mes "Are you sure you want to add: "+strmobinfo(1,.@id)+" to the system?";menu "Yes",-,"Input new ID",iAddMob,"Cancel",iCancel;set .MobOkay_ID[getarraysize(.MobOkay_ID)+1],.@id;next;mes "The Monster: "+strmobinfo(1,.@id)+" has been added to the system.";close;iChangeDrop:next;mes "Current Drop Rate: "+100/.MaxDropChance+"%";mes "Please input the new drop rate.";mes "*Note - Drop rate is determined by: 100/DropRate %*";mes "1 = 100%, 10 = 10%, 100 = 1%, 1000 = 0.1%, 10000 = 0.01%";input .@newdropchance;if(.@newdropchance <= 0){next; mes "Invalid Number"; close;}set .MaxDropChance,.@newdropchance;next;mes "Drop Rate has been changed.";mes "Current Drop Rate: "+100/.MaxDropChance+"%";close;OnInterIfInitOnce:setarray .MobOkay_ID[0],1002,1004,1005,1007,1008,1009,1010; //Replace XXXX with the ID's of the monsters you want to be affected by this script. Add more as necessariy. *Note only supports 128 different monsters*set .MaxDropChance,10; // 1 = 100% | 10 = 10% | 100 = 1% | 1000 = 0.1% | 10000 = 0.01% Basically, 100/.MaxDropChance = %end;OnNPCKillEvent:for(set @i,0; @i<getarraysize(.MobOkay_ID); set @i,@i+1){if (killedrid==.MobOkay_ID[@i]){goto iDropItemRate;}}end;iCancel:close;iDropItemRate:set @i,0;set @dropID,0;deletearray $@MobDrop_item[0],128;deletearray $@MobDrop_rate[0],128;set $@MobDrop_count,0;getmobdrops(killedrid);set .@MobDrop_count, $@MobDrop_count;copyarray .@MobDrop_item[0],$@MobDrop_item[0],.@MobDrop_count;copyarray .@MobDrop_rate[0],$@MobDrop_rate[0],.@MobDrop_count;goto iDropItemLoop;iDropItemLoop:set @i,rand(1,.MaxDropChance);if (@dropID == .@MobDrop_count){dispbottom "Success"; end;}if (@i==1 && .@MobDrop_rate[@dropID]<=1){getitem .@MobDrop_item[@dropID],1; if(@dropID==8){announce "[ "+strcharinfo(0)+" ]: got [ "+getitemname(.@MobDrop_item[@dropID])+" ] ( Chance: "+ (.MaxDropChance?"100%":"10%":"1%":"0.1%"|"0.01%") +" )",bc_all;} set @dropID,@dropID+1; goto iDropItemLoop;}if (@i<=.@MaxDropChance){set @dropID,@dropID+1; goto iDropItemLoop;}end;}
As title says, can someone convert this script to be compatible with Hercules. Thanks in advance.
It's an old eA script I dug up. It's GM Oceans script IIRC.
Share this post
Link to post
Share on other sites