• Please note: In an effort to ensure that all of our users feel welcome on our forums, we’ve updated our forum rules. You can review the updated rules here: http://forums.wolflair.com/showthread.php?t=5528.

    If a fellow Community member is not following the forum rules, please report the post by clicking the Report button (the red yield sign on the left) located on every post. This will notify the moderators directly. If you have any questions about these new rules, please contact support@wolflair.com.

    - The Lone Wolf Development Team

having trouble with code to create weapon from class custom ability

psych777

Well-known member
maybe it only works with custom made weapons but was trying to get a weapon to show on the weapon tab from a user selection on the class tab.

i was looking at the eval script for the Soulknife class in psionics unleashed to get an idea as that creates the mindblade weapon on the weapon tab from the users selection.
but i'm failing in my attempts to edit it to create the normal weapons on a user selection (any melee weapon) from my class custom ability. i have gotten a box with the name of the weapon to show up but get popup error saying basically it doesn't see any of the rest of the details of the weapon (att, dmg, crit, etc).

is there a way to do this for the base weapons? or will it only work with a completely fleshed out weapon (basically custom)?
 
I'm not completely clear on what you're trying to do? You have a custom special which when added to a class grants a weapon which can take any weapon's form?
 
when you add the custom special i've got an item selection for 'melee weapons' so the user selects a melee weapon. trying to script that when the weapon is selected there that it creates an entry on the weapon tab of that weapon
 
There isn't any way to add something to a character from an eval script. What you would probably have to do is bootstrap a helper "weapon" with no attributes, pull all the information from the kind of weapon your selector chooses, and then forward that information to the helper so it will mimic the chosen weapon.
 
I guess you could also rely on the user to add the correct weapon, perhaps creating an eval rule which checks if there is a weapon of the chosen kind on the hero and complains if there isn't.

I'm only speculating here, because I still don't know the details of what you're trying to do.
 
Back
Top