7
\$\begingroup\$

I'm using RPG-Maker-XP-like sprites (any 2D adventure/RPG style sprites). I would like to tint them so that they look different at different times of day.

Times of the day are the set of:

  • Daytime (normal)
  • Early morning (bluish?)
  • Sunrise and Sunset (orangish?)
  • Night time (dark)

What do I need to do to tint them, and make them look good, during different times of the day? Are there any "known" formulas for any of these times, like "delete the green blue component and tint heavily red+green for a sunrise effect"?

Ideally, I have just the original sprites, with no additional information or images (like spot-highlights or shadows separated out).

Finally, I'm using Silverlight/FlatRedBall for this, so I do have access to per-pixel information, as well as RGB tinting (adding, subtracting, multiplying, etc.)

\$\endgroup\$
1
  • \$\begingroup\$ For sample images, just run a Google image search for "RPG maker XP" (without the quotation marks). \$\endgroup\$
    – ashes999
    Apr 13, 2011 at 18:00

3 Answers 3

2
\$\begingroup\$

I'd suggest playing around with Photoshop (if you've got it) with different color/layer overlays, and see if you can't get the visual effect you're looking for. If you can find it, duplicate it in code.

If the sky is visible, consider the idea of fading between two different background images (night sky, day sky). If you're using sprites, you could also consider animating a moon/sun in the sky.

Also, take a look at (as in play) World of Warcraft. Yes, it's 3D, and it has a dynamically lit day/night cycle, but at the same time shadows and lighting of things is totally baked on - the shadows don't move. It's more like what you see in TV shows where they don't actually film at night, but instead film during the day and apply a night time filter. In fact you might consider googling around for how this is done for film as it might give some hints.

\$\endgroup\$
1
  • \$\begingroup\$ WoW is out of my reach, but I will try what you said -- that, or whip up an app to quickly load images and visually see how they look with various filters. \$\endgroup\$
    – ashes999
    Apr 14, 2011 at 3:35
1
\$\begingroup\$

Color temperature

But basicly it is orange at the morning and evening. White at the day. And blue is used for the night.

For creating shadows you may find useful program crazybump, which can create normal maps for 2D textures.

\$\endgroup\$
1
  • \$\begingroup\$ The Wikipedia link is quite technical. Maybe you can explain more how this answer relates to my question; I'm not too sure. \$\endgroup\$
    – ashes999
    Apr 13, 2011 at 23:30
0
\$\begingroup\$

What you want is typically called 'color blending'. There's a blog post about how to do it in silverlight here: http://blogs.silverarcade.com/silverlight-games-101/15/silverlight-blitting-and-blending-with-silverlights-writeablebitmap/

As far as what colors to use at different times of the day, that's a much harder question to answer. The colors you included in your post might work, but you might have to play around a bit with the exact values to make everything look 'good'.

It might be worth pointing out that adding shadows to the sprites would likely go a long way to improving the effect of changing the time of day.

\$\endgroup\$
1
  • \$\begingroup\$ Dynamic shadows are too tough. And colours is a hard question -- hence why I'm asking! :) \$\endgroup\$
    – ashes999
    Apr 14, 2011 at 0:45

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .