BotaniciTraffici on 7/5/2014 at 13:14
Hey Taffers!
(Sorry for my english)
I need a little help!
I added book->text property to a normal object because i want to show a message when Player frob one object, but i need to show the text only one time. How to?
Thanks in advance...
LarryG on 7/5/2014 at 14:05
The easiest way might be to make the book-object unfrobbable after reading. There's a metaprop for this which you can add to the book-object. NVMetaTrap is one way to go to add the metaprop.
BotaniciTraffici on 7/5/2014 at 14:20
Quote Posted by LarryG
The easiest way might be to make the book-object unfrobbable after reading. There's a metaprop for this which you can add to the book-object. NVMetaTrap is one way to go to add the metaprop.
Mmmmm... i will try... but i need the object stay froddable: object is a container and can be closed after opening.
LarryG on 7/5/2014 at 17:03
Another way is NOT to make the object a book to show the text, but instead to use NVOnscreenText. Since this is a Trap script, you can use NVOnscreenTextCount=1 to have the script only work once.
BotaniciTraffici on 7/5/2014 at 20:35
Quote Posted by LarryG
Another way is NOT to make the object a book to show the text, but instead to use NVOnscreenText. Since this is a Trap script, you can use NVOnscreenTextCount=1 to have the script only work once.
Thank you LarryG.
Sorry... i need more help because i never used customs script.
I do this...
1) in DromEd script_load NVscript
2) EngineFeature ->FrobInfo ->WorldAction=Script
3) S -> Script -> NVOnscreenText
4) Editor -> DesignNote -> NVText='file.str'
When frobbed the container show file.str and not its content
...and i don't have idea how to use NVOnscreenTextCount too.:confused:
LarryG on 7/5/2014 at 22:50
Almost right. I believe that in your case you would want something like this:
Editor>DesignNote: NVOnScreenTextOn="FrobWorldEnd"; NVOnScreenTextOff="Null"; NVOnScreenTextCount=1
and don't forget
Book>BookText: as per usual
LarryG on 8/5/2014 at 18:55
Try this:
Book>Text: filebanana
Editor>DesignNote: NVOnscreenTextFocusRead=0; NVOnscreenTextOn="FrobWorldEnd"
Engine Features>FrobInfo: {Script, FocusScript; [none]; [none]}
Scripts: {NVOnscreenText; ; ; ; False}
That will allow the object to still act like a container when frobbed since it is inheriting the scripts needed from the conatainer archetype, and in game it will not display the text until the object is frobbed. As long as the object has the focus, the text will be displayed. When you look away, it stops the display. Unfortunately I could not get NVOnscreenTextCount=1 to work. So every time you frob the container you get the text. This may be a bug in the script, or I may be doing something wrong.
BotaniciTraffici on 8/5/2014 at 19:51
Quote Posted by LarryG
Unfortunately I could not get NVOnscreenTextCount=1 to work. So every time you frob the container you get the text. This may be a bug in the script, or I may be doing something wrong.
But in this case is the same as book->text whitout NVScript, don't solve my first problem: Show text one time.
Aniway... i try your instructions but nothing happens when container is frobben.
(Sorry again for my bad english)
LarryG on 8/5/2014 at 21:05
What I described worked for me exactly as written. What was your setup when using the container as a "book"? Did that display the text at all?
Personally, I'm having trouble understanding why you want to have this duel action on the container. It doesn't make sense to me. What are you trying to accomplish? Maybe there is a simpler approach to meet your goals.