Jump to content

Help with some scripting and quest problems


Escape23

Recommended Posts

I've been working on my first mod and I like the way its comming along so far, but iv had a few problems that I just cant seem to figure out...

 

I have a quest going, so far only the beginning is done, you recieve the quest, and the key to a cave when you talk to an npc and it works fine till that point.

But I want to make it so when I enter the cave, it updates my quest again, iv tried the "Getincell" condition to make my "Setstage 2Ancientdoor 10" script go upon entering "BanditCave", but every time i enter the cave, nothing happens. Iv tried making it so you get the next part of the quest using the same script by talking to the same npc again and that worked fine... so I'm assuming I'm making an error with my conditions? or perhaps using the wrong condition to get the quest to update upon my entry?

 

Also.. How do I get an npc I placed in a dungeon to sit down in a chair? cant seem to figure it out lol.

 

And one last thing... how do you get the text box in the middle of the screen to pop up saying what you want it to? for instance, If you pick up a certain key, I want the text box that pops up saying something about the key, then you need to click ok for it to go away.

 

Thanks in advance for those who reply ^^

Link to comment
Share on other sites

Guest Some Guy

find ur way around here for a tutorial on some stuff. Hey, it's where I learned to do noob scripting.

PS Just a thought but maybe if its ur first mod u should start small like I did!

Hope I helped and happy modding :D

Link to comment
Share on other sites

is is

begin gamemode
set stage to getstage 2ancientdoor
if stage == 5
if player.getincell banditcave == 1
Setstage 2Ancientdoor 10
messagebox "You have arrived at the requested location"
endif
endif
end

or something similar?

Also, is this part of the script attached to the quest, within a gamemode block, and is the quest started?

If this dosn't help, you might want to just post the scripts here so we can see where you might be causing the problem.

Link to comment
Share on other sites

The script is attached to the quest, and the quest has been started already. I'm going to go try again with what you just showed me now.

 

edit- nope :/ heres the script i have

 

begin gamemode

getstage 2ancientdoor

if player.getincell banditcavecell == 1

setstage 2ancientdoor 10

endif

end

 

 

the quest ID is 2ancientdoor

cave is banditcavecell

previous stage index 5

current stage index (one im working with now) 10

 

what is it that im doing wrong?

Link to comment
Share on other sites

The script is attached to the quest, and the quest has been started already. I'm going to go try again with what you just showed me now.

 

edit- nope :/ heres the script i have

 

begin gamemode

getstage 2ancientdoor

if player.getincell banditcavecell == 1

setstage 2ancientdoor 10

endif

end

 

 

the quest ID is 2ancientdoor

cave is banditcavecell

previous stage index 5

current stage index (one im working with now) 10

 

what is it that im doing wrong?

 

You're not saying what stage the 2ancientdoor quest is in. You should've said something like 'getstage 2ancientdoor == 5', or whatever stage number it is. If this is the first journal entry, you could use 'getstage 2ancientdoor < 10', which means the journal entry will pop up when you enter the cell and the quest stage is smaller than 10.

Link to comment
Share on other sites

What about this script on the door?

begin OnActivate

if (IsActionRef player && GetStage 2ancientdoor < 10)
SetStage 2ancientdoor 10
activate

else
activate

EndIf

end

Adding scripts to doors can become problematic as the script would run any time that door is used by anyone. It would also not answer the question as to why this isn't working, which has me vaguly interested at this point. There are other ways to do this, checking the distance to a marker inside the cell from the quest script for instance, but would prefer to solve the problem.

 

From what I can see, there doesn't seem to be anything wrong with the script itself. But, is banditcavecell added by the same mod as the quest? If that the name, or the editorID? This is an interior cell right?

Link to comment
Share on other sites

You're not saying what stage the 2ancientdoor quest is in. You should've said something like 'getstage 2ancientdoor == 5', or whatever stage number it is. If this is the first journal entry, you could use 'getstage 2ancientdoor < 10', which means the journal entry will pop up when you enter the cell and the quest stage is smaller than 10.

 

If I try putting in a "getstage 2ancientdoor == 5"

or "getstage 2ancientdoor < 10"

It gives me an error, the new script reads

 

begin gamemode

getstage 2ancientdoor == 5

if player.getincell banditcavecell == 1

setstage 2ancientdoor 10

endif

end

 

and the error is

 

"Script "2ancientdoorstage100", line 2:

expected end of line.

compile script not saved!"

 

edit- played around some more and now the script is

 

begin gamemode

if getstage 2ancientdoor == 5

if player.getincell banditcavecell == 1

Setstage 2Ancientdoor 10

endif

endif

end

 

I no longer get an error, but my quest still doesnt advance a stage when I arrive

 

and the quest is not part of the mod, its a seperate quest that uses an area I added, it is an indoor cell, banditcavecell is the editor ID, not the name

Link to comment
Share on other sites

and the quest is not part of the mod, its a seperate quest that uses an area I added, it is an indoor cell, banditcavecell is the editor ID, not the name

 

You may have to have the quest within the same mod as the cell as one mod referencing another (like you could do with morrowind) doesn't work too well with oblivion.

Link to comment
Share on other sites

Archived

This topic is now archived and is closed to further replies.

  • Recently Browsing   0 members

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