The item doesn't destroy itself if you don't want it to.
If you want it to destroy itself upon use, you would set it to have exactly one charge and then set the 'when drained' parameter to 'item vanishes'. Set it to item remains or anything else and the item stays.
Anyway, checking for the item is obviously an inferior way, at least if there is even the slightest chance of the player having more than one copy of a specific tome.
I still don't understand why you are so eager to put your script into baldurs.bcs instead of using an invisible creature, but even so, you could still employ an invisible creature to check which player has used your tome.
Simply have the tome set the variable and also spawn an invisible creature (let's call it s9use.cre) and then check for (or better say, use it as a target object) lastsummonerof(''s9use''). (Don't forget to make the creature destroy itself.)
Haven't tested it but it should work that way.
I'm not so eager to use an invisible creature because it seems like "cheating" to me. I know that's kind of dumb. I like to code things a certain way that seem "right" to me and that just doesn't feel right, it feels like a LAST resort. Maybe that's dumb, sorry! Basically, I don't want problems with the summon limit and it seems like the wrong way to go about it to me?
The code below works, I made the tome not destroyed on use in NI... The problem is if, as you said, there is only one copy available. If there is more than one then it gets a problem where it would go in order due to the script (player1, player2, etc). I was going to have my little tome seller have multiple copies but maybe going to only have one if this is the only way to do this without summoning a creature.
IF
Global("S9KITTOM","GLOBAL",1)
HasItem("S9TOME01",Player1)
THEN
RESPONSE #100
ActionOverride(Player1,AddKit(BERSERKER))
ReallyForceSpellRES("IKitAno2",Myself)
SetGlobal("S9KITTOM","GLOBAL",0)
ActionOverride(Player1,DestroyItem("S9TOME01"))
END
IF
Global("S9KITTOM","GLOBAL",1)
HasItem("S9TOME01",Player2)
THEN
RESPONSE #100
ActionOverride(Player2,AddKit(BERSERKER))
ReallyForceSpellRES("IKitAno2",Myself)
SetGlobal("S9KITTOM","GLOBAL",0)
ActionOverride(Player2,DestroyItem("S9TOME02"))
END
::Well, I guess I'll just code up an invisible creature and see how that goes I guess..... Must be the only way unless I want to only have one at a time it seems.
Edited by smeagolheart, 11 May 2013 - 11:47 AM.