(10-22-2010, 06:19 PM)jens Wrote: Books are static props, which are a special form of entities that are only static. so they can not be scripted. You have to take a book entity and make a new special entity that is a normal object entity.
Alright, I did that. It's now an object, subtype "Grab".
But now, the book doesn't appear when I want it do do so.
Here's the function:
void SolveBookPuzzle(string &in asParent, string &in asChild, int alState) {
//Activates a script area that allows the user to "read" the book
SetEntityActive("ReadBookArea", true);
//Should make the book on the table visible, but doesn't
SetEntityActive("SolvedSpecialBook", true);
//Makes the book the player carried to the table disappear
SetEntityActive("specialBook", false);
PlayMusic("bt_01_puzzle_book.ogg", false, 80, 0, 0, false);
GiveSanityBoost();
}
I know it works because it does everything it should do, except making "SolvedSpecialBook" visible.
EDIT: Nope, nevermind, it's just me being stupid (and not knowing how to create a functional entity). It doesn't even show when I set it to active.
Oh well, I guess I need to do it another way. Yay me.