auto-reveal invisible units

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.

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. :smiley:

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

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

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
forums.vassalengine.org/mailman/ … engine.org

Post generated using Mail2Forum (mail2forum.com)

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…)

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.

Thus spake “evmanstein”:

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
forums.vassalengine.org/mailman/ … engine.org

Post generated using Mail2Forum (mail2forum.com)