Results 1 to 9 of 9

Thread: Game optimization

  1. Game optimization

    Hello all!

    Those who come here more often have probably read some of my posts. In that case you also saw my signature indicating that I'm working on a flash RTS. Since school and a lot of other important things are over I can now finally complete it.

    As many of you know flash is kinda limited in power, rather slow. So obviously I try to optimize my code as best as I can and I believe that's working quite well. However, since I started to program this project with almost zero knowledge about actionscript2 and it's IDE's it's all done in flash 8. This means I have several frames: pre-loader (now working correctly: thanks senocular) menu, options etc. How is this managed in flash's memory? How much influence do all of these things have on the performance in flash? And most importantly is there anything that can speed things up?

    On a different subject, would it matter if there was no campaign? Just skirmish? I could create a crappy one but even that would cost me time I'd rather spent on other things.

    Thanks.

  2. #2
    I coded AS2 for years and years and when AS3 came I was like .. gaah.. gotta start from scratch this sux. And I procrastinated for way too long.

    Here's my from the heart advice: Stop AS2. Move to AS3. It's insanely fast in comparisson and you have much greater control over memory management and performance.

    It blows, I know, but just take the leap.

  3. Quote Originally Posted by sekasi View Post
    I coded AS2 for years and years and when AS3 came I was like .. gaah.. gotta start from scratch this sux. And I procrastinated for way too long.

    Here's my from the heart advice: Stop AS2. Move to AS3. It's insanely fast in comparisson and you have much greater control over memory management and performance.

    It blows, I know, but just take the leap.
    Well I know AS2 sucks, I found that out soon enough. I also know AS3 is better. I continued this project with AS2 because I HAD to finish something. I'm always just screwing around starting games but never actually finishing anything. That's why I HAVE to complete this game, to finish something.

    I don't want to use any actionscript version to be honest. I think they all suck compared to for example c#. The reason why I started with flash is because it's easy to learn and to start with.

    I'm working an a.. well.. real RTS as we speak in XNA, c#. Especially when you get used to the awesomeness of a language like that it's hard to go back to actionscript. Which is why I need to finish this ASAP.

    I mean, maybe I could stick around with AS3.0 if they'd either fix the right mouse button, enable hard ware acceleration or gave access to the hard disc. but even then the only advantages over a language such as c# would be the abbility to play in your browser, which is not something I particularly need.

    Besides that, this is just finishing up, optimizing the game. It's almost done.


    So in short; no, stepping over to AS3, and thus restarting, is both pointless and something I don't want to do since there are way better alternatives. I hope you can understand that
    Last edited by ArmoredSandwich; July 6th, 2008 at 07:08 PM. Reason: Added stuff

  4. #4
    AS3!!!!!!!!!!!

    How much code do you have to port over to AS3? I had a pretty big game project I spent forever coding in 2, found as2 just wasn't suited for everything i wanted to do, and it took me about a week to port everything to as3...now it's more structured, faster, and a lot more flexible to work with.

    I dunno, it's up to you. If you wanted to add a campaign to your project, it'd probably be a lot easier to implement w/ as3. Just guessing tho.

    One advantage of AS you're missing with other languages is the ease of distribution once you have a finished product.
    you = function(){
    setEnabled( true );
    live();
    setEnabled( false );
    }

  5. Quote Originally Posted by therobot View Post
    AS3!!!!!!!!!!!

    How much code do you have to port over to AS3? I had a pretty big game project I spent forever coding in 2, found as2 just wasn't suited for everything i wanted to do, and it took me about a week to port everything to as3...now it's more structured, faster, and a lot more flexible to work with.

    I dunno, it's up to you. If you wanted to add a campaign to your project, it'd probably be a lot easier to implement w/ as3. Just guessing tho.

    One advantage of AS you're missing with other languages is the ease of distribution once you have a finished product.
    63 Classes or 412 kb. But I'm more or less looking to finish this in days, not weeks. So again, AS3 isn't really an option.

    It's true that it's a lot harder to spread the game when it's done, but still.. nah

  6. #6
    only 63 classes? I'd just port it over or start from scratch. AS3 is really the better choice.

    On a side note what kind of spatial partitioning are you using on your RTS? Grid, quadtree? I mean the big thing that slows flash down is rendering so culling everything before you're rendering helps a lot. And I assume you figured out the bitmap rendering with rotations and storing all the rotations as separate bitmaps in order to exploit the speed of copy pixels?

    If you need the links to where this stuff is discussed on the forum just ask and I'll look them up on my home computer.

  7. Quote Originally Posted by Sirisian View Post
    only 63 classes? I'd just port it over or start from scratch. AS3 is really the better choice.

    On a side note what kind of spatial partitioning are you using on your RTS? Grid, quadtree? I mean the big thing that slows flash down is rendering so culling everything before you're rendering helps a lot. And I assume you figured out the bitmap rendering with rotations and storing all the rotations as separate bitmaps in order to exploit the speed of copy pixels?

    If you need the links to where this stuff is discussed on the forum just ask and I'll look them up on my home computer.
    To be honest, I don't have a spatial partitioning algorithm. I know it's terrible but it's not something I could understand back when I tried to figure it out. I guess I can give it another try however, I found the tutorials available pretty crappy but if you have some particular good ones, I'd appreciate it. I bet it's the best optimization at this point if no one can inform me about the questions I actually asked

    The bitmap rendering is pretty much optimized so no worries there.

    Thanks for all your input guys

  8. #8
    wow you have been working on that game for a while, dont give up
    Zed Town- zombie killing game
    moar games at NPGAM.ES

  9. Thanks

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Tags for this Thread

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  

Home About kirupa.com Meet the Moderators Advertise

 Link to Us

 Credits

Copyright 1999 - 2012