Post Reply 
 
Thread Rating:
  • 0 Votes - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
T_DRINKS fix
Author Message
kn4tseb
Master
**

Posts: 392
Likes Given: 45
Likes Received: 10 in 10 posts
Joined: May 2014
Reputation: 0



Post: #1
T_DRINKS fix
Well guys, most of you must know this but in case you dont i put it here..

when you drink a T_DRINK item the TDATA1 is created but it doesnt keep the MOREM of the first object... so if you drink a glass of water or a pitcher
when first time created it gets the MOREM set in the script file but when you dclick it and target it on a T_WATER_WASH to "fill it up" the new glass of water of pitcher will not have any MOREM so no "drinking" or "food" points are restored...

that would be it..
Thank you very much.

PD: i created a function to fix this but i think would be better if it's hardcoded in the future ^^
Thanks

PD2: i dont know if i should report it as a bug...

Regards.
(This post was last modified: 08-28-2014 06:15 AM by kn4tseb.)
08-28-2014 06:14 AM
Find all posts by this user Like Post Quote this message in a reply
Extreme
Grandmaster Poster
***

Posts: 1,140
Likes Given: 217
Likes Received: 89 in 76 posts
Joined: May 2012
Reputation: 20

SphereCommunity

Post: #2
RE: T_DRINKS fix
Hmm, I understand BUT you fixed it with a softcode and it is enough.
Many things sometimes can't be hardcoded because every scripter have your ideas and hardcoding it will force them to have limitations.

You can share your fix here Big Grin

STEPS BEFORE CREATE A THREAD
- Check the revisions log;
- Use the search button and use the keywords of your problem;
- Check the WIKI;
- Create a thread.
08-28-2014 07:08 AM
Find all posts by this user Like Post Quote this message in a reply
kn4tseb
Master
**

Posts: 392
Likes Given: 45
Likes Received: 10 in 10 posts
Joined: May 2014
Reputation: 0



Post: #3
RE: T_DRINKS fix
i just added a quick simply function for both items:
Code:
[ITEMDEF 09a7]
DEFNAME=i_pitcher_glass
BLA ...

ON=@Dclick
TARGETF TURNINGWATERPITCHER <UID>
RETURN 1

[FUNCTION TURNINGWATERPITCHER]
REF1 = <ARGO>
REF2 = <ARGS>
IF <REF1.TYPE> == T_WATER_WASH
SERV.NEWITEM i_pitcher_water
NEW.MOREM = 3
IF (<REF2.TOPOBJ.ISCONT>
NEW.BOUNCE
ELSE
NEW.P <REF2.P>
ENDIF
REF2.REMOVE
ENDIF

same for
[ITEMDEF 01f81]
DEFNAME=i_glass
(This post was last modified: 08-28-2014 12:00 PM by kn4tseb.)
08-28-2014 11:55 AM
Find all posts by this user Like Post Quote this message in a reply
[+] 1 user Likes kn4tseb's post
Post Reply 


Forum Jump:


User(s) browsing this thread: 1 Guest(s)