I'm trying to make a script that allows a noninvasive way of enabling markers/objects at inns and abroad... I thought I knew what I was doing... but I apparently dont @_@
In game, I allow an object whose ownership changes during the course of the game (an inn bed, or say, the bed in the archmages quarters) to be "xGSxEnablingObject" and I allow the object I want to activate to be "xGSxObjectToBeEnabled"... However, when ownership changes, it doesn't fire @_@ and the chest/activator that I want to enable in the room of an inn doesn't appear. The chest/activator doesn't have an enable parent as I understand that disables the enable() function and is initially disabled... so... what is wrong?
Also, I read that RegisterForUpdate(1) is an unsafe command to use... and that RegisterForSingleUpdate() is better in most circumstances, is this one of them? If so, how would I implement it in this case?
Thank you for the help!
EDIT: After some fiddling, it seems to work properly,
PS: It may be good to just copy and paste this into Notepad++, as I narrated this script and wrapping is disabled and there is incorrect syntax highlighting.
DId I unregister it correctly? Would it be better to use a while loop? Also is there an AND function in the If command? Like
If (x>3 AND y<2)
wear pants
else
wear hat
endif