Member
Join Date: May 2013
Posts: 43
|
Hi,
Hoping this hasn't been answered before as I can't find it in the forums already, please feel free to flame me and point me at it if I've missed it. I've created a new class which is a hybrid of a fighter and cleric class but with both parent classes significantly weakened so as not to create an OP new class. I'm not even sure it is possible but I'm wishing to have the class be weapon focused, i.e. receive benefits from a specific type of weapon (Warhammer) which increases per number of levels, +1 for every six to be precise. i.e. As long as the character is wielding a warhammer he/she will receive an additional +1 to attack and damage at first level and for every six subsequent levels attained (7th, 13th, 19th). I cannot figure out how to do this from any tutorials or manuals I have studied. Could anyone point me in the right direction? I'm not asking for it to be done for me, just for someone to suggest any previously designed classes, abilities etc that achieve something similar and maybe provide the .user file I can load to look at how it's been achieved, or otherwise guide me via advice on how to do it. Thanks in advance, Zim |
#1 |
Senior Member
Join Date: Aug 2010
Posts: 1,528
|
This sounds very much like the new Warpriest class in the Advanced Class Guide playtest materials. You might want to see if that does what you want with no need to create your own class. At least, it may help with your question.
|
#2 |
Senior Member
Join Date: Oct 2011
Posts: 6,793
|
What kind of bonus to attack and damage is it? Does it stack with all other bonuses or is it typed?
|
#3 |
Member
Join Date: May 2013
Posts: 43
|
Silveras, Thanks, if the advanced class itself doesn't work for my needs, should I create a temp class from copy and look at the settings/scripts to see how it's done?
|
#4 |
Member
Join Date: May 2013
Posts: 43
|
|
#5 |
Senior Member
Join Date: Oct 2011
Posts: 6,793
|
Then all you need to do is calculate the bonus, foreach through all warhammers on the hero, and apply the bonus
Post-Level 10000 Code:
~ Calculate our bonus, start off with 1 field[abValue].value += 1 ~ Then at 7th and every 6 levels after, increase it by 1 var extrabonus as number extrabonus = field[xAllLev].value - 1 extrabonus = round(bonus/6,0,-1) field[abValue].value += extrabonus Post-Attr 10000 Code:
doneif (tagis[Helper.SpcDisable] <> 0) doneif (tagis[Helper.ShowSpec] = 0) foreach pick in hero from BaseWep where "IsWeapon.wWarhammer" eachpick.field[Bonus].value += field[abValue].value nexteach |
#6 |
Member
Join Date: May 2013
Posts: 43
|
Quote:
Zim |
|
#7 |
Member
Join Date: May 2013
Posts: 43
|
Quote:
Thanks |
|
#8 |
Senior Member
Join Date: Oct 2011
Posts: 6,793
|
Sorry for the slow reply, I'm currently taking a few days off. Happy new year!
First of all, are they in 2 separate eval scripts as I put them above? And what priorities did you set the eval scripts to run at? You can use the debug command to output info during an eval script. For example, if you're calculating the value of abValue and want to check where things are going wrong, it might look something like this: Code:
debug "At the start, our abValue is " & field[abValue].value field[abValue].value += 5 debug "At point 1, our abValue is " & field[abValue].value DO SOME WEIRD STUFF debug "At point 2, our abValue is " & field[abValue].value DO OTHER WEIRD STUFF debug "At point 3, our abValue is " & field[abValue].value field[abValue].value = round(field[abValue].value/2,0,-1) debug "Our final abValue is " & field[abValue].value If you, for example, see the total you expected at point 2, but then got the unexpected value at Point 3, then you know to look for something wrong in the OTHER WEIRD STUFF section of the code. |
#9 |
Member
Join Date: May 2013
Posts: 43
|
Quote:
Cheers |
|
#10 |
|
|