Create account / Log in

Game Pieces as Locations?

Talk about module design ideas and techniques.

Moderators: uckelman, Tim M

Game Pieces as Locations?

Postby ijthompson » June 29th, 2011, 2:44 pm

Hello guys,

I'm working on a card game where some of the cards are the locations upon which some other 'character' cards move. The idea is that the game layout changes with every game, depending on which location cards are played, and where. I have my location cards non-stacking, and it's all good functionally, but I'd really like to get the reporting of moves to state these locations. Like, if I have both a 'Living Room' and a 'Backyard' location in play (just as a silly example), then I'd like to have the moves report like "Fred moves from the Living Room to the Backyard".

I've been playing around with everything, but I just can't seem to make it work. For the record, the closest I can get to the above example is "* Fred moves -> offboard -> offboard*"... i.e., I can't even get my Board name to report. Any ideas?
User avatar
ijthompson
 
Posts: 66
Joined: April 23rd, 2011, 10:33 pm
Location: Toronto, Canada

Re: Game Pieces as Locations?

Postby Brent Easton » June 29th, 2011, 9:50 pm

Hi,
I can think of one way. Here is a very rough guide, some ideas to get you going:

- Create a map Zone for each area where a location card might be played.
- Add a Global Property named Loc to each of the Zones.
- Change the 'Location Format' in each Zone from $name$ to $Loc$
- When a location card is played, have it set it's name into the Loc property of the zone it is being played in using the Set Global Property trait.

Regards,
Brent.
User avatar
Brent Easton
 
Posts: 3090
Joined: December 21st, 2007, 3:06 am
Location: Berry, NSW, Australia

Re: Game Pieces as Locations?

Postby ijthompson » June 30th, 2011, 2:06 am

Hey, thanks Brent! I'll get to work on this, and let you know how it goes...
User avatar
ijthompson
 
Posts: 66
Joined: April 23rd, 2011, 10:33 pm
Location: Toronto, Canada

Re: Game Pieces as Locations?

Postby ijthompson » July 2nd, 2011, 12:42 pm

swampwallaby wrote:- When a location card is played, have it set it's name into the Loc property of the zone it is being played in using the Set Global Property trait.


Hoo boy... I think this last bit might be way over my head. Is there any place to read about how this might be done? The Set Global Property page (http://www.vassalengine.org/wiki/SetGlobalProperty) page doesn't really reveal too much...
User avatar
ijthompson
 
Posts: 66
Joined: April 23rd, 2011, 10:33 pm
Location: Toronto, Canada

Re: [messages] [Module Design] Re: Game Pieces as Locations?

Postby Brent Easton » July 3rd, 2011, 3:21 am

Hi,

It's not too hard.

You will need to use the capability in a Map the issues a Key Stroke to every counter that ends it's movement on that map. Say this is Ctrl-A. Most of your pieces will just ignore Ctrl-A, but the terrain cards will have a Set Global Property trait keyed to Ctrl-A. Just enter the Global Property Name as Loc and create a new Key Command with a Key Command of Ctrl-A, a type of 'Set value directly' and a New Value of $PieceName$. This can be set up in a prototype.

Now, when a you drop a terrain piece into a zone, the map will send it Ctrl-A which will activate the Set Global property trait to place the name of the terrain Card into the Loc property of the Zone.

The default action of Set Global Property works by trying first to find the named Property in the current zone. If it does not exist, it checks the current map, then if still not found, it checks for global properties.

Regards,
Brent.


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

On 2/07/2011 at 5:42 AM ijthompson wrote:

>"swampwallaby" wrote:
>> - When a location card is played, have it set it's name into the Loc
>> property of the zone it is being played in using the Set Global
>> Property trait.
>
>
>Hoo boy... I think this last bit might be _way_ over my head. Is there
>any place to read about how this might be done? The Set Global Property
>page http://www.vassalengine.org/wiki/SetGlobalProperty page doesn't
>really reveal too much...
User avatar
Brent Easton
 
Posts: 3090
Joined: December 21st, 2007, 3:06 am
Location: Berry, NSW, Australia

Re: Game Pieces as Locations?

Postby ijthompson » July 4th, 2011, 2:23 pm

Man, I've followed your instructions to the letter, and it just ain't happening - it just leaves out any description of the location at all.

Do you think the problem could have arisen from this other, earlier problem I was having? :

ijthompson wrote:For the record, the closest I can get to the above example is "* Fred moves -> offboard -> offboard*"... i.e., I can't even get my Board name to report. Any ideas?
User avatar
ijthompson
 
Posts: 66
Joined: April 23rd, 2011, 10:33 pm
Location: Toronto, Canada

Re: [messages] [Module Design] Re: Game Pieces as Locations?

Postby Brent Easton » July 4th, 2011, 9:05 pm

Is it possible to have a look at your module?

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

On 4/07/2011 at 7:23 AM ijthompson wrote:

>Man, I've followed your instructions to the letter, and it just ain't
>happening - it just leaves out any description of the location at all.
>
>Do you think the problem could have arisen from this other, earlier
>problem I was having? :
>
>
>"ijthompson" wrote:
>> For the record, the closest I can get to the above example is "* Fred
>> moves -> offboard -> offboard*"... i.e., I can't even get my Board
>> name to report. Any ideas?
User avatar
Brent Easton
 
Posts: 3090
Joined: December 21st, 2007, 3:06 am
Location: Berry, NSW, Australia

Re: Game Pieces as Locations?

Postby ijthompson » July 5th, 2011, 8:59 pm

Definitely - I'd be happy if you did!

Link coming via PM. :)
User avatar
ijthompson
 
Posts: 66
Joined: April 23rd, 2011, 10:33 pm
Location: Toronto, Canada

Re: Game Pieces as Locations?

Postby Brent Easton » July 6th, 2011, 1:10 am

Well,

I'm afraid I have good news and bad news.

The good news is that I forgot to mention that to have a map or zone report a location as part of movement, it must have a grid. Just add an irregular grid to the Zone and define 1 point where you want the card to snap. This solves you non-snapping point also.

The bad news is that it is not actually possible to include Global Variable names in the movement reports or grid location formats. I had not realised this when I suggested this method, I apologize for that. It sounded like a good idea at the time :)

There is another way though. You will need to turn off the movement reporting in the Map (Set the Auto-report field in the Map to blank) and handle the reporting of the movement yourself in each counter with a Report Action trait keyed to your map movement key Ctrl-Shift-A. A Report Action message can include any Global variables at all. Reporting the 'From' location is a little tricky, you will need to store it in a Dynamic Property in the counter each time you land somewhere, so that you can report it when you leave. Otherwise, just usa a 'X moves to Here' type message.

Hope this helps,
Brent.
User avatar
Brent Easton
 
Posts: 3090
Joined: December 21st, 2007, 3:06 am
Location: Berry, NSW, Australia

Re: Game Pieces as Locations?

Postby Tim M » July 6th, 2011, 1:17 am

swampwallaby wrote:The bad news is that it is not actually possible to include Global Variable names in the movement reports or grid location formats. I had not realised this when I suggested this method, I apologize for that. It sounded like a good idea at the time :)

Brent.



It still is, just hasn't happened yet :wink:
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: 1812
Joined: December 8th, 2007, 12:22 pm
Location: Earth

Re: Game Pieces as Locations?

Postby ijthompson » July 6th, 2011, 1:06 pm

Thank you for the help!

It could be a day or two before I can sit down with this again, but I'll be looking forward to seeing if I can make this happen...
User avatar
ijthompson
 
Posts: 66
Joined: April 23rd, 2011, 10:33 pm
Location: Toronto, Canada

Re: Game Pieces as Locations?

Postby ijthompson » July 7th, 2011, 2:41 am

Just a quick note (not bumping the thread, I swear! :P ): I didn't have time to try the new method, but it occurred to me that Movement Trails might be a simple and more elegant way to go. I tried adding them to the relevant prototypes, and they don't show up at all! Is there something wrong with Movement Trails right now? Not to derail the thread...
User avatar
ijthompson
 
Posts: 66
Joined: April 23rd, 2011, 10:33 pm
Location: Toronto, Canada

Re: [messages] [Module Design] Re: Game Pieces as Locations?

Postby Brent Easton » July 7th, 2011, 3:40 am

One thing I noticed when playing with your module was that your 'Start Game' is actually a pre-defined startup of a save file. This means that no changes you make to counters will EVER be visible in the module. I had to add a new 'no options' start game to be able to re-create a game from scratch.

Regards,
Brent.

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

On 6/07/2011 at 7:41 PM ijthompson wrote:

>Just a quick note (not bumping the thread, I swear! :P ): I didn't have
>time to try the new method, but it occurred to me that Movement Trails
>might be a simple and more elegant way to go. I tried adding them to the
>relevant prototypes, and they don't show up at all! Is there something
>wrong with Movement Trails right now? Not to derail the thread...
User avatar
Brent Easton
 
Posts: 3090
Joined: December 21st, 2007, 3:06 am
Location: Berry, NSW, Australia

Re: Game Pieces as Locations?

Postby ijthompson » July 10th, 2011, 2:21 pm

D'oh! THAT certainly changes things! :P

For the record, I made that pre-defined setup because in a proper game, those particular cards will need to begin in that particular place (and I wanted to save myself some work since those are the cards I need to tinker around with the most). However, it's clear to me now that pre-defined setups are things that I should be saving for the FINAL step of module creation! :lol:

Okay, off to work on this...
User avatar
ijthompson
 
Posts: 66
Joined: April 23rd, 2011, 10:33 pm
Location: Toronto, Canada


Return to Module Design

Who is online

Users browsing this forum: No registered users and 2 guests