vijay30393 Posted June 27, 2015 Share Posted June 27, 2015 25620,Royal_Scythe,Royal_Scythe,4,1,5000000,5,1,1, 1,4,0x00000100,6,2,2,4,100,1,8,{bonus bStr,10+(@kill*7);bonus bAllStats,1+(@kill);bonus2 bIgnoreDefRate,RC_DemiHuman,[email protected];},{dispbottom "[Royal Weapon] Your power is strong. Power:"[email protected];misceffect 182;misceffect 190;specialeffect2 543;},{} weapons will have a progressive script. Each Player kill will boost your weapon damage and stats. If you die, you lose half of the stacked kills and power. The weapon can stacked up to 10 kills for Max Power. Stats should be- Dex/Str/Int = 30+(kills*5) allstats = 1+(kills) demihuman damage = 3+kill At max power: 30+(10*5) = 80 dex or str or int allstats 1+10 = 11 Demihuman Damage 20+10 = 30 There are 14 different weapons, i just added 1 above.But its not working like the script says.Could you guys help me fix it?Thanks~ Quote Link to comment Share on other sites More sharing options...
Sneaky Posted July 1, 2015 Share Posted July 1, 2015 if(isequipped) and you should also put if(isequipped) everytime you're making a comparison. - script RoyalWeapon -1,{ OnPCKillEvent: if(isequipped(25621) || isequipped(25622) || isequipped(25623) || isequipped(25624) || isequipped(25625) || isequipped(25626) || isequipped(25627) || isequipped(25628) || isequipped(25629) || isequipped(25630) || isequipped(25631) || isequipped(25632) || isequipped(25633)) { if ( @kill < 10 ) { set @kill,@kill + 1; message strcharinfo(0),"You got "[email protected]+" Kills"; } } end; OnPCDieEvent: if(isequipped(25621) || isequipped(25622) || isequipped(25623) || isequipped(25624) || isequipped(25625) || isequipped(25626) || isequipped(25627) || isequipped(25628) || isequipped(25629) || isequipped(25630) || isequipped(25631) || isequipped(25632) || isequipped(25633)) { if ( @kill > 0 ) { set @kill, @kill/2; message strcharinfo(0),"You got "[email protected]+" Kills"; } } end; } Quote Link to comment Share on other sites More sharing options...
Emistry Posted June 27, 2015 Share Posted June 27, 2015 that's because you didnt have any npc script that will update the @kill variable. Quote Link to comment Share on other sites More sharing options...
vijay30393 Posted June 27, 2015 Author Share Posted June 27, 2015 Can you help me with that emistry? Quote Link to comment Share on other sites More sharing options...
Emistry Posted June 27, 2015 Share Posted June 27, 2015 OnPCKillEvent: if ( @kill < 10 ) @kill++; end; OnPCDieEvent: if ( @kill > 0 ) { @kill--; } end; Quote Link to comment Share on other sites More sharing options...
vijay30393 Posted June 27, 2015 Author Share Posted June 27, 2015 https://fbcdn-sphotos-h-a.akamaihd.net/hphotos-ak-xpf1/v/t34.0-12/11655203_909653139100680_76983650_n.jpg?oh=5436eca6336af4a121d3e92af9eaaa45&oe=5590942A&__gda__=1435616439_72f17c56b7b420c77eb388fda580e612Error emistry.I'm using 3CeAm btw. Quote Link to comment Share on other sites More sharing options...
Emistry Posted June 27, 2015 Share Posted June 27, 2015 https://rathena.org/board/topic/78263-scripting-faqtipstricks/?p=267219 Quote Link to comment Share on other sites More sharing options...
vijay30393 Posted June 29, 2015 Author Share Posted June 29, 2015 (edited) Script has been fixed but Still the stats is not changing in game @emistry! - script RoyalWeapon -1,{ OnPCKillEvent: if ( @kill < 10 ){ set [email protected],[email protected] + 1; } end; OnPCDieEvent: if ( @kill > 0 ) { set [email protected],[email protected] - 1; } end; } Dump anyone!Dump~ Need help! Edited June 28, 2015 by Emistry Quote Link to comment Share on other sites More sharing options...
Emistry Posted June 29, 2015 Share Posted June 29, 2015 you are using wrong type of variable .... your variable doesnt persist after script executed. Quote Link to comment Share on other sites More sharing options...
vijay30393 Posted June 29, 2015 Author Share Posted June 29, 2015 (edited) Fixed it! - script RoyalWeapon -1,{ end; OnPCKillEvent: if ( @kill < 10 ) { set @kill,@kill + 1; message strcharinfo(0),"You got "[email protected]+" Kills"; } end; OnPCDieEvent: if ( @kill > 0 ) { set @kill,@kill - 5; message strcharinfo(0),"You got "[email protected]+" Kills"; } end; } Edited June 29, 2015 by Emistry codebox Quote Link to comment Share on other sites More sharing options...
vijay30393 Posted July 1, 2015 Author Share Posted July 1, 2015 (edited) Still little problem. - script RoyalWeapon -1,{ OnPCKillEvent: if(isequipped(25620) && if(isequipped(25621) && if(isequipped(25622) && if(isequipped(25623) && if(isequipped(25624) && if(isequipped(25625) && if(isequipped(25626) && if(isequipped(25627) && if(isequipped(25628) && if(isequipped(25629) && if(isequipped(25630) && if(isequipped(25631) && if(isequipped(25632) && if(isequipped(25633)) { if ( @kill < 10 ) { set @kill,@kill + 1; message strcharinfo(0),"You got "[email protected]+" Kills"; } end; } OnPCDieEvent: if(isequipped(25620) && if(isequipped(25621) && if(isequipped(25622) && if(isequipped(25623) && if(isequipped(25624) && if(isequipped(25625) && if(isequipped(25626) && if(isequipped(25627) && if(isequipped(25628) && if(isequipped(25629) && if(isequipped(25630) && if(isequipped(25631) && if(isequipped(25632) && if(isequipped(25633)) { if ( @kill > 0 ) { set @kill, @kill/2; message strcharinfo(0),"You got "[email protected]+" Kills"; } end; } } Isequipped is not working. if anyone of those items are equipped, the script must pass to @set if not end;How can i fix it? any help is appreciated Edited July 1, 2015 by Emistry codebox. Quote Link to comment Share on other sites More sharing options...
Emistry Posted July 1, 2015 Share Posted July 1, 2015 replace && with || instead. Quote Link to comment Share on other sites More sharing options...
vijay30393 Posted July 1, 2015 Author Share Posted July 1, 2015 I did try that but it errors. Quote Link to comment Share on other sites More sharing options...
Emistry Posted July 1, 2015 Share Posted July 1, 2015 if ( A || B || C || D || E ) { /// script..... /// script..... } Quote Link to comment Share on other sites More sharing options...
vijay30393 Posted July 1, 2015 Author Share Posted July 1, 2015 (edited) It is not erroring but the scipt is not working. - script RoyalWeapon -1,{ OnPCKillEvent: if(isequipped(25621) || (25622) || (25623) || (25624) || (25625) || (25626) || (25627) || (25628) || (25629) || (25630) || (25631) || (25632) || (25633)) { if ( @kill < 10 ) { set @kill,@kill + 1; message strcharinfo(0),"You got "[email protected]+" Kills"; } end; } OnPCDieEvent: if(isequipped(25621) || (25622) || (25623) || (25624) || (25625) || (25626) || (25627) || (25628) || (25629) || (25630) || (25631) || (25632) || (25633)) { if ( @kill > 0 ) { set @kill, @kill/2; message strcharinfo(0),"You got "[email protected]+" Kills"; } } end; } I'm getting kills even when im not using those or any other items.I should only be getting @kill when im using any of those items. Edited July 1, 2015 by Emistry Please use CODEBOX. Quote Link to comment Share on other sites More sharing options...
25620,Royal_Scythe,Royal_Scythe,4,1,5000000,5,1,1, 1,4,0x00000100,6,2,2,4,100,1,8,{bonus bStr,10+(@kill*7);bonus bAllStats,1+(@kill);bonus2 bIgnoreDefRate,RC_DemiHuman,[email protected];},{dispbottom "[Royal Weapon] Your power is strong. Power:"[email protected];misceffect 182;misceffect 190;specialeffect2 543;},{}
But its not working like the script says.
Could you guys help me fix it?
Thanks~
Link to comment
Share on other sites