Lone Wolf Development Forums  

Go Back   Lone Wolf Development Forums > Hero Lab Forums > HL - d20 System
Register FAQ Community Today's Posts Search

Notices

Reply
 
Thread Tools Display Modes
bodrin
Senior Member
 
Join Date: Feb 2007
Location: Nottinghamshire, United Kingdom
Posts: 1,265

Old November 15th, 2010, 03:48 AM
I'm trying to script a Pre Req for the Psychokinetic Burst [Synergy] property from Magic Item Compendium Pg41.

I've managed to remove the Psychkinetic text from an equipped weapon so it only shows Psychokinetic Burst once added, therefore tidying up character sheet. Works a treat!

Remove Script
Code:
~ Don't show the previous version of Psychokinetic Weapon, to avoid clutter on the weapon description.

 perform hero.childfound[ipPsiPsyKi].delete[Helper.ShowSpec]
But I can't figure out how to make Psychokinetic Burst check for the Psychokinetic property and show as Valid in the selection screen!

I keep getting an Hero Lab was forced to stop compilation after the following errors were detected:

Syntax error in 'pre-requisite rule' script for Thing 'ipPsiPsyKB' on line 1
-> Reference to undeclared variable: 'validif'

Script i've tried so far.

Code:
Error Message : Psychokinetic property required.

validif (hero.childlives[ipPsiPsyKi].tagis[Helper.ShowSpec] <> 0)
Any ideas what im doing wrong?
bodrin is offline   #1 Reply With Quote
Mathias
Senior Member
Lone Wolf Staff
 
Join Date: May 2005
Posts: 13,213

Old November 15th, 2010, 07:37 AM
childlives[] is a question - it will answer 1 if the thing is there, and 0 if it isn't.
You can't transition from childlives[] to tagis[].

Code:
 
if (hero.childlives[ipPsiPsyKi] <> 0) then
  validif (hero.childfound[ipPsiPsyKi].tagis[Helper.ShowSpec] <> 0)
  endif
Mathias is online now   #2 Reply With Quote
bodrin
Senior Member
 
Join Date: Feb 2007
Location: Nottinghamshire, United Kingdom
Posts: 1,265

Old November 15th, 2010, 08:16 AM
Thanks for the clarification. I had it in the back of my mind that because I was removing the spechelper Psychokinetic then the burst version was invalidating itself.

I'll try the code later as not got hl with me at moment!
bodrin is offline   #3 Reply With Quote
bodrin
Senior Member
 
Join Date: Feb 2007
Location: Nottinghamshire, United Kingdom
Posts: 1,265

Old November 15th, 2010, 04:32 PM
Okay i've tried this script

Code:
~ Check for Psychokinetic property on weapon
~ If we are there then we're valid

if (hero.childlives[ipPsiPsyKi] <> 0) then
  validif (hero.childfound[ipPsiPsyKi].tagis[Helper.ShowSpec] <> 0)
  endif
And it's still showing an invalid red colour on the weapon!

Screen-shot attached.
Attached Images
File Type: jpg Psychokinetic.JPG (229.2 KB, 3 views)
bodrin is offline   #4 Reply With Quote
Mathias
Senior Member
Lone Wolf Staff
 
Join Date: May 2005
Posts: 13,213

Old November 15th, 2010, 04:52 PM
The weapon properties don't live in the hero, they live in a special gizmo container within the weapon.

This is why Shock and Shocking burst are two separate item powers, rather than shocking burst being an upgrade of shock.
Mathias is online now   #5 Reply With Quote
bodrin
Senior Member
 
Join Date: Feb 2007
Location: Nottinghamshire, United Kingdom
Posts: 1,265

Old November 16th, 2010, 01:04 AM
So is it possible to check for the gizmo for the purposes of a pre requisite script?
bodrin is offline   #6 Reply With Quote
Reply


Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT -8. The time now is 06:37 PM.


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