Jump to content

[LE] I'm urgently looking for help with advancing quest stages. Please help!


Recommended Posts

What I need to do is spawn a boss enemy after dealing with several mobs. Essentially I need to advance the quest by a set amount on each subsequent kill, however I haven't been able to figure it out. The script I used earlier went as follows:



Event OnDeath(Actor killer)

Advquestondeath.SetStage(20)

EndEvent


For obvious reasons, this can cause sequencing errors if the player kills mobs out of one specific sequence

What I need is for this "Advquestondeath.SetStage(20)" to become "Advquestondeath.SetStage(current quest stage+10)".


I assume it's very simple to do for someone familiar with the engine, but without knowing the syntax I don't even know what errors I'm making when trying to script it.


Any and all help will be greatly appreciated!


Link to comment
Share on other sites

I'm not sure if it's possible , but isn't it better to just create a counter , have it start with the amount of enemies you spawn , and have the counter go down with each kill?

and have the quest advance once the counter reaches 0?

would it not work best when the quest advances just once , when all enemies are killed?

Link to comment
Share on other sites

that's the thing , I've never used Papyrus in my life

I know some basic scripting , and from what I understand some scripts resemble the syntax of C# (which the programming language I know)

so I really have no idea how to go about doing something like this

I just thought this might be a better approach to this

 

I'll try doing some digging and see if I can find something informative for you to use

 

Edit : maybe this will help https://www.creationkit.com/index.php?title=Variables_and_Properties

Edited by WastelandAssassin
Link to comment
Share on other sites

; example
int maxEnemies = 10
 
Event OnDeath(Actor akKiller)
     ; This event will expect the player to be the killer.
     ; If you don\'t want this, just remove the player assignment and if statement block.
     akKiller = Game.GetPlayer()
     if (!akKiller)
         return
     endif
    
     maxEnemies -= 1
   
    if maxEnemies == 0
        ; stage can be whatever you want
        myQuest.SetCurrentStageID(stage)
    endif
EndEvent

Sounds like Wasteland Assassin is talking about something like the above. Ah yes, the thing about changing the stage on *every* kill. I really can't think of a safe way of doing that there's also the concern I have about the count somehow going negative if the event is too slow to process the death, like if multiple actors die at the same time. '<= 0' might take care of that. Since I'm not able to test in game, I can't be sure.

Edited by Rasikko
Link to comment
Share on other sites

; example
int maxEnemies = 10
 
Event OnDeath(Actor akKiller)
     ; This event will expect the player to be the killer.
     ; If you don\'t want this, just remove the player assignment and if statement block.
     akKiller = Game.GetPlayer()
     if (!akKiller)
         return
     endif
    
     maxEnemies -= 1
   
    if maxEnemies == 0
        ; stage can be whatever you want
        myQuest.SetCurrentStageID(stage)
    endif
EndEvent

Sounds like Wasteland Assassin is talking about something like the above.

 

 

yep , that sounds like what I would write , if I knew Papyrus syntax

thanks Rasikko :)

Edited by WastelandAssassin
Link to comment
Share on other sites

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...