Jump to content

  • Log In with Google      Sign In   
  • Create Account

Banner advertising on our site currently available from just $5!

1. Learn about the promo. 2. Sign up for GDNet+. 3. Set up your advert!


Member Since 22 Jul 2010
Offline Last Active Today, 02:54 AM

Posts I've Made

In Topic: Weird framerate drop

13 January 2015 - 11:48 AM

Java has a good VM and a good GC but if you want to take control of things pools are the way to go.

It shouldn't be too much hassle though, a project-wide or class-wide find and replace might even do most the work for you.

A number of vector operations create new vectors behind the scenes as well so numerous calls can start to add up allocations quickly.


While it might not be the main problem you are facing it is worth taking the time to investigate, in my experience pools make life so much easier when working one games and trying to prevent GC stutters.


Like the look of the video by the way - cool mechanic.

In Topic: Weird framerate drop

13 January 2015 - 03:22 AM

Just to echo Sean, who is probably right with regards to the cause of your issues, when writing games in languages like Java, object pools are your friend! The stop the GC having to do much work at all while your game is running.


Just have a look through your game code an if you are seeing any "new Vector2D, new GameObject, new Texture2D, or anything like that then you are already wasting CPU.


At the start of a level (or earlier) you can just create pools of these objects and then get them from your pool when you need them and put them back when you are done. The code for these are really easy to do and the impact they create in memory managed languages can be huge.



//in game loop somewhere

GameObject badGuy = GameObjectPool.getGameObject();   //new GameObject();

//later on

GameObjectPool.returnGameObject(badGuy);    //badGuy = null;


Your aim should be as close to zero allocations during game-play as possible - reuse the living crap out of everything you can.

In Topic: Programming a Level Editor

08 January 2015 - 08:12 AM



There is a little video of a "simple" level editor that the guys made for overgrowth, it is pretty neat - very few features but enough to start building levels with.

The bare minimum is a load/save level function, a load object function, and move/rotate/scale functions.

After that you can expand into material editing but in reality you can do that in the code initially easy enough.



In Topic: making a serious game in flash

30 December 2014 - 10:00 AM

Ah thanks, so they did!

While there a few versions of that game, both 2d and 3d and from fairly simple to complex destructible scenes most of the logic will take place in 2d and should be pretty straight forward!


Pretty sure flash is up to something like that.

In Topic: making a serious game in flash

30 December 2014 - 05:45 AM

Should be possible but there are some caveats. If the game is huge and complex (i.e. 3D, networked, large levls, complex behaviours, etc...) then flash will probably not be able to compete with other technologies, but then if that is your target it is going to be an uphill struggle whatever you use.



Fast to get things working,

AS3 is easy to develop in and debug (especially with the right ide - use FlashDevelop it is free pretty powerful).

Flash, despite what a lot of people think is fast, thousands of on screen sprites are no problem if you use Stage3D (GPU).
You could (depending on mechanics) easily port the game to android and IOS.
You could allow people to play a "demo" version online before they even have to download the full game.. which is neat.

The Flash IDE makes building ui and assets very easy.



Flash is not as quick as c++ or c#... but it isn't a million miles away.

Some useful language features are missing but it is not prohibitive.

People just don't like flash.


What kind of game are you thinking of, if you were able to share with us a brief of some kind we could probably let you know if flash is up to the task.