Using Quest Event - Increase Level

Post » Thu Jun 21, 2012 3:44 am

Hi all,

I am sure this has been done before but I cannot find any example of it anywhere. Basically I want to create a new quest that does not display in the players journal (well not yet anyway might create a proper quest at some point) that watches when the player levels up.

At level 2 or higher they are given Spell A
(Level 2 because I don't want anything added while the player is in the Tutorial)
At level 10 or higher they are given Weapon B
At level 40 or higher they are given Armour C

I want the quest to finish once they player definitely has all three custom references.
I know papyrus pretty well created a lot of scripts but I'm totally new to the quest side of it except using a quest to hold variables.

Spell Property CoolSpell AutoWeapon Property CoolWeapon AutoArmor Property CoolArmour AutoIF Game.GetPlayer().GetLevel() >= 2	   Game.GetPlayer().AddSpell(CoolSpell)	 IF Game.GetPlayer().GetLevel() >= 10		   Game.GetPlayer()AddItem(CoolWeapon, 1, FALSE)		   IF Game.GetPlayer().GetLevel() >= 40				  Game.GetPlayer()AddItem(CoolArmour, 1, FALSE)		  ENDIF	ENDIFENDIF
Etc. etc.
Could anyone give me some info of setting this up. I have gone through the Wiki quest tutorial for good old Bendu but I'm not quite grasping the use of the other quest functions especially Aliases.

This would be really useful for me when releasing my mods as I don't like to mess with the Vanilla form lists or vendors and it's a good way to restrict the player getting the good items/spells too early.

Thanks.
User avatar
Kaley X
 
Posts: 3372
Joined: Wed Jul 05, 2006 5:46 pm

Post » Thu Jun 21, 2012 9:50 am

Look into SM event nodes.
User avatar
Laura-Lee Gerwing
 
Posts: 3363
Joined: Fri Jan 12, 2007 12:46 am

Post » Thu Jun 21, 2012 10:46 am

IMO, if you want to maintain compatibility with other mods, forget using SMEN's.
If you add a node to the Increase Level Event, and I add a node to it also, a user with both our mods will see only one's addtion.
I think you're better off using an Update Event in your quest script to check the players level...
Yeah, it may not happen immediately, but then you waon't get people telling you that your mod is not working...
User avatar
Cartoon
 
Posts: 3350
Joined: Mon Jun 25, 2007 4:31 pm

Post » Thu Jun 21, 2012 9:28 am

Right, I had forgotten about that unforunate feature. I made a companion mod that used the nodes to give perk points to a follower, didn't work out so well.
User avatar
Aliish Sheldonn
 
Posts: 3487
Joined: Fri Feb 16, 2007 3:19 am

Post » Thu Jun 21, 2012 11:27 am

IMO, if you want to maintain compatibility with other mods, forget using SMEN's.
If you add a node to the Increase Level Event, and I add a node to it also, a user with both our mods will see only one's addtion.
I think you're better off using an Update Event in your quest script to check the players level...
Yeah, it may not happen immediately, but then you waon't get people telling you that your mod is not working...

Is this true for ANY additions to the Story Manager? Even adding new quests to the "Change Location Event"?
User avatar
Elizabeth Davis
 
Posts: 3406
Joined: Sat Aug 18, 2007 10:30 am

Post » Thu Jun 21, 2012 3:37 pm

IMO, if you want to maintain compatibility with other mods, forget using SMEN's.
If you add a node to the Increase Level Event, and I add a node to it also, a user with both our mods will see only one's addtion.
I think you're better off using an Update Event in your quest script to check the players level...
Yeah, it may not happen immediately, but then you waon't get people telling you that your mod is not working...
I don't know if this is relay true. Last thread I noticed about it http://www.gamesas.com/topic/1371672-sm-event-node-known-issue-what-to-do-or-avoid/ says you can safetly use it. I believe adding an entire new SM node from the Object tree should be safe, also adding groups to a node might work. Didn't properly tested it myself.
User avatar
Marine Arrègle
 
Posts: 3423
Joined: Sat Mar 24, 2007 5:19 am

Post » Thu Jun 21, 2012 8:25 am

hmmm...
i think i'll do some more testing. It was a quick and dirty test i made when i was imformed of a problem with my mod ASAP.
but, off to bed now. i'll report back tomorrow or the next day.
User avatar
marie breen
 
Posts: 3388
Joined: Thu Aug 03, 2006 4:50 am

Post » Thu Jun 21, 2012 5:10 am

Okay so my original idea is pretty much out the window as
A: it's not as straight forward as I had hoped and
B: there is a possible issue with SM nodes and conflicts with other people mods.
Fair enough, not the first time I have had to come up with a work around and I bet not the last.

My new idea, which unfortunately will modify a vanilla Cell in Skyrim something I have been trying very hard not to do in my entire mod is effect anything vanilla to keep my mod as compatible as possible. Such is life.
What if I created placed an object with no Havok below a vendors shop interior, and attached the below script.

Actor Property PlayerRef Auto	 ; References the player.Book Property bkSpellA Auto	 ; Reference the Spell A Spell Tome.Book Property bkSpellB Auto	 ; Reference the Spell B Spell Tome.Book Property bkSpellC Auto	 ; Reference the Spell C Spell Tome.Book Property bkSpellD Auto	 ; Reference the Spell D Spell Tome.Spell Property spSpellA Auto	 ; Reference Spell A.Spell Property spSpellB Auto	 ; Reference Spell B.Spell Property spSpellC Auto	 ; Reference Spell C.Spell Property spSpellD Auto	 ; Reference Spell D.ObjectReference Property VendorChest Auto	 ; Reference the vendors sales chest.EVENT OnCellAttach()  Debug.Notification("Object script ran")  Debug.Trace("Object script ran")	 IF PlayerRef.GetLevel() >= 2 && !PlayerRef.HasSpell(spSpellA) && VendorChest.GetItemCount(bkSpellA) == 0		  VendorChest.Additem(bkSpellA, 1, FALSE)	 ENDIF	 IF PlayerRef.GetLevel() >= 10 && !PlayerRef.HasSpell(spSpellB) && VendorChest.GetItemCount(bkSpellB) == 0		  VendorChest.Additem(bkSpellB, 1, FALSE)	 ENDIF	 IF PlayerRef.GetLevel() >= 20 && !PlayerRef.HasSpell(spSpellC) && VendorChest.GetItemCount(bkSpellC) == 0		  VendorChest.Additem(bkSpellC, 1, FALSE)	 ENDIF	 IF PlayerRef.GetLevel() >= 30 && !PlayerRef.HasSpell(spSpellD) && VendorChest.GetItemCount(bkSpellD) == 0		  VendorChest.Additem(bkSpellD, 1, FALSE)	 ENDIF	 IF PlayerRef.HasSpell(spSpellA) && PlayerRef.HasSpell(spSpellB) && PlayerRef.HasSpell(spSpellC) && PlayerRef.HasSpell(spSpellD)		  Disable()		  Delete()	 ENDIFENDEVENT

So basically this script will only run when the player enters the vendors shop and when the player reaches a certain level a new spell book will be added to the vendors inventory. If the player already has the spell the tome won't be sold again, also once all the spell tome's have been bought and the player has learnt all the spells the object destroys itself stopping the script ever running again.

Will this work okay or are there other potential conflicts I am not seeing?
User avatar
Toby Green
 
Posts: 3365
Joined: Sun May 27, 2007 5:27 pm

Post » Thu Jun 21, 2012 4:35 pm

leonfenten

Have you tried creating an alias then putting the aliased object with the container if certain conditions are true?

One of my quests have a note that is placed within an NPC and then given to the player.

The object is using "Create Reference To Object" under the alias properties.

Or is that not what you're looking for?
User avatar
Lillian Cawfield
 
Posts: 3387
Joined: Thu Nov 30, 2006 6:22 pm


Return to V - Skyrim