![]() |
HELP WITH sphere.ini - Printable Version +- SphereCommunity (https://forum.spherecommunity.net) +-- Forum: Sphere 0.56d (/Forum-Sphere-0-56d) +--- Forum: General Help (/Forum-General-Help) +--- Thread: HELP WITH sphere.ini (/Thread-HELP-WITH-sphere-ini) |
RE: HELP WITH sphere.ini - amonvangrell - 05-27-2014 07:27 AM Code: [function f_isitem] RE: HELP WITH sphere.ini - Extreme - 05-27-2014 07:38 AM (05-27-2014 07:11 AM)kn4tseb Wrote: Last question What? Sorry, I didn't understand. RE: HELP WITH sphere.ini - kn4tseb - 05-27-2014 11:02 AM it works fine when i set it for an item, but i must do this this for several items and i'd like to make some kind of event checking <durability> and setting the value instead doing this for every single item. PD: im asking this because if i put the code at the tooltip events or equipitem event, hitpoints are increased everytime i pick an item with <durability> iam really sorry about this newbie questions, im a begginer and im studing the tutorials RE: HELP WITH sphere.ini - Extreme - 05-27-2014 01:49 PM First create your item event (e_events_item for example) Set it on sphere.ini and test if it will apply the bonus [EVENTS E_EVENTS_ITEM] ON=@CREATE IF <DURABILITY> MAXHITS += <EVAL (<DURABILITY>*<MAXHITS>)/100> HITS <MAXHITS> ENDIF RE: HELP WITH sphere.ini - kn4tseb - 05-27-2014 02:16 PM Didnt work ![]() added the event into a new file... then added the name of event to sphere.ini file at EventsItem= but nothing happened :/ when item is created it doesnt get the bonus. RE: HELP WITH sphere.ini - Extreme - 05-28-2014 01:09 AM What sphere build are you using? Lastest versions? RE: HELP WITH sphere.ini - kn4tseb - 05-28-2014 01:19 AM may 22th nightly Sphere Version 0.56c-Nightly [WIN32] by http://www.spherecommunity.net, compiled at May 22 2014 (00:05:19), internal build #1935 this is an example for a working durability bonus: PHP Code: [ITEMDEF i_DULL_COPPER_PLATEMAIL_CHEST] But as you know i dont want to have to add it everytime an item has durability bonus, so i tried with the event but nothing happens ![]() and if i add it to other events it works but everytime i pick up the item it gets the bonus over and over again. RE: HELP WITH sphere.ini - Extreme - 05-28-2014 02:04 AM Alright, it SHOULD be working. It's not here too. Do this: in your player events, in @itempick_up, make it check about durability. If it has, apply the bonus and SET the durability 0 in the item. It will prevent apply again. This is not the best way, since @create in eventsitem had to work. RE: HELP WITH sphere.ini - XuN - 05-28-2014 02:08 AM Wait until tomorrow's build, I did not apply the same changes for items than for characters when using events for the @Create trigger. RE: HELP WITH sphere.ini - kn4tseb - 05-28-2014 03:37 AM Okey, thank you both, i will wait ^^ |