YouDoNotKnowMyName Posted May 8, 2021 Share Posted May 8, 2021 Good evening everybody! So it appears that you can't really use SetStage to set the current stage of a quest to a lower value then the current quest stage.In other words: You can't decrement the quest stage. But quests would be pretty good to use as "state machines".For example, an elevator that services 10 floors could be nicely done with a quest, where the quest stage "stores" on which floor the elevator cabin is currently located. But oh no, quest stages can only be inceased! What a stupid limitation ...Why did they make "quests" this way?I mean the "quest stage" is basically just a variable like everything else, right?So technically there is no reason why it shouldn't be able to be decremented ...Sorry for the rant ... So, is there any way to "work around" this limitation?If not, how else should we implement "state machines"?With global variables? Putting a ton of markers in a cell and enabling / disabling them (that seems very messy ...)? Link to comment Share on other sites More sharing options...
SKKmods Posted May 9, 2021 Share Posted May 9, 2021 Quests are desigend for linear one way progression, an objective can be regressed but not a stage. Actually a stage can technically be regressed but that state is not correctly reported by GetStage() or GetStageDone() so its useless. Use Global Variables as non object associated state flags. Use Actor values for object (not just actor) associated state flags. Infact I tend to use GVs and Script functions rather than quest stages and script fragments as they are far more flexible and easier to maintain. Link to comment Share on other sites More sharing options...
YouDoNotKnowMyName Posted May 9, 2021 Author Share Posted May 9, 2021 Quests are desigend for linear one way progression, an objective can be regressed but not a stage. Actually a stage can technically be regressed but that state is not correctly reported by GetStage() or GetStageDone() so its useless. Use Global Variables as non object associated state flags. Use Actor values for object (not just actor) associated state flags. Infact I tend to use GVs and Script functions rather than quest stages and script fragments as they are far more flexible and easier to maintain.Ok, thanks!I will use globals then ... Link to comment Share on other sites More sharing options...
DocClox Posted May 9, 2021 Share Posted May 9, 2021 Yeah, I did that way back when the CK was first released for Skyrim. Seemed obvious really - use quests as state machines. And, like you, I found out that if you regress a quest, while it flags that the stage has been "done", the current stage stays at the largest value. I wasted a couple of weeks finding that out the hard way. Did I not say all this to you when you first asked about it? I'm fairly sure I did. Link to comment Share on other sites More sharing options...
YouDoNotKnowMyName Posted May 9, 2021 Author Share Posted May 9, 2021 Yeah, I did that way back when the CK was first released for Skyrim. Seemed obvious really - use quests as state machines. And, like you, I found out that if you regress a quest, while it flags that the stage has been "done", the current stage stays at the largest value. I wasted a couple of weeks finding that out the hard way. Did I not say all this to you when you first asked about it? I'm fairly sure I did.Sorry, I sometimes loose track of what I already know ... Link to comment Share on other sites More sharing options...
Recommended Posts