![]() |
|
Extra gold killings mobs - Printable Version +- SphereCommunity (https://forum.spherecommunity.net) +-- Forum: Sphere 0.56d (/Forum-Sphere-0-56d) +--- Forum: Script Help (/Forum-Script-Help) +--- Thread: Extra gold killings mobs (/Thread-Extra-gold-killings-mobs) |
Extra gold killings mobs - Van Glan Bloom - 06-30-2013 10:54 AM Hi guys, I need your help with this script: [ITEMDEF i_arken_talisman] Defname=i_arken_talisman ID=i_talisman4 Name=Arken talisman type=t_jewelry Tevents=t_arken Tevents=t_luck_item tag.luck=100 ON=@EQUIP IF (<src.findlayer.9.baseid>==i_arken_talisman) src.events=+e_more_money else Return 0 endif ON=@UNEQUIP src.events=-e_more_money [Events e_more_money] ON=@kill if (<act.isplayer>) obj=<argo.uid> if (<obj.isevent.e_exp>) local.new=<new> serv.newitem i_gold,{1000 2000} bounce <new> new=<local.new> return 1 endif endif The script serve as the player kill a mob, this drop extra gold. When I kill the mob with him GM drop the gold, but when you kill the player nothing happens. Can you help? RE: Extra gold killings mobs - RanXerox - 07-01-2013 02:58 AM Look at the wiki page for @Kill http://wiki.sphere.torfo.org/index.php/@Kill ... There is no ACT reference explicitly set in that trigger. The reason it works for your GM, but not your players is coincidental. Also, "saving" NEW in a LOCAL variable should not be necessary... however, failing to save OBJ, may cause you problems later since OBJ is a global reference. Why even use OBJ? My suggestion is to never use it. Lastly, using RETURN 1 in @Kill prevents the killer from receiving credit for the kill... do you really want that? Here is a simpler alternative: Code: [Events e_more_money]RE: Extra gold killings mobs - Mordaunt - 07-01-2013 06:46 AM I could have sworn I answered this one last night... |