Welcome, Guest. Please login or register. Did you miss your activation email?

Author Topic: Spell Effects  (Read 3140 times)

0 Members and 2 Guests are viewing this topic.

Megatron

  • Newbie
  • *
  • Posts: 22
    • View Profile
Spell Effects
« on: July 13, 2011, 05:36:09 am »
I'm not sure if this is outside the bounds of what this board covers, but I figured I'd ask.

I want to be able to achieve spell effects that cause a fragmenting/discoloring effect on the sprite. The first couple seconds of shows what i meant. When the enemy get's hit by an electric attack, the effect I'd like to achieve activates (in yellow).

I'll have to use shaders to do this (if I don't, other, practical ways to do it would be extremely helpful). I have no idea where to start with a shader like this (beyond the obvious - using time and base color as parameters), and was curious if someone had something similar I could use as a base, or had a good idea where to start. I know the basic of glsl, but was hoping to spare myself some pain if someone has something like this already or could provide a starting point.

Any help would be appreciated,

thanks[/url]

aeron

  • Newbie
  • *
  • Posts: 9
    • MSN Messenger - aeron005@gmail.com
    • View Profile
    • http://aeron.uni.cc/
Spell Effects
« Reply #1 on: July 13, 2011, 07:03:17 am »
The effect you are referring to is implemented with a technique called color cycling, very common in retro games. Back then, they used hardware limitations to their advantage by shifting palette colors around to imitate animation at almost no processing cost. Unfortunately it can be a bit hard to represent on high-level hardware, but a few people still do it. Check out the demos here:

http://www.effectgames.com/effect/article.psp.html/joe/Old_School_Color_Cycling_with_HTML5

If you play around in the options you can see the palette as the image changes. Also, a friend of mine whipped up something similar in opengl, I can try and track it down for ya.

Over and out

Megatron

  • Newbie
  • *
  • Posts: 22
    • View Profile
Spell Effects
« Reply #2 on: July 15, 2011, 12:54:25 am »
If you could that'd be great.

I've been able to get okay results by either "yellowfying" all the points in the sprite or gray scaling then multiplying by yellow, but neither of them quite achieve the effect displayed in that video

section_two

  • Newbie
  • *
  • Posts: 19
    • View Profile
Spell Effects
« Reply #3 on: August 01, 2011, 04:43:06 am »
Hi,take a screenshot of the sprite in youtube. If you have gimp, load the image   and look at Threshold, in the menu Color. Its very similar the way the color change, when you change the parameters. Maybe tinting the result of a threshold B/N shader its a start.

Or, in gimp, make every sprite , and just make an animation.
In gimp make a mask layer with the threshold effect, and tint yellow the next layer.....something like that.
Bye.