View Single Post
dwobbit
Junior Member
 
Join Date: Jan 2020
Posts: 12

Old March 27th, 2023, 02:11 PM
This is what I did but the button does not generate any numbers:

Code:
<portal
	id="Random"
	style="actBig"
	tiptext="Click here to randomly generate attributes.">
	<action
		action="trigger"
		buttontext="Roll Stats"
		confirm="This will generate random values for all attributes. Proceed?">
		<trigger><![CDATA[
		hero.child[attrStr].field[trtUser].value = random(6) + random(6) + 1
		hero.child[attrAgl].field[trtUser].value = random(6) + random(6) + 1
		hero.child[attrCon].field[trtUser].value = random(6) + random(6) + 1
		hero.child[attrInt].field[trtUser].value = random(6) + random(6) + 1
		hero.child[attrEdu].field[trtUser].value = random(6) + random(6) + 1
		hero.child[attrChr].field[trtUser].value = random(6) + random(6) + 1
		]]></trigger>
	</action>
</portal>
Any ideas?

Last edited by dwobbit; March 27th, 2023 at 05:47 PM.
dwobbit is offline   #3 Reply With Quote