Jump to content

Scripting Troubles in the CK


Roarian

Recommended Posts

I've been fooling around with the CK for a while, mostly taking the tutorial and making my own spin on the quest described there.

 

When arriving at the stage of giving the player some money, the CK is adamant that 'Gold_001' as described is not actually something that exists.

 

Game.GetPlayer().AddItem(Gold001, 500)

 

That just throws up an error noting that Gold_001 isn't real. The alternative mentioned doesn't work with the same error.

 

Later on (I skipped that for the moment) I got to editing in some Radiant elements, and the tutorial clearly shows that the following needs to be added to Stage 10 of the quest to replace the exisitng hardcoded marker reference.

 

Alias_ThiefLocation.GetReference().AddToMap()

 

Adding this and trying to compile, though, does nothing. My version of ThiefLocation is identical to the one shown in the tutorial. The error I receive is :

 

c:\program files (x86)\steam\steamapps\common\skyrim\Data\Scripts\Source\temp\QF_HeronTomb01_0100198E.psc(41,21): GetReference is not a function or does not exist
c:\program files (x86)\steam\steamapps\common\skyrim\Data\Scripts\Source\temp\QF_HeronTomb01_0100198E.psc(41,36): none is not a known user-defined type

 

(Note that HeronTomb is simply my version of the questname.)

 

Please, any advice on what I'm doing wrong? :)

 

Jeron

Link to comment
Share on other sites

Read http://www.creationkit.com/Property_Reference

This confused the hell out of me too. Ill break it down.

 

You need to declare your gold with a property in the new properties dialog. Highlight your script and click properties.

http://img820.imageshack.us/img820/2180/highlighti.png

 

Now click add property. The name you give the property is the name you will use in scripts and the type defines what you can attach to it. For gold choose MiscObject.

When you see your new property highlight it and click edit value on the right and choose gold001.

http://img198.imageshack.us/img198/2831/goldtime.png

 

Now you will notice the property has been added to your script for you.

MiscObject Property Gold  Auto  

 

For now on when you want to add gold in a script you would say..

Game.GetPlayer().AddItem(Gold, 500)

 

8)

Link to comment
Share on other sites

8)

 

Apparently the tutorial people just skimmed over that part.

 

I already managed to fix (at least mostly) the other problem I had, which was another problem with the tutorial moreso than the actual CK.

 

Figures. :P

 

Kudos to you, my dear Sir!

Edited by Roarian
Link to comment
Share on other sites

Hope it got you on the right track then :biggrin:. I skipped the tuts because I was all "I know what Im doing" and then I was like "Why does nothing work!" :psyduck: Looking at vanilla stuff that behaves similar to what your trying to make he been the best help for me so far. Hope we can all help each other out because its 2 steps forward one step back everytime I think I learn something. Im rambling .. bedtime
Link to comment
Share on other sites

  • Recently Browsing   0 members

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