ijarofjami Posted July 17, 2010 Share Posted July 17, 2010 So, I'm wondering... How do you update the quest log when you acquire a specified item or kill a person? I know this is probably a relatively simple thing to do, but I'm new and still getting the hang of this stuff. Link to comment Share on other sites More sharing options...
slygothmog Posted July 17, 2010 Share Posted July 17, 2010 So, I'm wondering... How do you update the quest log when you acquire a specified item or kill a person? I know this is probably a relatively simple thing to do, but I'm new and still getting the hang of this stuff. lets say the quest is called aaStorm and you want it to progress to stage 15 if the player picks up a sword called Bob You will need a short variable to make this happen only once short custard begin gamemode if custard == 0 && player.getitemcount Bob == 1setstage aaStorm 15set custard to 1endif end Link to comment Share on other sites More sharing options...
ijarofjami Posted July 17, 2010 Author Share Posted July 17, 2010 So, that's a script, right? I haven't actually gotten into those, yet. Like I said, I'm fairly new. So, once I make the script, how do I apply it, or does it apply automatically? Also, how would I go about doing the same thing for killing someone and progressing the quest? Link to comment Share on other sites More sharing options...
slygothmog Posted July 17, 2010 Share Posted July 17, 2010 (edited) Yes thats a script ( I've had a beer so I gave it daft names )...you need to make a quest and attach the script to that. Scripts dont work unless you attach them to something, the three things you can write a script for are Magic, Quest and Object....Magic only works with a begin scripteffectstart block, but begin gamemode can be attached to both quest and object ( they also run every frame per second ), whereas begin onadd, begin onactivate and begin onequip only run once. Yes it's possible to progress a quest upon the death of an NPC, but I only know how to do this using OBSE. ref actor begin gamemode set actor to player.getcrosshairref thats one way, the other is to write a loop script that checks all NPC's within the same cell as the player set actor to player.getnumrefs 69 1 You can also progress a quest through dialogue. sorry I am not being much use here, but I have had a beer and what you are trying to accomplish will not be easy if you know nothing about script. You either need to do some serious study of script or I can write it for you...but dont count your chickens before they hatch with me. Edited July 17, 2010 by slygothmog Link to comment Share on other sites More sharing options...
slygothmog Posted July 17, 2010 Share Posted July 17, 2010 I wrote a script on notepad you can copy and paste into a quest script ( you will need to use ctrl + v as right click dont bring up the small menu in script ), you will need to give it the ID of the NPC and the questID + the stage number you wish to progress to.This script will constantly check all npc's that are in the same cell as the player ( both interior and exterior ) and once the relevant one is dead will progress the quest to whatever stage you set within the script.If you have problems give me a shout either here or via a PM. ( now i have bad hangover :( ) You will need to launch the CS via OBSE for this to work....if you dont know how to do this, again gimme a shout. Link to comment Share on other sites More sharing options...
Zaldir Posted July 17, 2010 Share Posted July 17, 2010 To make a quest update when a NPC dies: Attached to a Quest: (i.e if you want it to update when more than one npc is dead)Begin GameMode if (FirstNPCRef.GetDead == 1) && (SecondNPCRef.GetDead == 1) Setstage 'QuestID' 'QuestStage' Endif End Attached to a NPC:Begin OnDeath Setstage 'QuestID' 'QuestStage' End Link to comment Share on other sites More sharing options...
ijarofjami Posted July 18, 2010 Author Share Posted July 18, 2010 Okay, so for picking up the item, I would save the script type as Object, right? Link to comment Share on other sites More sharing options...
Zaldir Posted July 18, 2010 Share Posted July 18, 2010 This script:short DoOnce begin gamemode if DoOnce == 0 && player.getitemcount ItemRef/ItemID == 1 setstage 'QuestID' 'QuestStage' set DoOnce to 1 endif end Can be used for both object and Quest. I would make it a quest script though. (This requires that you use the ItemRef, and not the ItemID)Then, if both these scripts are for the same quest, you would just add them to the same script. Link to comment Share on other sites More sharing options...
ijarofjami Posted July 19, 2010 Author Share Posted July 19, 2010 Sweet, thanks for the help. Link to comment Share on other sites More sharing options...
ijarofjami Posted July 19, 2010 Author Share Posted July 19, 2010 Okay, one more question... I'm trying to get a quest to update when you read a note. I was trying something like this, but it obviously didn't work: ScriptName AssassinsContract2 short DoOnce begin gamemode if DoOnce == 0 && IsActionRef player == 1 && GetStage AHAdemarQuest02 == 10 || GetStage AHAdemarQuest02 == 25 && player.GetIsUsedItem AHContract2 == 1SetStage AHAdemarQuest02 30Set DoOnce to 1endif end Let me know what I'm doing wrong. Link to comment Share on other sites More sharing options...
Recommended Posts