[Plugin]Board, Layout2Board [Behavior] Grid Move

Post your completed addons to share with the community

Post » Fri Oct 10, 2014 4:18 am

iwontnamemyself wrote:@rexrainbow - I haven't been able to figure out how to get a sprite to wrap like in your capx by using touch instead of the keyboard. It seems pretty straight forward though, which is why I don't understand why I'm having an issue. Is grid move or slg movement required for the wrap to work? I don't see the layout to board plugin in you capx either. Do we not need that anymore? What's the purpose of InstGroup? It doesn't look life it's set to anything and what is the Chess.Player Boolean for?


I'll make a sample capx for moving on wrap board with touch + path finding later.
B
97
S
22
G
178
Posts: 4,119
Reputation: 104,045

Post » Fri Oct 10, 2014 4:26 am

iwontnamemyself wrote:@rexrainbow - I haven't been able to figure out how to get a sprite to wrap like in your capx by using touch instead of the keyboard. It seems pretty straight forward though, which is why I don't understand why I'm having an issue. Is grid move or slg movement required for the wrap to work? I don't see the layout to board plugin in you capx either. Do we not need that anymore? What's the purpose of InstGroup? It doesn't look life it's set to anything and what is the Chess.Player Boolean for?


Layout to board plugin is used to place existed chess or tile into board.
Or user could create tiles at runtime so that it dose not need layout to board in this case.

Instance group is used to put the picking result of move able area or moving path.

Wrap is at the property of board plugin you could set it to no to see the running result of my sample capx files.
B
97
S
22
G
178
Posts: 4,119
Reputation: 104,045

Post » Fri Oct 10, 2014 7:15 am

Update

rex_board: fix a bug.


@iwontnamemyself

Here is a sample capx which finding moving path at wrap board, and moving along this path. (Demo)


I still need to add something to allow moving at wrap board with custom events, currently it only could move using rex_grid_move behavior.
B
97
S
22
G
178
Posts: 4,119
Reputation: 104,045

Post » Fri Oct 10, 2014 2:28 pm

@rexrainbow - I'm a little confused. Are the capx and the demo suppose to be the same program? Cuz they're not. The capx link goes to the square board grid move capx, which is the one that was posted before with the player wandering through the edges. The demo however is called board move at wrap board, which looks similar to what I need, but I can't find a capx for in your dropbox anywhere.

Also, is there a way of using the wrap without using grid_move or slg_movement? I've never used them before, so I'd prefer to use Touch and drag drop, only cuz that's what I'm familiar with.

[edit] I just reread your last post and I answered my own question about grid_move and slg_movement. lol [/edit]

[edit]So apparently the demo name is board move at wrap board, but the file name is square board slg movement capx. Found it! lol [/edit]
B
8
S
1
Posts: 67
Reputation: 859

Post » Fri Oct 10, 2014 2:49 pm

@rexrainbow - Upon opening the square board slg movement capx, nothing shows up on screen except a white board with a grey border.
B
8
S
1
Posts: 67
Reputation: 859

Post » Fri Oct 10, 2014 11:36 pm

@iwontnamemyself

Sorry. The steps of playing are

1. click black( now it is gray ) chess, it will show move-able area in red tile
2. click any red tile to move on it.
B
97
S
22
G
178
Posts: 4,119
Reputation: 104,045

Post » Fri Oct 10, 2014 11:42 pm

@iwontnamemyself

It depends on you. rex_slg_movement is used to find a moving path in tiles. rex_grid_move is used to move chess logically and physically.

Or you might choose official tilemap object with official wrap behavior.
B
97
S
22
G
178
Posts: 4,119
Reputation: 104,045

Post » Sat Oct 11, 2014 12:37 am

@rexrainbow - I guess I'm gonna have to mess around with gridmove for a little while cuz I haven't been able to get this to work with just Touch.

Also, any tips or tricks on getting a variable from a single chess on a full board, without using an array?
B
8
S
1
Posts: 67
Reputation: 859

Post » Sat Oct 11, 2014 12:55 am

@iwontnamemyself

Pick chess by a condition, then you could get the variable. You could pick chess by logical XYZ, or by tile.

The wrap only happens when chess move to "wrapped" neighbor in rex_grid_move.
For example in 10x10 board, (0,0) -> (11,0).
(1,0) -> (11,0) is not "wrapped" neighbor. It will move right directly.
B
97
S
22
G
178
Posts: 4,119
Reputation: 104,045

Post » Sat Oct 11, 2014 6:49 pm

@rexrainbow - I think I've got the basics of gridmove finally and how to use it along with Touch. lol I didn't realize you had to use gridmove move to left/right/up/down. I was trying to use gridmove move to x,y when the touch end event occurrs, which is obviously wrong and has caused me to have a major headache the last 2 days. lol

I've got the blocks to wrap finally though, but they vary in distance from each other when they are repined to one another after the wrap. I have to assume I have the pin action in the wrong spot though, so hopefully that's an easy fix. lol

Thank you so much for all your help!!! I feel like I put you through the ringer. :? You will definitely get some recognition in the credits for the game when I release it. :D
B
8
S
1
Posts: 67
Reputation: 859

PreviousNext

Return to Completed Addons

Who is online

Users browsing this forum: Bitmichael and 3 guests