One more question,
I want to know how to flip character graphic in game
THanks ~
-----edit : resolved-----
Actually, the easiest way would be to just get a charset with the graphics flipped, then use an event to change the graphic.
Quote from: ForeverZer0 on April 20, 2011, 01:35:18 am
Actually, the easiest way would be to just get a charset with the graphics flipped, then use an event to change the graphic.
it's the easiest method but... what should i say...
I wanted to do it with a script to reduce graphics needed
I want to use it for all event in certain map,
to create flipped version on each graphics will increase a lot of size
If you have light coming from a specific angle simply mirroring the graphic may not look right.
Consider if this is the case for the character graphics you want flipped because you'd get a better result spriting the flipped character to reflect the light.
*hugs*
class Scene_Map
attr_accessor :spriteset
end
class Spriteset_Map
attr_accessor :character_sprites
end
module ShadowSaber
def self.flip
$scene.spriteset.character_sprites.each {|chr| chr.angle += 180 }
end
end
Just use the script call "ShadowSaber.flip"
This is about as down and dirty as it gets. With a couple more minutes, it could actually be scripted properly...
Isn't that rotation by 180 and not flipping? Under flipping I'd understand a horizontal or a vertical flip. There's always Sprite#mirror that can be set to true in that case.
Yeah, but as far as mirroring goes on character sprite, its basically just the sprite facing the opposite direction. I kind of assumed he meant vertically.
ShadowSaber?
a true vertical flip would rotate 180 AND mirror it
oooooh, and the shit just got deeper.... :haha:
-----removed-----
One-liners, ew.
thanks drago :haha: