TURNING TILES?
Posts
Hi, is it possible to do the following, and if yes, any general idea on how I would do this?
1. A tile (object or whatnot... I haven't decided yet XD) that turns as the player pushes on one side (see top part of pic). Player can't push if a part of the tile is hitting the wall.
2. A platform is created after pushing a boulder (I've seen some games do this, but I forgot where)
3. Changing the entire map layout after a certain event (Still the same map, but the arrangement of tiles would be different). For example, the entire map looks like one huge square, then after talking to an NPC, the whole room would have divisions.
Thank you so much. :-)
1. A tile (object or whatnot... I haven't decided yet XD) that turns as the player pushes on one side (see top part of pic). Player can't push if a part of the tile is hitting the wall.
2. A platform is created after pushing a boulder (I've seen some games do this, but I forgot where)
3. Changing the entire map layout after a certain event (Still the same map, but the arrangement of tiles would be different). For example, the entire map looks like one huge square, then after talking to an NPC, the whole room would have divisions.
Thank you so much. :-)
My game Giadon Saga has that boulder thing.
You create an event (boulder). The event is triggered by action button.
Use a conditional branch so that the player has to face a certain
direction to use the event. Once used set the event to have a
move route.
You also need a second event that is the new floor which will
appear due to a control switch you will activate at the end
of the move route of the first event (Boulder.)
So it's like...
Condition if player is facing up
>Move Boulder Up
Else
Condition if player is facing left
>Move Boulder Left
Else
Condition if player is facing right
>Move Boulder Right
Else
Condition if player is facing down
>Move Boulder Down
Else
nothing
Break Condition
Break Condition
Break Condition
Break Condition
Just some questions. The boulder has to move one step at a time, is it fine? And since this would be true for all boulders, this is going to be a common event? Would the boulder also consider stopping if it reaches a wall or something?
Condition if player is facing up
>Move Boulder Up
Else
Condition if player is facing left
>Move Boulder Left
Else
Condition if player is facing right
>Move Boulder Right
Else
Condition if player is facing down
>Move Boulder Down
Else
nothing
Break Condition
Break Condition
Break Condition
Break Condition
Just some questions. The boulder has to move one step at a time, is it fine? And since this would be true for all boulders, this is going to be a common event? Would the boulder also consider stopping if it reaches a wall or something?
I kinda mess with boulders going on switches in Matsumori Days, but the concept sounds similar to what you want to do with creating platforms.
For the move-route, it would be simpler to set the move route on the boulder to be "1 Step Away From Hero", and ensure the "Skip if cannot move" box is checked. The event can trigger with "Action button", but my preference lately has been to do it by "Player touch".
To make the platform appear, basically, you'd need conditional branches that would check when the X/Y coordinates of the boulder match those of where the platform would appear. When all the coordinate variables match, enable a game switch.
Not sure about the rotating tiles of the first picture. I imagine the processing of that would have to check player direction to determine which direction the boxes (or whatever) are rotating, then set switches based on which position of where the "empty slot" will be located after the turn is complete.
For the move-route, it would be simpler to set the move route on the boulder to be "1 Step Away From Hero", and ensure the "Skip if cannot move" box is checked. The event can trigger with "Action button", but my preference lately has been to do it by "Player touch".
To make the platform appear, basically, you'd need conditional branches that would check when the X/Y coordinates of the boulder match those of where the platform would appear. When all the coordinate variables match, enable a game switch.
Not sure about the rotating tiles of the first picture. I imagine the processing of that would have to check player direction to determine which direction the boxes (or whatever) are rotating, then set switches based on which position of where the "empty slot" will be located after the turn is complete.
author=Marrend
I kinda mess with boulders going on switches in Matsumori Days, but the concept sounds similar to what you want to do with creating platforms.
For the move-route, it would be simpler to set the move route on the boulder to be "1 Step Away From Hero", and ensure the "Skip if cannot move" box is checked. The event can trigger with "Action button", but my preference lately has been to do it by "Player touch".
To make the platform appear, basically, you'd need conditional branches that would check when the X/Y coordinates of the boulder match those of where the platform would appear. When all the coordinate variables match, enable a game switch.
Not sure about the rotating tiles of the first picture. I imagine the processing of that would have to check player direction to determine which direction the boxes (or whatever) are rotating, then set switches based on which position of where the "empty slot" will be located after the turn is complete.
Thanks so much. The boulder thing works. I did this (Common Event)
Set Move Route: This event (Skip) :$>Move away from Player
And it works wonderfully haha.
As for the platform... How do I accomplish that?
For the map thing the easiest thing to do is create a map then
copy it. Add the new stuff you want in the second map.
Then when the event triggers transfer your player to the
new map.
You will need to insert control switches at all the transfer event that
lead into the original map. So that they will take you
to the new map instead.
Marrend sound like they know how to do that boulder thing
better than me (since I programmed my boulder to only be able
to move in one direction.)
author=kory_toombs
For the map thing the easiest thing to do is create a map then
copy it. Add the new stuff you want in the second map.
Then when the event triggers transfer your player to the
new map.
You will need to insert control switches at all the transfer event that
lead into the original map. So that they will take you
to the new map instead.
Hmm, I think that would work... Additional work load, but whatever works, haha.
I think the problem now is that turning tiles problem. I just wish there's an easy way to accomplish that one.
Well, maybe you could make the platform event graphic by making a copy of the floor tile from the tile set, and setting up a character sprite from it? There is a special character (Either "$" or "!", I forget which.) that you put at the beginning of the file name to indicate that it represents one character rather than the standard four character by four character spread.
*Edit: With the turning tile problem, each of the tiles that turn would pretty much have to be an event. Note that they are positioned in a cross fashion (i.e. "north", "south", "east", and "west" are possible positions), and that one position is empty. Considering this, it would probably be more effective to set up the box-events according to which position is empty. So, if the "north" position is empty, and the player is rotating the boxes counter-clockwise, then you turn off the switch that represents the "north" box, and turn on the switch that represents the "west" box.
Does... that make any sense whatsoever?
*Edit: With the turning tile problem, each of the tiles that turn would pretty much have to be an event. Note that they are positioned in a cross fashion (i.e. "north", "south", "east", and "west" are possible positions), and that one position is empty. Considering this, it would probably be more effective to set up the box-events according to which position is empty. So, if the "north" position is empty, and the player is rotating the boxes counter-clockwise, then you turn off the switch that represents the "north" box, and turn on the switch that represents the "west" box.
Does... that make any sense whatsoever?
author=Marrend
Well, maybe you could make the platform event graphic by making a copy of the floor tile from the tile set, and setting up a character sprite from it? There is a special character (Either "$" or "!", I forget which.) that you put at the beginning of the file name to indicate that it represents one character rather than the standard four character by four character spread.
*Edit: With the turning tile problem, each of the tiles that turn would pretty much have to be an event. Note that they are positioned in a cross fashion (i.e. "north", "south", "east", and "west" are possible positions), and that one position is empty. Considering this, it would probably be more effective to set up the box-events according to which position is empty. So, if the "north" position is empty, and the player is rotating the boxes counter-clockwise, then you turn off the switch that represents the "north" box, and turn on the switch that represents the "west" box.
Does... that make any sense whatsoever?
Sorry, I guess I wasn't able to follow through all of it, but I somewhat get the gist. I got a thought, though...
What if the event uses the condition about player facing some direction, then the boxes would appear and disappear on certain locations to imitate that it is rotating? Using the picture, If the player comes to the north part of the tile from the left, the west tile would disappear, and the southern tile would appear. Though I'm not sure if this is harder to make than the first one. :(
Logically speaking, yes. The player's facing would determine which direction the boxes are being rotated in. I mean, pressing up on the "east" box should cause a different rotation than pressing up on the "west" box!
If you want to be slick, set a move-route for the boxes to make them look like they are being rotated. You'd still use the switches to keep track of things, but player's shouldn't notice it (in theory). However, that's more of a final touch. Getting the basic system down has higher priority.
If you want to be slick, set a move-route for the boxes to make them look like they are being rotated. You'd still use the switches to keep track of things, but player's shouldn't notice it (in theory). However, that's more of a final touch. Getting the basic system down has higher priority.
author=Marrend
Logically speaking, yes. The player's facing would determine which direction the boxes are being rotated in. I mean, pressing up on the "east" box should cause a different rotation than pressing up on the "west" box!
If you want to be slick, set a move-route for the boxes to make them look like they are being rotated. You'd still use the switches to keep track of things, but player's shouldn't notice it (in theory). However, that's more of a final touch. Getting the basic system down has higher priority.
I'll give it a try and see what happens. Another question is that, is it possible to do a boulder-move thinggy on a boulder that's more than a tile size (for example, 2x2, 1x5, ect)?
Edit: I managed to start with it, but for some reasons, the tiles move continuously! Here's what I have so far..
North Tile has 1 event
page 1:
Conditional branch: player is facing left > Control Switch: [0001:NorthTile_1Left] = ON > Set Move Route: This event (Wait) :$>Move Left :$>Move Down : Else Conditional branch: player is facing right > Control Switch: [0001:NorthTile_1Right] = ON > Set Move Route: This event (Wait) :$>Move Right :$>Move Down :Else Branch End Branch End
West Tile has 3 events
page 1:
Conditional branch: player is facing down > Control Switch: [0001:WestTile_1Down] = ON > Set Move Route: This event (Wait) :$>Move Down :$>Move Right : Else Conditional branch: player is facing up > Control Switch: [0001:NorthTile_1Up] = ON > Set Move Route: This event (Wait) :$>Move Up :$>Move Right :Else Branch End Branch End
> Set Move Route: This event (Wait) :$>Move Down :$>Move Right
> Set Move Route: This event (Wait) :$>Move Up :$>Move Right
The west tile moves indefinitely.
When you put in a move command for one event, just put the same move command for the other events in the same place. When one is triggered, they all will be. But unless you setup a way to check the space in front, they could end up being mixed up.
Okay, so I did this:
North Tile
But the tiles aren't moving.
North Tile
Conditional branch: player is facing left > Set Move Route: [WestTile_1](Wait) :$>Move Down :$>Move Right > Set Move Route: This Event(Wait) :$>Move Left :$>Move Down > Set Move Route: Player(Wait) :$>Move Left :$>Move Left > Set Move Route: [EastTile_1](Wait) :$>Move Up :$>Move Left : Else Conditional branch: player is facing right > Set Move Route: [EastTile_1](Wait) :$>Move Down :$>Move Left > Set Move Route: This Event(Wait) :$>Move Right :$>Move Down > Set Move Route: Player(Wait) :$>Move Right :$>Move Right > Set Move Route: [WestTile_1](Wait) :$>Move Up :$>Move Right :Else Branch End Branch End
But the tiles aren't moving.
It could be that they are trying to move, but there is something already in that tile, so it aborts the process.
Is there an option for "ignore impossible moves"? I only know 2k3, and that would be the problem.
You could use Phasing Mode, or whatever option there is to remove collision detection during the moves. Or a second page that has them on different layers, so they don't bump.
Is there an option for "ignore impossible moves"? I only know 2k3, and that would be the problem.
You could use Phasing Mode, or whatever option there is to remove collision detection during the moves. Or a second page that has them on different layers, so they don't bump.
I'm not sure about ace if it has one...
I made sure about the existence of tiles in certain position by arranging their movement. For example, one tile moves first to free the space, then the next one moves.
EDIT:
Okay, so I managed to edit them to make them move... now, the problem is making them move correctly...
EDIT:
I got another thought, that the turning would consider where the tile is located (either N, S, W, or E of the middle tile) to perform the rotation...
For example, at the start, the N tile is on the North, the W tile is on West, and E tile on the East.
Condition 1: If the N tile is at north (it follows that W is on West and E on East)
Move W tile to south
Move N tile to West
Move E tile to North
and so forth...
It's getting more and more complicated... haha....
I made sure about the existence of tiles in certain position by arranging their movement. For example, one tile moves first to free the space, then the next one moves.
EDIT:
Okay, so I managed to edit them to make them move... now, the problem is making them move correctly...
EDIT:
I got another thought, that the turning would consider where the tile is located (either N, S, W, or E of the middle tile) to perform the rotation...
For example, at the start, the N tile is on the North, the W tile is on West, and E tile on the East.
Condition 1: If the N tile is at north (it follows that W is on West and E on East)
Move W tile to south
Move N tile to West
Move E tile to North
and so forth...
It's getting more and more complicated... haha....
author=shiningriver
I'm not sure about ace if it has one...
With Ace, there should be a check-box in the Move Route event command that says "Skip if cannot move". I mentioned this previously, but not for the turning tiles issue, specifically.
author=Marrend
For the move-route, it would be simpler to set the move route on the boulder to be "1 Step Away From Hero", and ensure the "Skip if cannot move" box is checked.
You have the right idea of specifying move routes for the boxes, but the switch needs to be enabled after the move routes, and the switch that is enabled indicates which position is empty.
author=shiningriver
I got another thought, that the turning would consider where the tile is located (either N, S, W, or E of the middle tile) to perform the rotation...
I made mention of this too.
author=Marrned
Logically speaking, yes. The player's facing would determine which direction the boxes are being rotated in. I mean, pressing up on the "east" box should cause a different rotation than pressing up on the "west" box!
I know this is confusing you, but this should be able to work with two event pages for each box. One page where the processing of rotation actually happens, and one where the box doesn't exist.
While I was playing around, I managed to get something working... I used 12 switches (4 directions for each tile, 3 tiles on that map) to check the position of each tile, and I made conditional branches and conditions per event...
North Tile:
page 1: Condition: NorthTile_1_N is On, Player Touch
The process somewhat repeats on the rest of the 4 pages, two of them are if the player is facing up and down. It kinda works, and right now I'm just tracing the code and checking if all scenarios work. So far, it does (at least for the North tile, I'm checking events if I start with the West tile). :-)
Edit:
It's actually working now, yay! As for the next challenge, I'll try to make variants of this turning tile (one flap, two straight flaps, two L flaps).
I have another question, though. is it possible to do a boulder-move thinggy on a boulder that's more than a tile size (for example, 2x2, 1x5, ect)?
North Tile:
page 1: Condition: NorthTile_1_N is On, Player Touch
@>Conditional Branch: Player is Facing Left @> Set Move Route: [WestTile_1](Wait) : : $>Through ON : : $>Move Down : : $>Move Right : : $>Through OFF @> Set Move Route: This event(Wait) : : $>Through ON : : $>Move Left : : $>Move Down : : $>Through OFF @> Set Move Route: Player(Wait) : : $>Through ON : : $>Move Left : : $>Move Left : : $>Through OFF @> Set Move Route: [EastTile_1](Wait) : : $>Through ON : : $>Move Up : : $>Move Left : : $>Through OFF @>Control Switches: [0001..0012] = OFF @>Control Switches: [0002:NorthTile_1_W]=ON @>Control Switches: [0002:WestTile_1_S]=ON @>Control Switches: [0002:EastTile_1_N]=ON : Else @>Conditional Branch: Player is Facing Right @> Set Move Route: [EastTile_1](Wait) : : $>Through ON : : $>Move Down : : $>Move Left : : $>Through OFF @> Set Move Route: This event(Wait) : : $>Through ON : : $>Move Right : : $>Move Down : : $>Through OFF @> Set Move Route: Player(Wait) : : $>Through ON : : $>Move Right : : $>Move Right : : $>Through OFF @> Set Move Route: [WestTile_1](Wait) : : $>Through ON : : $>Move Up : : $>Move Right : : $>Through OFF @>Control Switches: [0001..0012] = OFF @>Control Switches: [0002:NorthTile_1_E]=ON @>Control Switches: [0002:WestTile_1_N]=ON @>Control Switches: [0002:EastTile_1_S]=ON : Else : Branch End : Branch End
The process somewhat repeats on the rest of the 4 pages, two of them are if the player is facing up and down. It kinda works, and right now I'm just tracing the code and checking if all scenarios work. So far, it does (at least for the North tile, I'm checking events if I start with the West tile). :-)
Edit:
It's actually working now, yay! As for the next challenge, I'll try to make variants of this turning tile (one flap, two straight flaps, two L flaps).
I have another question, though. is it possible to do a boulder-move thinggy on a boulder that's more than a tile size (for example, 2x2, 1x5, ect)?
If the "$BigMonster" character sets are any indication, an event is one tile and one tile only. Even if you set up the graphic of an event to be to be larger than one tile, it's still one tile to the engine. What you'd have to do is splice up the graphic between multiple events to simulate the size of the object properly. As for actually moving the events in question, that might take a bit of finagling. You're moving more than one event, so the "1 tile away from Hero, skip if cannot move" trick won't necessarily work anymore.
*Edit: With the rotating boxes, I meant for one switch to be on/enabled at a time, but, whatever works!
*Edit2: I tried this out myself with a test-map, and got some interesting results when implementing the move-routes. I seem to have thought that a new event page would cause said event to reset it's position on the map, but that's not the case! Thankfully, there is Set Event Location to correct things. At least, I think that would work!
*Edit: With the rotating boxes, I meant for one switch to be on/enabled at a time, but, whatever works!
*Edit2: I tried this out myself with a test-map, and got some interesting results when implementing the move-routes. I seem to have thought that a new event page would cause said event to reset it's position on the map, but that's not the case! Thankfully, there is Set Event Location to correct things. At least, I think that would work!
That's... not good. I was hoping to have a simple 2x2 tile event at the least... it's gonna be a challenge... T___T
I'll try to play some more with Ace to see what can be done... but I have to go to work first... meh XD
Edit:
I felt that since I'm moving more than 1 tile at a time (in the case of a 2x2 tile and a 1x5 tile), I felt that this would also need a switch... or some switches.
Edit 2:
Though inefficient, I thought of using 4 switches for the 2x2 tile, each switch would pertain to which direction it is going to after pushed. So each tile would have to move according to which switch is turned on. I'll experiment on this and post the results later...
I'll try to play some more with Ace to see what can be done... but I have to go to work first... meh XD
Edit:
I felt that since I'm moving more than 1 tile at a time (in the case of a 2x2 tile and a 1x5 tile), I felt that this would also need a switch... or some switches.
Edit 2:
Though inefficient, I thought of using 4 switches for the 2x2 tile, each switch would pertain to which direction it is going to after pushed. So each tile would have to move according to which switch is turned on. I'll experiment on this and post the results later...
The 2x2 tile was a little awkward, since it's moving part by part and not as a whole. There's a small, annoying lag that I want to remove, but I don't know how.
I've tested this with a 2x2 tile, and it works (1Tile is on NW, 2Tile is on NE, 3Tile is on SW, 4Tile is on SE)
Settings:
Speed: 6:x4 Faster, Freq: 5:Highest (It's simply not fast enough.
Priority: Above Characters
Trigger: Player Touch
Walking Animation Off
Like what I've mentioned, it is simply not fast enough, as it acts one by one and not simultaneously. It's enough to simulate a move, but... still. :-)
I've tested this with a 2x2 tile, and it works (1Tile is on NW, 2Tile is on NE, 3Tile is on SW, 4Tile is on SE)
Settings:
Speed: 6:x4 Faster, Freq: 5:Highest (It's simply not fast enough.
Priority: Above Characters
Trigger: Player Touch
Walking Animation Off
@>Conditional Branch: Player is Facing Down @>Set Move Route: [3Tile](Wait) : : $>Through ON : : $>Move Down : : $>Through OFF @>Set Move Route: [4Tile](Wait) : : $>Through ON : : $>Move Down : : $>Through OFF @>Set Move Route: This event(Wait) : : $>Through ON : : $>Move Down : : $>Through OFF @>Set Move Route: [2Tile](Wait) : : $>Through ON : : $>Move Down : : $>Through OFF :Else @>Conditional Branch: Player is Facing Right @>Set Move Route: [2Tile](Wait) : : $>Through ON : : $>Move Right : : $>Through OFF @>Set Move Route: [4Tile](Wait) : : $>Through ON : : $>Move Right : : $>Through OFF @>Set Move Route: [3Tile](Wait) : : $>Through ON : : $>Move Right : : $>Through OFF @>Set Move Route: This event(Wait) : : $>Through ON : : $>Move Right : : $>Through OFF :Else @>Conditional Branch: Player is Facing Up @>Set Move Route: This event(Wait) : : $>Through ON : : $>Move Up : : $>Through OFF @>Set Move Route: [2Tile](Wait) : : $>Through ON : : $>Move Up : : $>Through OFF @>Set Move Route: [3Tile](Wait) : : $>Through ON : : $>Move Up : : $>Through OFF @>Set Move Route: [4Tile](Wait) : : $>Through ON : : $>Move Up : : $>Through OFF :Else @>Conditional Branch: Player is Facing Left @>Set Move Route: This event(Wait) : : $>Through ON : : $>Move Left : : $>Through OFF @>Set Move Route: [3Tile](Wait) : : $>Through ON : : $>Move Left : : $>Through OFF @>Set Move Route: [4Tile](Wait) : : $>Through ON : : $>Move Left : : $>Through OFF @>Set Move Route: [2Tile](Wait) : : $>Through ON : : $>Move Left : : $>Through OFF :Else : Branch End : Branch End : Branch End : Branch End
Like what I've mentioned, it is simply not fast enough, as it acts one by one and not simultaneously. It's enough to simulate a move, but... still. :-)















