[Plugin]Board, Layout2Board [Behavior] Grid Move

1 favourites
From the Asset Store
Snap to visible grid - perfect solution for any game genre
  • Update:

    Board plugin: add "condition:Pick all chess on the board" to pick all chess (and tiles) into SOL

    Chess behavior: this behavior might help user get logic index (LX, LY, LZ) and neighbor UID more easily.

    Capx

  • Thanks!!!

  • rexrainbow awesome plugin, as usual! :) Btw, I'm having a little trouble with grid move. It seems I can't grid move 2 sprites at once. Here's the CAPX of what I'm trying to do. To recreate, wait until there are no matches, then click on two adjacent tiles. Only one is moving.. :(.

  • Soybean

    Uh, do you try to swap two chess?

    The other chess will be kicked off the board when one chess occupied it's space (the same x,y,z), the kicked chess is no longer at board and it could not "move" on the board.

    Board plugin has "action: swap" to swap two chess in one action.

    Or you could assign logic Z of chess to it's UID, so that all chess will never occupy to each other, then they will never be kicked off, and could move to any (x,y) at board.

  • rexrainbow

    Still not working. I've fixed my capx because I realized the sprite for moving around needs chess behavior. It should be correct now, but the grid move is still stuck on 1 chess (the second selected chess).

    The logic swap works though. But not the physical movement. I tried moving the Z for both swapping chess (1 and 2) but when I logged the Z, it still outputs 0 (doesn't seem to work)

    Another thing, you can swap diagonally and it works, but when I redo it on the same chess sprite, it won't work.

    Btw, I tried assigning the chess on different Z values on creation, but it seems the matcher plugin is only able to match chess on Z = 0.

    Updated CAPX

    Thanks

  • Try Construct 3

    Develop games in your browser. Powerful, performant & highly capable.

    Try Now Construct 3 users don't see these ads
  • Hey rexrainbow, following question:

    Is it possible to move a chess to the chosen (clicked) tile, so that the chess doesn't overlap another chess objects while moving (evades another objects). GridMove>MoveToTarget moves the chess straight to the tile and overlaps another objects on the way.

    I think it is sort of path-finding. May be there's a work around for that?

  • xoros

    Plugin: slg_movemen, the sample capx is the answer of your question.

  • Man, thank you again! I'm speechless.

  • xoros

    You're welcome.

    Finally, I release slg_movement plugin, It had been made a long time ago.

  • Update:

    [Plugin] Board

    Add "condition:On chess kicked". It will be trigger when the chess had been kicked from board when executing "action:Add tile", "action:Add chess", "action:Move chess", since a (x,y,z) only allows one chess.

    For example, running "action:Create chess" at (1,1,1) twice, the first chess will be kicked from board.

    [Behavior] Grid move

    If set "Property:Force move" to "Yes", grid move behavior will not check "solid" and logic overlapping. And the z index of chess will be changed when overlapping to other chess (to avoid overlapping), this feature could make the chess "cross" other chess with the same z index.

    For example, there is a chess at (1,1,1). Now another chess want move from (0,0,1) to (1,2,1).

    • Finding moving path by slg_movement plugin
    • then moving chess by grid move behavior with "Force move" mode.

    The possible moving index might be

    (0,0,1) -> (1,0,1) -> (1,1,"#30") -> (1,2,1)

    Grid move behavior will change z index when logical overlapping to other chess at (1,1,1). So no chess will be kicked after this moving.

  • When I try to open test_square_grid_move, I get the following error: "Unable to load behavior in [...]Found 'GetBehaviorSettings' global, but is not a function. This behavior will not be available in the editor".

  • Angel: make sure you extract the files of the behavior in the "exporters\html5\behavior\" folder, not "plugin".

  • No, that's not it. It's installed on the right folder. I was using r109 and I've also updated to r110.2 just in case, but the result is the same.

    <img src="http://s9.postimage.org/bqlu4a1pp/behavior.png" border="0" />

  • Angel

    Uh, "rex_grid_move" is a "behavior", you should put it into "behaviors" folder.

  • Update:

    [Plugin] Board

    • Add condition & action "Pick chess at Logic X,Y", "Pick chess above tile", "Pick chess above tile UID" to pick chess into SOL above tile.

    Note: "Pick chess above tile" only pick chess above "one" tile.

    "Pick chess above tile UID" could help user pick chess instance in

    slg_movement, and Matcher plugin since they all provide expression:TileUID.

Jump to:
Active Users
There are 1 visitors browsing this topic (0 users and 1 guests)