Create account / Log in

Score counter

Talk about module design ideas and techniques.

Moderators: Tim M, uckelman

Score counter

Postby packonn » March 1st, 2019, 1:40 pm

It is possible to change of level in a Layer trait according to a specific value?
For example, 6 levels of numbers, from 0 to 6. The current level its 0, the specific value to apply is +3, then the level must change and show 3 in the score counter with the Layer trait.
And vice versa, the current level its 4, and the specific value to apply is -2, then the level must change and show 2 in the score counter with the Layer trait.
The specific value in both cases is the movement of a piece: +3 forward and -2 backward
Thanks for advance.
User avatar
packonn
 
Posts: 63
Joined: November 5th, 2008, 4:13 pm
Location: Murcia (Spain)

Re: Score counter

Postby Tim M » March 1st, 2019, 3:33 pm

Short answer. Yes
Link the layer trait to a dynamic property trait
Tim,
Vassal Uber Geek/Guru

Problems? post your OS, Physical Mem, version of Vassal and Java plus the Module in question.
No developer can help with out that info, thx!
User avatar
Tim M
 
Posts: 1774
Joined: December 8th, 2007, 12:22 pm
Location: Earth

Re: Score counter

Postby packonn » March 2nd, 2019, 10:01 am

Tim M wrote:Short answer. Yes
Link the layer trait to a dynamic property trait

I never used dynamic property trait. You can write a simple example of how to link a layer trait to a dynamic property? Thank you.
User avatar
packonn
 
Posts: 63
Joined: November 5th, 2008, 4:13 pm
Location: Murcia (Spain)

Re: Score counter

Postby DrNostromo » March 2nd, 2019, 5:32 pm

Attached you'll find an example of what you can do with dynamic properties and layer traits.

I don't remember what I used the upper left counter for ...it was a long time ago. But the one to the right center is a kill count. You'll note that as the count gets higher, the rank changes and the influence stats in the upper right change as well. This should give you a good example to work from.

Just change the .zip extension to .vmod and you're good to go
Attachments
MultipleLayerSample.zip
(73.33 KiB) Downloaded 9 times
User avatar
DrNostromo
 
Posts: 995
Joined: December 21st, 2007, 3:54 am
Location: Wine Country, Cal. USA

Re: Score counter

Postby packonn » March 2nd, 2019, 6:40 pm

Thank you very much DrNostromo. I will try with this. My answer once I check it.
User avatar
packonn
 
Posts: 63
Joined: November 5th, 2008, 4:13 pm
Location: Murcia (Spain)


Return to Module Design

Who is online

Users browsing this forum: No registered users and 1 guest