Create account / Log in

auto-reveal invisible units

Topics related to the main Vassal engine.

Moderators: uckelman, Tim M

auto-reveal invisible units

Postby rfdoane » October 4th, 2009, 7:06 pm

Does anyone know a good way to make pieces belonging to one side automatically reveal invisible pieces belonging to another side? I'm using a GKC to fire a trigger that reveals all invisible pieces within 5 hexes of the moving unit. The problem is the invisibility trait itself. In order to reveal invisibile units, that side must be listed in the "Can be hidden by...." selections, which means they can also see the enemy units when they are hidden. I haven't been able to figure out a way to work around this yet.
rfdoane
 
Posts: 33
Joined: March 24th, 2008, 11:36 pm

Postby rfdoane » October 4th, 2009, 9:48 pm

I should be a little more specific. Here is what I'm trying to do:

Side A starts with all its pieces invisible on the map. Side B's pieces are always revealed, do not use invisibility. As B's pieces move, they should reveal any of A's pieces the instant they become 5 hexes or closer. Once revealed, A's pieces cannot become invisible again.

The problem is that if B is allowed to reveal A's pieces, that means B can see them even when they are still invisible which defeats the purpose, naturally. :D
rfdoane
 
Posts: 33
Joined: March 24th, 2008, 11:36 pm

auto-reveal invisible units

Postby Brent Easton » October 4th, 2009, 10:02 pm

*********** REPLY SEPARATOR ***********

On 4/10/2009 at 2:48 PM rfdoane wrote:

I should be a little more specific. Here is what I'm trying to do:

Side A starts with all its pieces invisible on the map. Side B's pieces
are always revealed, do not use invisibility. As B's pieces move, they
should reveal any of A's pieces the instant they become 5 hexes or closer.
Once revealed, A's pieces cannot become invisible again.

The problem is that if B is allowed to reveal A's pieces, that means B can
see them even when they are still invisible which defeats the purpose,
naturally. :D


The purpose of the Invisible trait is to make one sides pieces not findable in any way by the oppponent. What you want to do is directly opposed to this, you want to make one sides Invisible pieces available to the other in some way. This is exactly the opposite of the purpose of the Invisible trait and is the reason you cannot use the invisible trait to do this.

One way to do this is to implement the invisibility yourself using a layer. Create a piece with no Basic Piece image and a layer with several levels, one of which is a transparent image. Your player B pieces can then make the player A counters appear using ranged Global Key Commands.

B.


_______________________________________________
Messages mailing list
Messages@forums.vassalengine.org
http://forums.vassalengine.org/mailman/ ... engine.org

Post generated using Mail2Forum (http://www.mail2forum.com)
User avatar
Brent Easton
 
Posts: 2991
Joined: December 21st, 2007, 3:06 am
Location: Berry, NSW, Australia

Automated Spotting in Panzerblitz

Postby evmanstein » January 4th, 2010, 3:21 am

I suppose this is as good a spot as any to add this question (or request/observation). I've been taking a growing interest in Vassal, and have been playing Panzerblitz for years, and always thought an automated reveal operation for spotting units hidden in bushes or behind hills when a moving enemy unit enters a given hex would be a VERY cool addition to the basic game, and something which computerization should be fundamentally perfect for (conceptually, that is to say). Having developed a couple of trivial Vassal modules and browsed the development directory and this forum, I am concluding that there is not actually that capability built into Vassal at this time.

Even though I'm a long time software developer, I've not yet had any need to pick up Java (though I might be motivated to eventually) so any Javanese would be foreign at the moment, but the concepts are certainly clear.

How big a challenge would something like this be to do? What sort of knowledge and skills would it take? Or is there something already in place to provide this capability?

Just curious! (and maybe serious...)
evmanstein
 
Posts: 4
Joined: December 23rd, 2009, 6:30 am

Automated Spotting in Panzerblitz (II)

Postby evmanstein » January 4th, 2010, 3:24 am

I should add that using the Hidden trait and having an observer perform this action is already clearly doable. What I'm suggesting is the possibility of having the Vassal system perform this function in place of the moderator. Obviously, there would be some significant logic that each reveal check would need to employ, but depending upon what structure is used to store the data that is the mapboard, some reasonable algorithmns seem plausible.
evmanstein
 
Posts: 4
Joined: December 23rd, 2009, 6:30 am

auto-reveal invisible units

Postby uckelman » January 7th, 2010, 10:59 pm

Thus spake "evmanstein":
How big a challenge would something like this be to do? What sort of knowledg
e and skills would it take? Or is there something already in place to provide
this capability?


The right way to do this would be to create a generic engine for handling
LOS. I think Brent did some initial work on this a while back, but my
memory is failing me.

--
J.

_______________________________________________
Messages mailing list
Messages@forums.vassalengine.org
http://forums.vassalengine.org/mailman/ ... engine.org

Post generated using Mail2Forum (http://www.mail2forum.com)
User avatar
uckelman
Site Admin
 
Posts: 8617
Joined: December 10th, 2007, 9:48 am
Location: Durham, England


Return to General Discussion

Who is online

Users browsing this forum: No registered users and 2 guests