Lone Wolf Development Forums

Lone Wolf Development Forums (http://forums.wolflair.com/index.php)
-   HL - d20 System (http://forums.wolflair.com/forumdisplay.php?f=46)
-   -   New item material (http://forums.wolflair.com/showthread.php?t=14031)

Provos September 24th, 2011 12:13 AM

New item material
Me again.
I am having trouble with adding in some new materials for weapons and armor. I can adjust damage and weight with no problems but I cannot get the item costs to change. Here is my eval script

Phase First Priority 10000 index 1
~ Divide our weight by 2
    container.parent.field[gWeight].value /= 2

~ Reduce our damage by 1.
      container.parent.field[wDamBonus].value -= 1

~ Set our 'general cost' field to the items cost times 0.5
  container.child[gCustMagic].field[gCustCost].value *= 0.5

As always any help is appreciated

Provos September 27th, 2011 07:04 PM

Anyone have any ideas on how to do this?

Lawful_g September 29th, 2011 03:55 PM

Let me fiddle with this later on after I am finished with my current thing and I'll get back to you.

Provos September 29th, 2011 06:05 PM

One of my problems is that the develop tab enable data file debugging does not work on the pop up windows so there seems to be no way to see the field names.

Lawful_g September 29th, 2011 08:33 PM

Of which pop up windows do you speak?

Provos September 29th, 2011 08:48 PM

1 Attachment(s)
Under custom weapons. When trying to choose what material then weapon is made out of.

Lawful_g September 29th, 2011 09:03 PM

Ok, so looking at the different materials in the program it looks like there is one material that multiplies the base item cost (which is what you're shooting for, right?). Cold Iron doubles the base item cost and has this eval script:

First 10000
~ Double our weapon cost.
container.child[gCustMagic].field[gCustSCost].value *= 2

Comparing that to the relevant portion of your code:

container.child[gCustMagic].field[gCustCost].value *= 0.5

It seems that the only problem is that you are multiplying the "gCustCost" field, but you should be multiplying the "gCustSCost" field

Provos September 29th, 2011 09:23 PM

Thanks, wow, I feel dumb that I missed that.

Oh, it works now.

All times are GMT -8. The time now is 08:17 PM.

Powered by vBulletin® - Copyright ©2000 - 2020, vBulletin Solutions, Inc.
wolflair.com copyright 1998-2016 Lone Wolf Development, Inc. View our Privacy Policy here.