10-31-2012, 02:47 AM (This post was last modified: 09-25-2024, 11:33 PM by kyonides.)
KTimers XP
Version 1.1.0
by Kyonides
Introduction
This script should let you create events like growing plants. The benefits are interesting, you won't find any timer on screen and the corresponding timers will keep running even if you're on another map. Don't worry about them running forever, they'll stop right after they reach their "ripe stage". Only a player hitting the OK button while standing right in front of the event could reset the timers.
Instructions
Create a multi-page event with its graphics.
On the first page leave a comment like this one:
Code:
timer 1 refresh 15
That means the event will use a timer with x stages and will count till 15 seconds before the next stage begins (that means it will change to the next page on the event list).
On the last page add a script call:
Code:
reset_timer
That will help you reset the growing plant event. It will be activated once the player hits the OK button while standing right in front of the event.
Also take a look at the script and search for the STAGES Constant and edit it at your will.
Example:
Code:
STAGES = {1 => 2, 2 => 3, 3 => 5}
# Timer Type => Number of stages (that means Number of event pages - 1)
As you might have figured it out by now, the timer ID on the comment you left at the growing plant event corresponds to some kind of Timer Type of the STAGES Constant.
Free for non-commercial games.
Donations aka voluntary payments are accept if going commercial.
Due credit is not optional but a must.
Check out my signature below!
"For God has not destined us for wrath, but for obtaining salvation through our Lord Jesus Christ," 1 Thessalonians 5:9
Maranatha!
The Internet might be either your friend or enemy. It just depends on whether or not she has a bad hair day.
This sounds quite usefull certainly =D
I've downloaded your Demo to give it a try, only...it crashes right at the start XD'
"Unable to find file Data/Map003.rxdata."
Since the start point is set there aparently, this prevents the game from running. After setitng the start point on one of the other maps, fixing a broken teleport that lead to map three as well and giving the signs the Direction Fix Tag I looked at the actuall commands in the growing events.
I have not tested this to it's limits yet, but it seems to be working just fine =)
Only with the crystal at the bottom of map two I am not sure.
Friendship is born at that moment when one person says to another: "What! You, too? Thought I was the only one." (C.S. Lewis) For the time you're laughing, there's nothing wrong in the world. (Colin Mochrie) If it's funny, make sure people laugh. If it's not funny, make it funny (unless it's actually really serious). (silvercheers)
Please don't spell my name "Yamina-chan". It's all small. Thank you =D
Oh, I forgot to say that I had to delete it because it was no longer in use, two maps were more than enough to prove my point or so I thought before reading your post. Well, I'll fix that but at least it's something simple that people can handle properly. Obviously it's not the idea to let you go through all those weird situations. I'd be uploading a new demo in a bit.
The event that was located at the bottom was not supposed to work with the script but it was a test engine to check whether or not it was easier to perform the same tasks by use of the usual command event commands. That's why it shouldn't work at all but the new demo doesn't include such event anymore.
EDIT
New demo's already available! It just needs less than 200 KB of harddisk space.
"For God has not destined us for wrath, but for obtaining salvation through our Lord Jesus Christ," 1 Thessalonians 5:9
Maranatha!
The Internet might be either your friend or enemy. It just depends on whether or not she has a bad hair day.
07-03-2021, 02:26 AM (This post was last modified: 07-03-2021, 04:11 AM by kyonides.)
Bug Fix Available!
KTimers XP has now reached the 1.0.2 milestone!
After all these years, a forumer reported a weird bug on another board. I took a look at it and decided I could change a few lines as a way to prevent it from ever returning. I just hope she won't break it any time soon.
"For God has not destined us for wrath, but for obtaining salvation through our Lord Jesus Christ," 1 Thessalonians 5:9
Maranatha!
The Internet might be either your friend or enemy. It just depends on whether or not she has a bad hair day.
12-27-2023, 04:59 AM (This post was last modified: 03-29-2024, 12:28 AM by kyonides.)
Version 1.1.0 is Now Available!
Go Download any of the 2 Existing Ports Now!
This brand new release brings an interesting feature, failing crops!
Nope, there's no need to hire a witch to destroy your crops.
You just need to pass a condition and it will determine whether or not you will get your crop or byproduct.
12-27-2023, 08:42 AM (This post was last modified: 12-27-2023, 10:13 AM by kyonides.
Edit Reason: Added Snapshots
)
It's Official!
This Script Has Been Ported to RMVX ACE!
Now version 1.1.0 is finally available on all 3 RGSS-based engines!
I thought it would just require a single change in code to port it to VX and ACE, but RGSS3 had no command_end so I had to get creative here. Only to find out all of a sudden that $game_system never gets updated like it does in XP and VX. So $game_timer had to come to the rescue.
4 Snapshots
"For God has not destined us for wrath, but for obtaining salvation through our Lord Jesus Christ," 1 Thessalonians 5:9
Maranatha!
The Internet might be either your friend or enemy. It just depends on whether or not she has a bad hair day.
04-29-2024, 06:20 PM (This post was last modified: 04-29-2024, 06:20 PM by kyonides.)
The RMXP Port Has Been Updated!
It reached the 1.2.0 milestone already!
I noticed that there was no way to limit the sowing process from triggering if the game developer wanted to use a game switch. This made me add a new script call to make it possible.
There's just one caveat: it would only work as part of a conditional branch.
The Explanation
The reasoning behind this is that the script would turn them into automatic / parallel events even if they were located on a different map. That's why leaving the comment at the very top of the command list was and still is very important there. The conditional branch or the switch trigger broke that. This is why I had to come up with a way to make it work IF a conditional branch was used.
The New Script Call:
Code:
set_timer(TimerID, Seconds)
Example:
Code:
set_timer(1, 10)
Event Screenshot
"For God has not destined us for wrath, but for obtaining salvation through our Lord Jesus Christ," 1 Thessalonians 5:9
Maranatha!
The Internet might be either your friend or enemy. It just depends on whether or not she has a bad hair day.