GomuGomu64 Posted June 16, 2012 Share Posted June 16, 2012 What I'm trying to do is that when a piece of dialogue is going to be said, a message box pops up, which the player then clicks a button on.Thing is, I haven't a clue how to do this. I've tried extending a script with a function that shows the message box, then I call the function, I get an error. I've tried putting a small script with properties and everything into a fragment, doesn't compile. It flips out. Anybody know how to do this? Link to comment Share on other sites More sharing options...
DreamKingMods Posted June 16, 2012 Share Posted June 16, 2012 (edited) 1) Create your message in the Messages section of the CK2) Put something really simple in your dialogue fragment like "int a", then hit the "Compile" button.3) Close out of the dialogue window, then open it again. Hit the "Properties" button next to the scripts.4) Click the "Add Property" button, choose Message as the type, give it a name. Then edit its value to point to the message you created.5) In your fragment script, delete the "int a" and you should now be able to do YourMessagePropertyName.Show() Alternatively you can put a function to display your message in a quest script attached to your quest, then in the fragment do (GetOwningQuest() as MyQuestScriptName).MyFunctionToDisplayAMessage() Edited June 16, 2012 by DreamKingMods Link to comment Share on other sites More sharing options...
gasti89 Posted June 16, 2012 Share Posted June 16, 2012 Or you can make the dialogue call a setstage, then set the properties and the Show() on the stage fragment. Quest fragments are easier to manage than dialogue fragments imho. Link to comment Share on other sites More sharing options...
GomuGomu64 Posted June 16, 2012 Author Share Posted June 16, 2012 You are awesome. It works! Thanks a lot. Link to comment Share on other sites More sharing options...
Recommended Posts