domrein / flixel-haxe Goto Github PK
View Code? Open in Web Editor NEWPort of Flixel game engine to haXe with a focus on iOS development
Port of Flixel game engine to haXe with a focus on iOS development
When a sprite is rotated, it's alpha channels become corrupted and display as opaque white instead of the correct alpha.
In renderSprite(), if the advanced renderer is used, there is a class cast error when using flash9. This is because it's impossible to cast a String into a BlendMode.
I resolved this by changing the property "blend" in FlxSprite from String to BlendMode and by removing the cast. It works fine for flash9 but I didn't try to compile for another target.
Create a default control overlay for games on iOS. This overlay should support the default Flixel controls (arrow keys and x,c). The default overlay class should fire the appropriate "keyboard" inputs so that input methods are compatible across platforms.
Use DrawTiles instead of CopyPixels for a performance boost when rendering on iOS.
okay... i have just tried this engine...
and found a bug...
in FlxGame, line 502
this line
switchState(Type.createInstance(Type.resolveClass("PlayState"), []));
must be
switchState(Type.createInstance(_iState, []));
When the game engine is paused while a sound is playing, that sound's SOUND_COMPLETE event doesn't get hooked back up when the engine is un-paused and thus the playing field incorrectly indicates that the sound is still playing.
The play() function in the FlxSound.hx file should be changed to:
public function play():Void
{
if(_position < 0)
return;
if(_looped)
{
if(_position == 0)
{
if(_channel == null)
_channel = _sound.play(0,9999,_transform);
if(_channel == null)
active = false;
}
else
{
_channel = _sound.play(_position,0,_transform);
if(_channel == null)
active = false;
else
_channel.addEventListener(Event.SOUND_COMPLETE, looped);
}
}
else
{
if(_position == 0)
{
if(_channel == null)
{
_channel = _sound.play(0,0,_transform);
if(_channel == null)
active = false;
else
_channel.addEventListener(Event.SOUND_COMPLETE, stopped);
}
}
else
{
_channel = _sound.play(_position,0,_transform);
if(_channel == null)
active = false;
else
_channel.addEventListener(Event.SOUND_COMPLETE, stopped);
}
}
playing = (_channel != null);
_position = 0;
}
As can be seen in Mode-Haxe, the keyboard inputs only partially work.
There are several places throughout the engine where values that should be floating point are being stored as integers. This is causing several different problems.
FlxText doesn't display
I have a transparent object that the play needs to collide with to update the scores, this object should be killed on collision with .kill() , the object dies but does not count the death when I use countDead(), returns "GL Error: 1282 480x25" in iOS simulator. Works in Neko target.
As can be seen in Mode-Haxe, when using FlxGroups and passing the members variable to other classes, the array reference is somehow changed resulting in null pointer errors.
A declarative, efficient, and flexible JavaScript library for building user interfaces.
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. ๐๐๐
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google โค๏ธ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.