Apophilius Posted June 21, 2009 Share Posted June 21, 2009 Need a blocktype function in the form of "begin *blocktype*". The script has to be activated when the player reads a book that is NOT in their inventory. Anybody know the blocktype for this? I know its not "Onactivate," because everytime I write my script for this the book doesn't open. Its not Onequip either because the book actually has to be in the player's inventory. Link to comment Share on other sites More sharing options...
Vagrant0 Posted June 22, 2009 Share Posted June 22, 2009 Need a blocktype function in the form of "begin *blocktype*". The script has to be activated when the player reads a book that is NOT in their inventory. Anybody know the blocktype for this? I know its not "Onactivate," because everytime I write my script for this the book doesn't open. Its not Onequip either because the book actually has to be in the player's inventory.Onactivate is when they use anything in the world, onequip is when it is in the inventory. Unfortunately, onactivate will trigger BEFORE the book displays its contents, and even prevent those contents from being seen unless the onactivate block causes activation of the book. Essentially, what you need are 2 blocks; an onactivate block which sets a variable in the script, and then activates the book, then a menumode which is based around that variable, and being in the book menu to handle everything you want done while the book is being displayed. And then resetting the variable back so that it remains inactive until triggered again. Keep in mind however that some things do not work particularly well within menumode blocks. Link to comment Share on other sites More sharing options...
Apophilius Posted June 22, 2009 Author Share Posted June 22, 2009 I've found a simpler way around it. Before your state your conditions in the block (i.e. If (getstage...)...), you put in the following script. bookreferenceid.activate - place the conditions and the functions below them and the book will open BEFORE the quest updates. Thanks for the help though! Link to comment Share on other sites More sharing options...
Recommended Posts