lorenzoulm Posted July 4, 2013 Share Posted July 4, 2013 Hi. I'm making a quite complex script. In this script I can heal my companion only if I have enough medicine ability or enough stimpaks (EX. 70% life --------> 1 Stimpak or 30 Medicine, 50% 2 stimpak or 40 medicine etc....). Here's my question: is there a command to check player's inventory to see if there are enough stimpaks to heal. Also one more stupid question: what's the command in a script to run another script (ex. like startsript myscript)? Link to comment Share on other sites More sharing options...
lorenzoulm Posted July 5, 2013 Author Share Posted July 5, 2013 Ok I solved the first isssue by using the command player.GetItemCount ABC X, but I can't figure how to make my script to start after a certain dialogue. How to do that??? Link to comment Share on other sites More sharing options...
joshua121 Posted July 5, 2013 Share Posted July 5, 2013 (edited) Ok I solved the first isssue by using the command player.GetItemCount ABC X, but I can't figure how to make my script to start after a certain dialogue. How to do that???I don't really know of a .startscript command... But there are a lot of ways you can do that anyway. If you're going to be doing a lot of stuff like that, I would use quest variables myself. For example make a quest for whatever you're doing and give it a quest script. In that script just declare variables that you can call from other scripts. It would look like this... SCN TheQuestScript Short QuestVar1Short QuestVar2etc... Now in your other scripts you can use those variables to do all sorts of things. So if we named the quest MyModQuest we could call any one of those variables in another by doing things like this... SCN AnotherScript Begin Gamemode If MyModQuest.QuestVar1 == 1 Do a bunch of other stuff elseif MyModQuest.QuestVar1 ==2 Do this instead So for your case in the dialogue's result script you could set the quest variable to 1 set MyModQuest.QuestVar1 to 1 And then your other script can call it like I showed in the previous example. I hope that helps and if you need me to explain it further let me know. Edited July 5, 2013 by joshua121 Link to comment Share on other sites More sharing options...
lorenzoulm Posted July 5, 2013 Author Share Posted July 5, 2013 Thanks, I will use that QuestVar variables as a trigger to start a part of the script. The bad thing is that i need to rewrite the entire script from scratch :blink: Link to comment Share on other sites More sharing options...
Gribbleshnibit8 Posted July 6, 2013 Share Posted July 6, 2013 If it's being triggered from dialogue, why not use the dialogue result scripts that are part of the dialogue system? Link to comment Share on other sites More sharing options...
Recommended Posts