PDA

View Full Version : How to Make An Effective Day/Night System



idontknow
03-19-2006, 12:11 PM
Here's how to make an effective day/night system, where you warp every x minutes when on the overworld, even after traveling across screens. (To use only for beta 9)

Say you want the player to warp from day to night & vise-versa every 2 minutes of being on the overworld, even after moving from screen to screen. Simply do the following:

1) Make 2 dmaps: One for the day overworld, the other for your night overworld. The day overworld should have a normal or bright pallette whereas the night overworld's pallette should be dark. Perhaps in the day have lively NPCs and in the night have stalfos enemies & NPCs that are sleeping or no longer there.

2) Make 2 combos: The first should be 72 tiles and 100 tics (or 100 tiles & 72 tics) Why? Because lets break down the amount of time needed for the cyclng of day & night like this:
-60 tics in a sec
-60 sec in a minute
-2 minutes in a cycle
So: 60x60x2=7200 tics
Therefore the warp needs to occur after the first combo changes to the next, approximately 7200 tics, the equivalent of 2 minutes.

*f you want to change the amount of time the warp takes place to X minutes, multiply 3600 (number of tics in a minute) by X (3600 for 1 minute, 7200 for 2 minutes, 10800 for 3 minutes, etc. This is how many tics the first combo needs to last, so for ease, you could then divide this number by 100, and that's the number of A. Frames you need with an A. Speed of 100.

3) The first combo's type should be 'none' and its 'next' combo must be the 2nd combo you're going to make, and then it should be placed on every single screen of your overworld, for both day & night dmaps. If necessary, you could hide it by placing something over it on any layer. (Keep in mind, this combo must be on layer 0 for this to work)

4) The second combo's type must be Autowarp [A]. This makes it so that when appearing on screen, that is, after being cycled to, Link will warp automatically, even if he is not touching that combo. See where i'm going with this? Because you have a combo that takes 7200 tics or about 2 minutes to cycle to this Autowarp, Link will warp after that much time. The 'timer' for each screen is really the first combo, who's animation never resets, only combo cycling resets once it has taken place (like after warping)

5) Now, you need to go to 'Side Warp' and set tab A's warp destination to that of the same screen coordinate but on the night dmap. So, say dmap 0 is your day overworld. Dmap 1 is your night. On dmap 0, each screen needs to lead to the same coordinate on dmap 1. (And vise-versa) Repeat this for your night overworld.

6) Also, on each overworld screen (and on both night & day versions), you need to check the screen flags "Direct Autowarp"

7) Repeat steps 5 & 6 for each screen for both overworld versions (both day & night dmaps). This can be tedious, to set up a sidewarp for all screens and making sure to check that the warps are direct. Also make sure that each screen has the first tile you created in step 1, so that when on any screen in your overworld, you will automatically warp when the autowarp appears, in other words, after every 2 minutes.

8) If you want it so that when something happens on a day screen, something else takes effect on that screen's night time version, you need to go to the day time screen and go to screen data. Click on the third tab (special data) Here you can set the Map # and the coordinate # of the night screen. This is Room State Carry Over. This makes it so if you trigger secrets here, then secrets are triggered on the night screen as well.

If you go to the night screen & set the data for the Room State Carry Over screen to that of the day screen, then the opposite will be true; if you then trigger secrets on the night screen, secrets on the day screen will be triggered too. You could also do this for both screens so that triggering secrets on either overworld will effect the opposite overworld (day to night, or night to day) This isn't required for all screens, just any screens where you want changes in day to cause changes at night & vise versa.

Revfan9
03-19-2006, 08:19 PM
Thanks. Now there should be no excuse for a 2.11 quest not to have a day/night system.

punkonjunk1024
03-26-2006, 02:25 PM
Except maybe how goddamn tedious that would be to create. :)

idontknow
03-26-2006, 03:46 PM
^EXACTLY!

Why so tedious?
--You have to set the side warp of every single screen on not just one but TWO overworld maps!
--You have to make sure each screen has the direct autowarp screenflag set
--You have to make sure each screen has the cycling autowarp & that its either hidden, or a camofloug (looks like the ground with no apparent animation, which would be a waste of MANY identical tiles)
--Then you need to set room state carry over data for all screens where this is necessary. This could include, but not limited to, screens where theres cave entrances you need to bomb, or when you have the same item on both the day & night versions but when you grab it in one screen, it also goes away in the other.
--And then simply changing the aesthetics of the night screen so that things are somewhat different at night, besides just a darker pallette (such as more obstacles, enemies, no people sprites, etc.)

punkonjunk1024
03-26-2006, 03:57 PM
Someone (cough jman cough) should implement "Seasonal/timed Dmaps" which would do all of that, except automatically, and without interfering. Like, the times would be set, or maybe how many screens to walk over until the season changes, and all you'd need are the Dmaps.

Or even seasonal combos! like, a combo linked to another combo, that changes depending on a state set based on like, time or number of screens crossed.

C-Dawg
04-02-2006, 02:31 PM
That clinches it, 2.11 is amazing. And this doesn't sound like a whole lot of work for some really amazing results.

-C

Revfan9
04-14-2006, 11:53 PM
Just created a little test quest that has this. It's pretty sweet.

PolygonX8
04-16-2006, 06:58 AM
Excellent idea as most of your past ones, IDK, however... one big flaw.

Bushes, grass, etc... will not restore.

EDIT: Forgot to say I made one of my own, however... it is also flawed for it does not allow changes in the OW.

Mr. Z
05-03-2006, 12:22 PM
Here's another way to make a timed dmap:
You need 3 combos: A FF change combo. An invisible meter (Or visible if you want to show the remaining time). And a clone of the meter, but an Auto Warp as combotype.

In case you don't get it yet, here's how it works:

You put the meter on a side of the screen and make it move to the other side. At the other side is the FF combo which makes it change to the next one in the list (the Auto Warp). Just give both FF combos the Carry Over flag, and you're done.

You can set the Direct Auto Warp screen flag for better results.

Just make sure you use a "No FF Carryover" screen flag on the destination screen or the timer won't reset.

Cloral
05-03-2006, 01:11 PM
That would work well for timed areas where you always enter through a specific entrance. It wouldn't work for a day/night system though.

Mr. Z
05-03-2006, 02:16 PM
With the Carry Over flags you can carry over the auto warp, but you can change its location on every screen. And with a screenflag you can make it warp you to the exact point where you were standing.
The only problem is that you can't go back the same way. But in cases where you don't need to go back that way, it works perfect.
Like... for underwater areas, where you have limited air.