Tileset change after a certain time interval

Tralse

Map Builder
Veteran
Joined
May 18, 2015
Messages
57
Reaction score
6
First Language
English
Primarily Uses
RMVXA
Hi there, I've been stumped with this for about an hour now so I'm gonna see if anyone can take a crack at it.

I want to change a tile (i.e. the mirror) to a different tile (i.e. broken mirror) after a certain amount of time. In the particular scene, my character is walking through a dark room and several mirrors begin to break on a timer. The mirrors breaking are meant to scare the player and hurry them through the map. 

Only problem is I can't get them to change tiles. I've used the "Set move route" command, photoshopped my own image sizes to fit in the "characters" file to change the graphic, tried "change tilesets" that didn't work at all. I'm also having a problem with the autorun and parallel process function because the only way, that I've tried, the mirror changes AT ALL is if the event is in autorun mode and no erase event so my character can even move which defeats the whole purpose of RUNNING as the mirrors break.

I don't know where to begin, but I'm hungry so imma grab a sandwhich and see if any of you smart peoples can figure it out!

Here are pics of a sample enviornment:

Capture1.PNG

Capture2.PNG
 

GrandmaDeb

Modern Exteriors Posted!
Veteran
Joined
Apr 25, 2012
Messages
4,467
Reaction score
2,942
Primarily Uses
Have each mirror be a two page event. Page one unconditional not broken, page two conditional on value of a variable ( I called it "broken mirrors") being


7 or lower, 6 or lower, 5 or lower, 4 or lower, etc.


(separate controlling event) Start the event by setting the timer.


have a parallel process with a conditional statement to check the timer


Will post image in a minute


**********************************


The Parallel process will set a variable "time" to the value of the timer


Then based on that value it will set another variable for the smashing of the mirrors


You could just have the mirrors be set to the "time" value I suppose, but it is messier to change things


Here is the conditional statement. It would look nicer with a scriptlet


check tie and set variable.PNG


You can have a first part of the conditional to be "if timer less than or equal to zero" which means your timer has run out.


I like to have a wait in the parallel process of 30 - no sense check more often than every half second.


********************************************************


BTW here is a cracking mirror graphic by RYU


http://img.www5.hp-ez.com/img/white-patisserie/a_20120818-184528.png


It would use the same animation as a treasure chest, with direction fix on.
 
Last edited by a moderator:

headdie

Villager
Member
Joined
Dec 2, 2013
Messages
60
Reaction score
10
First Language
UK English
Primarily Uses
replace the mirrors with events.

the event needs to be 2 pages

the first page of each event the character picture needs seting to the mirror which will be in tileset B or C at the bottom

enter your timer information and a trigger to change the event, either a self switch or external trigger as needed

set the event to parallel process

in the second page of the event set it to look for the trigger and set the image to the broken form of the mirror

copy paste and edit as needed for the rest of the mirrors and you should be good to go
 
Last edited by a moderator:

Tralse

Map Builder
Veteran
Joined
May 18, 2015
Messages
57
Reaction score
6
First Language
English
Primarily Uses
RMVXA
Okayy guys I have literally been working on this since you posted, thanks for the RYU mirror shatter sprite, but I cannot understand this. What am I missing? I can't get the timer system running correctly but I managed to make the glass shatter so that's improvement lol. I feel so cumbersome right now, but this is the most coding, if you want to call it that, I've done on the project so far. 
 

GrandmaDeb

Modern Exteriors Posted!
Veteran
Joined
Apr 25, 2012
Messages
4,467
Reaction score
2,942
Primarily Uses
Okay, sorry. I hope I wasn't too awfully unclear. Hope this helps.


Add the mirror graphic to your game graphics, renamed with a dollar sign in front.


The mirror event will have THREE pages if you animate the cracking. Note the triggers on each page, and the sound effect has been changed from a treasure chest movement as I mentioned earlier. Also the movement is not identical to the treasure chest move route the way I have done it.


Also, the variable on page two will be different for EACH mirror. The first mirror to crack will be one, the second will be two, etc. You can make one event, test it, make sure your event works, and then make the other six copies. Edit the variable on the second page and you are good to go.







the event which controls everything will look like this:







Screenshots:




Customizing the time:

You can adjust the time down from 70 seconds if you think this takes too long. You don't have to change the mirror events to do this. Just change the timer setting on page one of the controlling event, and the increments on the conditional branches. For example, suppose you wanted it to only last 35 seconds; first you would edit the first page so that the timer was set to 35 seconds. Then on the second page you would cut the highlighted numbers in the conditional branches in half.


 
Last edited by a moderator:

DragonVine

May or May Not be Batman
Veteran
Joined
Jun 17, 2014
Messages
344
Reaction score
385
First Language
English
Primarily Uses
I have a clarifying question - do you want the mirrors to break as the player walks by them? Or specifially after a certain amount of time? It sounds like the latter, given your first post, but I want to make sure.

If you want it after an amount of time, Grandma Deb's event should do the trick. Simple and very effective.

If you want to the mirrors to crack as the player walks by, it would need a different event.
 

Tralse

Map Builder
Veteran
Joined
May 18, 2015
Messages
57
Reaction score
6
First Language
English
Primarily Uses
RMVXA
Thanks Grandma Deb for your time. I modified your method and this works perfectly for me: 

And for the future, how do I post a screenshot into a spoiler bubble?

mirrormethod.PNG
 
Last edited by a moderator:

Andar

Veteran
Veteran
Joined
Mar 5, 2013
Messages
31,358
Reaction score
7,671
First Language
German
Primarily Uses
RMMV
And for the future, how do I post a screenshot into a spoiler bubble?
The spoiler tag needs to be written, it has no direct button (or rather a very deeply hidden button in the editor).
And if I write the tag here, it'll function - so I have to add a space to make the tag visible.


just write


[spoi ler]


[/spoi ler]


but without the space arount whatever you want inside the spoiler
 

GrandmaDeb

Modern Exteriors Posted!
Veteran
Joined
Apr 25, 2012
Messages
4,467
Reaction score
2,942
Primarily Uses
I modified your method and this works perfectly for me
Ahh, so as soon as your character appears on the map, the mirrors start breaking based on an increasing wait time.


Actually MUCH more elegant than what I did! (and suited to something happening immediately upon entering the map)


Great idea. Glad you got it worked out.
 

Users Who Are Viewing This Thread (Users: 0, Guests: 1)

Latest Threads

Latest Profile Posts

Do you Find Tilesetting or Looking for Tilesets/Plugins more fun? Personally I like making my tileset for my Game (Cretaceous Park TM) xD
How many parameters is 'too many'??
Yay, now back in action Happy Christmas time, coming back!






Back in action to develop the indie game that has been long overdue... Final Fallacy. A game that keeps on giving! The development never ends as the developer thinks to be the smart cookie by coming back and beginning by saying... "Oh bother, this indie game has been long overdue..." How could one resist such? No-one c
So I was playing with filters and this looked interesting...

Versus the normal look...

Kind of gives a very different feel. :LZSexcite:

Forum statistics

Threads
105,855
Messages
1,017,007
Members
137,563
Latest member
MinyakaAeon
Top