Skip to content

function : to interact with itemproperty data type

Hello,

I've noticed some time ago, that is NOT possible to "add" to custom itemproprety variable from none. There was not any way to call it from script. You already have a function that seems intended to have this behavior "IPGetItemPropertyByID (int, int, int, int, int)" but in the end is just a Wrapper </ b> so you can not use it to create a valid custom itemproperty. We're already limited by it at creating new properties for items, even when they're already done at "itempropdef.2da / itemprops.2da" and you can add them from aurora but not from script.


How to indeed make it possible with the current resources? </ b>
Well ... I think we need a way to interact with the data type deepper, I mean, actually that data type is somethink like ...

itemproperty (
int nPropID,
int nParam1,
int nParam2,
int nParam3,
int nParam4,
);

... So, we need a function that putting a value returns it's appropiate itemproperty variable. Using "-1" value to deactivate each unnecesary value, probably the same way that you already did internally in the base code when you wanted to created a new itemproperty.

Example: </ b>
itemproperty ipNWN = ItemPropertyEnhancementBonusVsSAlign (IP_CONST_ALIGNMENT_TN, 7);
itemproperty ipMyProject = ItemPropertyCustom (int nPropID, int nParam1, int nParam2, int nParam3)


If I correctly remember the nParam are related as follows:
int nPropID: Unique ID at itemprops.2da and itempropdef.2da
int nParam1: SubType.
int nParam2: ParamItemCost
int nParam3: Param1

I'm exited about this one, so it's possible that I didn't explain my self good enough.



ANOTHER IDEA: Why not to use Param1 to set CasterLevel for CastSpell itemproperty and similar ones...?





Sign In or Register to comment.