I’m trying to change properties of the image to change it’s angle, flip it, etc and I’ve read here: http://useflashpunk.net/docs/net/flashpunk/graphics/Image.html but I can’t figure out how to make it work.
I tried modifying the PLAYER_IMAGE with .flipped = true, angle = 40, etc but the image doesn’t change.
I tried the same with graphic but it gets an error and I can’t run it.
package
{
import net.flashpunk.Entity;
import net.flashpunk.graphics.Image;
import net.flashpunk.utils.Input;
import net.flashpunk.utils.Key;
public class GameEntity extends Entity
{
[Embed(source = "assets/sprites/player.png")] private const PLAYER_IMAGE:Class;
public function GameEntity()
{
graphic = new Image(PLAYER_IMAGE);
//PLAYER_IMAGE.flipped = true;
setHitbox(24, 32);
type = "player";
}
}