ChancellorKremlin Posted October 1, 2012 Posted October 1, 2012 Right, so I'm advancing at a slugs pace towards the exciting prospect of having variables set through dialogue, but for that I need a script, and a place to store them. Problem is, I have no idea how to set one up. So say I have a quest (scriptless for the time being) and in that quest there is a dialogue option that says "OK, I'll do that." - I want to then advance the dialogue a little with other characters, so that if say "if WorkingAsWhore = 1" then ... do you get the gist? So with that in mind, how would I set up a simple script to store a number of variables, which can be changed through dialogue? Any help would be greatly appreciated. Thanks!
zippy57 Posted October 1, 2012 Posted October 1, 2012 Make a script, assign the script to the quest: scn MyScript int WorkingAsWhore int SomethingElse int AnotherThing
ChancellorKremlin Posted October 1, 2012 Author Posted October 1, 2012 Funny thing is, the moment I posted that, I looked up TryoutLegion and found its variables, and I was surprised at how simple the entire thing was, I was dumbfounded. I thought it was going to be a lot more complicated. For once, I'm glad lol. Thanks Zippy.
ChancellorKremlin Posted October 1, 2012 Author Posted October 1, 2012 What's the difference between int and short?
zippy57 Posted October 1, 2012 Posted October 1, 2012 int, short, and long are all actually the same thing.
ChancellorKremlin Posted October 1, 2012 Author Posted October 1, 2012 So it doesn't matter which one I use, so long as in the dialogue I say set MyQuestOhNoSheDidnt to MyQuestOhNoSheDidnt + 1 ?
Halstrom Posted October 1, 2012 Posted October 1, 2012 int' date=' short, and long are all actually the same thing.[/quote']In NV scripting they are anyway, they are different elsewhere, so I just use ref, short & float myself If you want to be blown away have a look at the VAR quest scripts in SCR for storing actor variables
ChancellorKremlin Posted October 1, 2012 Author Posted October 1, 2012 I keep getting the following problem: "Form's ID is not unique! Previous form is type Script." It won't save my script when I enter: scn MyScript short OhNoSheDidnt I'll save, and it will just disappear. Am I supposed to save "script type" as object, quest or effect?
BruceWayne Posted October 1, 2012 Posted October 1, 2012 I keep getting the following problem: "Form's ID is not unique! Previous form is type Script." It won't save my script when I enter: scn MyScript short OhNoSheDidnt I'll save' date=' and it will just disappear. Am I supposed to save "script type" as object, quest or effect? [/quote'] If it´s a quest script it´s quest.
ChancellorKremlin Posted October 1, 2012 Author Posted October 1, 2012 Thanks Bruce, for some reason the script still won't save. Am I supposed to do something else besides "save" and "exit"? The minute I do that the script vanishes...
zippy57 Posted October 1, 2012 Posted October 1, 2012 That error means there's already an existing file with that name, and it happens to be a script. Call it something you'll actually remember and can use filters to locate. For example, SexoutAgentT01Q2VentScript (don't actually use that one).
BruceWayne Posted October 1, 2012 Posted October 1, 2012 Thanks Bruce' date=' for some reason the script still won't save. Am I supposed to do something else besides "save" and "exit"? The minute I do that the script vanishes... [/quote'] Close all quest windows, save and reopen your quest. Click the ... and your script should be there somewhere. One of the mistakes I made earlier, was giving my script the same name as my quest. Maybe that´s your problem too. Try naming it MyQuestscript for your quest MyQuest. If you´re going to do scripts, even if it´s only for storing variables i highly recommend geckpu. Most of the time it gives you a message for what´s missing. edit:argh, too slow...
ChancellorKremlin Posted October 2, 2012 Author Posted October 2, 2012 I'm fairly sure I'm using geckpu, the one that uses nvse_loader as a shortcut? Also, I've changed the names of the script and the quest and I get the same error - I don't understand, there is no way there is another quest/script in the game with the same name as mine. Changed the script bit to quest, and still the same error.
zippy57 Posted October 2, 2012 Posted October 2, 2012 Hmm... Not sure what to tell you, I only know of one source of that error: a record of any kind with the same name.
ChancellorKremlin Posted October 2, 2012 Author Posted October 2, 2012 OK, to be absolutely sure, I'm in the quest list, and searching for the name of the quest I want to implement comes up with zero results, so I'm assuming it doesn't exist and therefore shouldn't conflict, right? EDIT: Just created a totally different quest and script name, totally random, and have the same problem... I don't know what I could possibly be doing wrong. Maybe I'll do a step by step screenfest and maybe anyone can figure out where I am erring?
zippy57 Posted October 2, 2012 Posted October 2, 2012 The error message you posted said the old ID belonged to a script, not to a quest.
ChancellorKremlin Posted October 2, 2012 Author Posted October 2, 2012 I thought all scripts were stored in quests? This is what I've done: Under Actor Data > Quests I've opened up the list and right at the bottom where it's blank I've right clicked "New Quest". There I've ticked "Start Game Enabled" and "Script Processing Delay". For the Quest Name, I've put "Slave Jail Sex Variable Storage" and for Quest ID I've put "SlaveJailTSexVar". Right of where it says script, I've clicked the ... button, and there I clicked the tab "Script" and "New". This allows me to edit the big white space. I then write in "sct SlaveJailTSexVar" followed by a space, and then "short isrubbleprostitute", next line, then "short isslaveprostitute". Finally, in "Script Type" I select Script from the drop down menu. I then open the "Script" tab, save, then exit. The script appears not to save. Then, if I try and exit the quest by pressing "exit" on the bottom right corner, I get the "Form Editor ID Error: Form's ID is not unique! Previous form type is Script." ?
BruceWayne Posted October 2, 2012 Posted October 2, 2012 I thought all scripts were stored in quests? This is what I've done: Under Actor Data > Quests I've opened up the list and right at the bottom where it's blank I've right clicked "New Quest". There I've ticked "Start Game Enabled" and "Script Processing Delay". For the Quest Name' date=' I've put "Slave Jail Sex Variable Storage" and for Quest ID I've put "SlaveJailTSexVar". Right of where it says script, I've clicked the ... button, and there I clicked the tab "Script" and "New". This allows me to edit the big white space. I then write in "sct SlaveJailTSexVar" followed by a space, and then "short isrubbleprostitute", next line, then "short isslaveprostitute". Finally, in "Script Type" I select Script from the drop down menu. I then open the "Script" tab, save, then exit. The script appears not to save. Then, if I try and exit the quest by pressing "exit" on the bottom right corner, I get the "Form Editor ID Error: Form's ID is not unique! Previous form type is Script." ? [/quote'] It should look like this: edit: my steps: new - quest filling in quest id and name ->OK reopen quest clicking ... new script stuff script type ->quest save script close select script from dropdown menu edit2: Maybe you don´t have an active plugin selected? If not you can´t save.
ChancellorKremlin Posted October 2, 2012 Author Posted October 2, 2012 It looks exactly like that. Now I save, exit, then try and exit again, and I get that error message.
zippy57 Posted October 2, 2012 Posted October 2, 2012 You can't have two things with the same name. If your quest is SlaveJailTSexVar then your script can't also be SlaveJailTSexVar.
ChancellorKremlin Posted October 2, 2012 Author Posted October 2, 2012 Ah, okay, I get it. See, I thought the script had to use the same name as the quest in order for it to work. When you guys said they both couldn't have the same name, I thought you meant the Quest name and the ID. Urgh, two pages of LL's bandwith wasted on this noobness. Thanks guys, you've been a real help!
BruceWayne Posted October 2, 2012 Posted October 2, 2012 You can't have two things with the same name. If your quest is SlaveJailTSexVar then your script can't also be SlaveJailTSexVar. Oddest thing is that it actually saved for me. Maybe that´s some unknown geckpu magic...
zippy57 Posted October 2, 2012 Posted October 2, 2012 It saved for you because you didn't give them both the same name. The script was SlaveJailTSexVar and the quest was SlaveJailSexVariableStorage.
ChancellorKremlin Posted October 2, 2012 Author Posted October 2, 2012 OK new problem, it saves now, but when I look it up in the quests list and look up the script, it just says "none" and there is nothing there if I open it.
BruceWayne Posted October 2, 2012 Posted October 2, 2012 It saved for you because you didn't give them both the same name. The script was SlaveJailTSexVar and the quest was SlaveJailSexVariableStorage. Lol, didn´t notice that. It´s getting late...
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now