Jump to content

Retrieving Item Data


Samustus

Recommended Posts

What: Scripting.

 

Example: I need to get the data 'Value' (see weapons) of a specific weapon so I can use the data in an equation. In this case I need to be able to retrieve the cost/price (in caps) of any weapon so I can apply/remove a multiplier.

 

How would I go about getting the cost value? It's driving me mental.

 

 

Thanks.

Edited by Samustus
Link to comment
Share on other sites

Thanks :)

 

Got excited for a sec there, hehe. Those FOSE functions looked really handy.

 

But, I still can't find what I need, though. No worries. I guess I will have to do it all manually. Seems silly as the info is stored anyway.

 

Cheers.

Edited by Samustus
Link to comment
Share on other sites

GetValue and GetItemValue are the same function; GetItemValue is simply an alias.

 

The syntax depends on whether you want to use it on a reference or BaseForm:

 

set iValue to rItem.GetValue

OR

set iValue to GetValue SomeBaseForm

 

...where iValue is an int (short) and rItem is a reference. I'm not sure, but I think you can actually use either syntax regardless, although this is the proper method.

Link to comment
Share on other sites

*Weary Sigh*

 

Thank you.

 

From your example, I kept trying to use "SomeBaseForm.GetValue".

 

It's a learning experience, that's for sure.

 

I appreciate your time.

 

Sam.

 

P.S. By the way, rItem is a reference? As in a referenced in-world object? If so, then no wonder what I was doing was wrong.

 

EDIT: Just clicked your Feng Shui link and was blown away by the vid. That, my friend, is one of the most incredible mods I've ever seen.

Edited by Samustus
Link to comment
Share on other sites

  • Recently Browsing   0 members

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