Hi guys,
My project is progressing quite well, thanks to your tips.
This time my question is this:
How can I store on a variable a text that was typed by the player?
I've seen on nwnx4 demo (that plugin that allows you to merge neverwinter database with mysql database) that it is possible to open a chat window in which the player can type a message and then store that message on the database.
Does anyone here have any idea of how to implement this? I tried to open the nwnx4 demo on the toolset but it wasn't possible.
thx
how to store a player typed message
Débuté par
el.sombrero
, juil. 28 2012 02:01
#1
Posté 28 juillet 2012 - 02:01
#2
Posté 28 juillet 2012 - 11:37
pretty sure the Gui will do this, start with DisplayInputBox( ) & maybe search through 'nwscript.nss' for "gui" ...
#3
Posté 28 juillet 2012 - 11:56
When you create your party in SoZ, the party motto is stored and used later as for the company logo on the banner of the company at Candlekeep.
#4
Posté 02 août 2012 - 09:48
Hey KevL... what is this GUI thing? I have seen at the "DisplayInputBox" description but I'm not quite sure what it is... supose it has to do with conversation archives, but doesnt have the least idea of how to work it out... anyone can point me to any faq/guide about this?
#5
Posté 02 août 2012 - 10:09
it's a long haul, cause you'll have to get familiar with Gui/xml coding. Basically if you already know some scripting a Gui-box window can be pulled up for the player.
Those are functions that can be looked up in ScriptAssist. Lance Botelle has a tutorial and Obsidian Programmer has more indepth descriptions of Gui elements. Google searches should pull either/both up pretty quick, but really the only way to do it is get messy until things start making sense. I suggest starting by trying to just pull up a DisplayMessageBox( ) that shows sMessage to the client.
void DisplayGuiScreen(object oPlayer, string sScreenName, int bModal, string sFileName = "", int bOverrideOptions = FALSE); void DisplayMessageBox(object oPC, int nMessageStrRef, string sMessage, string sOkCB="", string sCancelCB="", int bShowCancel=FALSE, string sScreenName="", int nOkStrRef=0, string sOkString="", int nCancelStrRef=0, string sCancelString=""); void DisplayInputBox(object oPC, int nMessageStrRef, string sMessage, string sOkCB="", string sCancelCB="", int bShowCancel=FALSE, string sScreenName="", int nOkStrRef=0, string sOkString="", int nCancelStrRef=0, string sCancelString="", string sDefaultString="", string sUnusedString=""); void SetNoticeText(object oPlayer, string sText);
Those are functions that can be looked up in ScriptAssist. Lance Botelle has a tutorial and Obsidian Programmer has more indepth descriptions of Gui elements. Google searches should pull either/both up pretty quick, but really the only way to do it is get messy until things start making sense. I suggest starting by trying to just pull up a DisplayMessageBox( ) that shows sMessage to the client.
#6
Posté 06 août 2012 - 09:39
Hey guys, I need to implement, basically, 3 message-related functions in my game.
1º I would like to have a message displayed to the PC just before he starts the game. This message will inform the player about the game's background... pretty much like that first screen on the star wars movie (but it doesn't need to move... just a regular message will be ok).
2º At the end of the maze, the palyer will meet a character who will give him a knighthood if the time the player really spent to solve the maze is less than 5 minutes. It will be a simple message "As consequence of your efforts in solving this maze, you are now a knight of our majesty".
At the end of a maze I need a box to open up. At the box header will be written the following: "type how many minutes and seconds you think you spent to solve this maze?". The value the player types need to be stored at a variable. spent".
3º At the end of a maze I need a box to open up. At the box header will be written the following: "type how many minutes and seconds you think you spent to solve this maze?". The value the player types need to be stored at a variable. spent".
To implement these functions, which way do I think I should try... just playing with the functions above or going to some tutorial?
thx!
1º I would like to have a message displayed to the PC just before he starts the game. This message will inform the player about the game's background... pretty much like that first screen on the star wars movie (but it doesn't need to move... just a regular message will be ok).
2º At the end of the maze, the palyer will meet a character who will give him a knighthood if the time the player really spent to solve the maze is less than 5 minutes. It will be a simple message "As consequence of your efforts in solving this maze, you are now a knight of our majesty".
At the end of a maze I need a box to open up. At the box header will be written the following: "type how many minutes and seconds you think you spent to solve this maze?". The value the player types need to be stored at a variable. spent".
3º At the end of a maze I need a box to open up. At the box header will be written the following: "type how many minutes and seconds you think you spent to solve this maze?". The value the player types need to be stored at a variable. spent".
To implement these functions, which way do I think I should try... just playing with the functions above or going to some tutorial?
thx!





Retour en haut






