Larian Banner: Baldur's Gate Patch 9
Previous Thread
Next Thread
Print Thread
#559294 29/11/14 09:46 PM
Joined: Oct 2014
B
Burgee Offline OP
enthusiast
OP Offline
enthusiast
B
Joined: Oct 2014
Need some help with this one.

Trying to be able to check whether a player uses an item type - for instance - an Apple. I don't want a check for every single apple on the map, but instead I want to check if a player uses ANY apple.

I think the call I need is

CharacterUsedItemTemplate(CHARACTER_character, STRING_template, INTEGER_ItemHandle), but I don't understand the arguments it's looking for because I can't get it to work. I'm using it like this:

IF
CharacterUsedItemTemplate(CHARACTER_Player1,"CON_Food_Apple_A",_)
THEN
CharacterDisplayText(CHARACTER_Player1,"Eat");

Nothing happens.

If I check for the SPECIFIC apple being eaten (CharacterUsedItem), the script works. What am I doing wrong?

Last edited by Burgee; 29/11/14 09:47 PM.
Joined: Oct 2014
B
Burgee Offline OP
enthusiast
OP Offline
enthusiast
B
Joined: Oct 2014
Nevermind, figured it out.

Needed to get into LStools and open the items.lsb file in the game/global folder and find the template of the apple item in there.


Link Copied to Clipboard
Powered by UBB.threads™ PHP Forum Software 7.7.5