antstubell Posted September 17, 2020 Share Posted September 17, 2020 Having issues with packages, package conditions and quest stages. I’ll explain. Quest is not start game enabled. Is NONE. Priority 30. Allow repeated stages. NPC is running the 1st package (top most) in the stack – examine dead body (use idle marker). Package is conditioned Run on Subject (all packages are run on subject), GetStage (Questname) < 10Player sees NPC crouched over body and walks over.Player enters triggerbox and sets quest stage to 10. Screen notification confirms this is stage 10 and shows a messagebox “Follow the stranger.” Quest sets stage to 15.If player does not approach, doesn’t see, can’t be bothered to approach NPC then a triggerbox a little way further on that player cannot avoid but to trigger, sets quest to stage 15.In both circumstances stage is 15 and NPC stops his 1st package. Next package in stack, 2nd from top – walk home (travel) reference to travel to is inside NPC house.Package is conditioned to run when quest == 15When NPC opens the door to his house an OnOpen script is fired only by the NPC and fires only once sets quest stage to 20. On screen confirmation “Doctor is at home Stage 20”This package runs perfectly every time. Stage 20 of the quest does some stuff – unlocks a door so player can enter NPC’s house (surgery, doctor is now open for business)Quest is set to stage 30. Stage 30 of the quest starts a timer. Timer script sets stage 40 after 1 hour.On screen notification “Timer started,”This is purely for immersion so it appears NPC has gone home done some stuff and is now off again. Relates to storyline Doctor has examined dead body, gone home to write a report which player can read then leaves to visit a patient. Stage 40 set after 1 hour. NPC goes to visit patient.On screen notification “Stage 40,”Package is 3rd in the stack – walk to house (travel) reference is inside ‘patient’s’ house.Condition is GetStage == 40. So this is what happens. Doctor examines body, walks home, enters house and a second later leaves house. Following the doctor, after he gets stuck a bit – needs a nudge – he goes back to where he was examining the dead body and stands there doing nothing.If I add a 4th package – sandbox, no conditions, no schedule, reference in NPC’s house, that I thought would make him stay in the house when no conditioned package was running, then he does all the things I have mentioned but when he gets home, he never leaves again. Sorry this was a long post but I wanted to cover everything.Help appreciated GREATLY. Link to comment Share on other sites More sharing options...
FiftyTifty Posted September 17, 2020 Share Posted September 17, 2020 Remember, packages are sorted through from the top -> bottom. If there are no conditions on the first package, it will always be the package being run by the NPC. If there are conditions that don't pass, then it is skipped, and the 2nd package has it's conditions checked. So on and so forth. Link to comment Share on other sites More sharing options...
antstubell Posted September 18, 2020 Author Share Posted September 18, 2020 That's exactly how I stacked the packages. Conditioned first then non-conditioned. Still NPC does not wait for timer to expire which sets stage 40 and runs the package conditioned to ONLY run a stage 40. Link to comment Share on other sites More sharing options...
Recommended Posts