Author Topic: Importing from old computer (problems)  (Read 1748 times)

Minverva

  • Active Member
  • ***
  • Posts: 126
  • Karma: +0/-0
    • View Profile
Importing from old computer (problems)
« on: Tue, Jan 6, 2015 »
I was finally able to get a new computer (old one broke) and transfer most of my old project, and it compiles, but I think I did something wrong and I'm not sure where to look.

As of right now, the most noticeable problem is that FlxText doesn't seem to be working. None of my texts show up anywhere, but a trace statement in FlxText shows that it is being called and running. Some of the variables appear to be messed up as well, but I could be mistaken on this because it is such a massive project and I could've been testing something at the time. Other aspects of Flixel seem to be working like the emitters, sounds and graphics.

Technical info:
Flixel 2.34

Old Computer:

Using Flash Player 10
Windows Vista
32 Bit OS

New Computer:

Using Flash Player 16
Windows 7
64 bit OS

This is a bit of a puzzle for me and I could use some help from those who have more technical aptitude and experience than myself.

The more I think about it the more I think it may have to do with my new install of FlashDevelop. FlxText is supposed to import:

   import flash.display.BitmapData;
   import flash.text.TextField;
   import flash.text.TextFormat;

but perhaps it doesn't have the right file location for them. I had to more the file location for my project to the "user" area in order to compile. In Vista I had it in the programfiles/flashdevelop/projects/myproject/ (or similar). If I could compile the project from my old location then that may just solve all these problems.

Minverva

  • Active Member
  • ***
  • Posts: 126
  • Karma: +0/-0
    • View Profile
Re: Importing from old computer (problems)
« Reply #1 on: Wed, Jan 7, 2015 »
Ok, I did get it to compile from the program files location, but the problem with FlxText not working remains. Am I supposed to use Flex,Air with Flixel as my SDK? I hope this is an install issue of some sort, because if it is a compatibility issue I don't know if I could even update this program to a new version of Flixel (and if I could it would probably take a few weeks).

Minverva

  • Active Member
  • ***
  • Posts: 126
  • Karma: +0/-0
    • View Profile
Re: Importing from old computer (problems)
« Reply #2 on: Wed, Jan 7, 2015 »
Ok, I found what appears to be the main error. Maybe someone can be saved some heartache later. My game was developed using Flex 3, but the newest (and only available version AFAIK) version of Flex is 4. In FlxGame you'll find the following lines:

//Flex v4.x SDK only (see note above):
//[Embed(source="data/nokiafc22.ttf",fontFamily="system",embedAsCFF="false")] protected var junk:String;

//Flex v3.x SDK only (see note above):
[Embed(source="data/nokiafc22.ttf",fontFamily="system")] protected var junk:String;

Comment out the version 3 embed and uncomment out the version 4 and it seems to work fine. Anyone aware of any other transversional issues with Flex?

Wing Eraser

  • Guest
Re: Importing from old computer (problems)
« Reply #3 on: Wed, Jan 7, 2015 »
Have you read the comment above the code:
Code: [Select]
NOTE: Flex 4 introduces DefineFont4, which is used by default and does not work in native text fields.
Use the embedAsCFF="false" param to switch back to DefineFont4. In earlier Flex 4 SDKs this was cff="false".
So if you are using the Flex 3.x SDK compiler, switch the embed statment below to expose the correct version.

In v2.43 flixel already went over to Flex 4.x.

Minverva

  • Active Member
  • ***
  • Posts: 126
  • Karma: +0/-0
    • View Profile
Re: Importing from old computer (problems)
« Reply #4 on: Thu, Jan 8, 2015 »
Have you read the comment above the code:
Code: [Select]
NOTE: Flex 4 introduces DefineFont4, which is used by default and does not work in native text fields.
Use the embedAsCFF="false" param to switch back to DefineFont4. In earlier Flex 4 SDKs this was cff="false".
So if you are using the Flex 3.x SDK compiler, switch the embed statment below to expose the correct version.

In v2.43 flixel already went over to Flex 4.x.

You transposed the numbers. I'm using 2.34.

I don't think I did read the comment. It seemed like an obvious switch when I saw the lines and it worked when I switched them.

Wing Eraser

  • Guest
Re: Importing from old computer (problems)
« Reply #5 on: Thu, Jan 8, 2015 »
hehe, I didn' t transposed the numbers. I actually meant since v2.43 flixel is not using Flex 3 anymore and there are no (or not much) users that still use older versions.

Minverva

  • Active Member
  • ***
  • Posts: 126
  • Karma: +0/-0
    • View Profile
Re: Importing from old computer (problems)
« Reply #6 on: Thu, Jan 8, 2015 »
hehe, I didn' t transposed the numbers. I actually meant since v2.43 flixel is not using Flex 3 anymore and there are no (or not much) users that still use older versions.

Ah okay.

I actually use such an old version because I'd previously downloaded Flixel a long time ago. I started using it much later (but didn't update it) and kind of built up my project too much with it. I think the code is too weird to actually update it to a newer version of Flixel since I basically learned with it.

After I'm done I'm absolutely going to the newest version - probably HaxeFlixel.