Comments (12)
I have no idea what to do about this, if anybody wants to take point on finding out if there is a Flex 3 and Flex 4 compatible way of doing text that'd be rad!
from flixel.
Hm... am I the only one who does not see "Use Flex 3 Compatibility Mode" in the Flex SDK Version fieldset? I'm using Flex Builder 3 as a plugin for Eclipse.
from flixel.
@goshki It's in Flash Builder 4 beta 2 (new version of former Flex Builder 3)
from flixel.
Thanks for the explanation. For anyone interested in using Flixel (1.50) with Flex SDK 4 (4.0.0.10485) in Flex Builder 3, you have to do the following: go to Project Properties -> Flex Compiler -> Compiler options and in the "Additional compiler arguments" field add the following:
-compatibility-version=3.0.0
After this FlxText should display correctly.
from flixel.
I'm super interested in actually solving this big, or at least understanding it, so any leads that anybody has I would love to hear them. My sickly stumbling about on Google hasn't turned up anything yet!
from flixel.
Seems like there might be some merit to manually disabling CFF for the font embed. This is all due to the transition between Define3 and Define4 embedding. It's rather unclear to me what the actual issue is, but it appears Flex 4 uses a new Text engine and embeds things differently to match.
The below blog post and Adobe page helped me:
http://www.richardleggett.co.uk/blog/index.php/2009/03/16/definefont4embedding
http://opensource.adobe.com/wiki/display/flexsdk/Gumbo+Font+Embedding
So following the blog's advice we would change the font embed in FlxGame to the following:
[Embed(source="data/nokiafc22.ttf",fontFamily="system",cff="false")]
I'm too lazy to try this but I figured I'd post my findings.
from flixel.
It still doesn't work here. I'm following the first tutorial (Hello World) and I'm getting the 1067 error.
I'm using Flex Builder 3 (build 3.0.2.214193) and the latest version of Flixel.
Also when I go to project properties I don't see Flex Compiler, but Actionscript Compiler. Tried the compatibility Goshki said, but that gave me a different error (invalid verison specified).
Help would be appreciated.
from flixel.
Right now the only reliable solution is to use the 3.4 Flex SDK
from flixel.
-compatibility-version=3.0.0 worked for me
from flixel.
Yep, this is a weird one, I was messing around with it, changed the Metadata in FlxGame to this:
[Embed(source="data/nokiafc22.ttf",fontName="system")]
protected var SystemFont:Class;
Then I referenced SystemFont in the FlxGame constructor:
public function FlxGame(GameSizeX:uint,GameSizeY:uint,InitialState:Class,Zoom:uint=2)
{
SystemFont
...
}
And suddenly it worked! But interestingly, I can't get it to un-work. I've completely undone all of my changes, restarted flash builder, restarted the browser, cleaned my project and none of the above seemed to change anything. It just continued to work using the EXACT same code that wasn't working a few minutes ago. Weird.
Anyway, I'm not sure what exactly made it work, but I have a suspicion it's the use of 'fontName' can someone please test this as I can't seem to break it. :D
from flixel.
So the first official non-beta release of Flex 4 came out a few days ago. If you add embedAsCFF='false' to the font line that should fix the issue. So if you change the embed font line in FlxGame.as to the following text should display without using the the compatibility-version fix that now breaks a ton of other things.
[Embed(source="data/nokiafc22.ttf",fontName="system",embedAsCFF="false")] protected var SystemFont:Class;
Of course, I'm having some issues now with embeding txt files, but I dunno if that's a configuration problem on my end or something with Flex SDK 4 again.
from flixel.
awesome, it looks like that's working!! thanks mklee :)
from flixel.
Related Issues (20)
- FlxEmitter rotation problem
- FlxTilemap.ray() Result value always null HOT 1
- Missing usage of particleClass in FlxEmitter.emitParticle()
- FlxCamera follow jitters
- FlxSound.proximity is broken.
- FlxG.removeCamera does not remove the camera from FlxG.cameras
- Reloading A FlxTilemap
- Animated Tilemap - FlxAnimatedTilemap.as
- Full outline rather than shadow on FlxText HOT 1
- FlxSprite.onScreen() locks the game up if returns false. HOT 1
- Tiling Export
- Sound only plays after unpausing HOT 1
- loadRotatedGraphic Error HOT 1
- FlxG.play() not destroying FlxSound object even when AutoDestroy flag is set. HOT 1
- Error Message in flx.py HOT 1
- useDefaultHotKeys documented, not implemented HOT 2
- Flixel forums are down
- Flixel Is Dead HOT 1
- HaxeFlixel is Here!
- am I the one that still using it? HOT 2
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from flixel.