Sorry your browser is not supported!

You are using an outdated browser that does not support modern web technologies, in order to use this site please update to a new browser.

Browsers supported include Chrome, FireFox, Safari, Opera, Internet Explorer 10+ or Microsoft Edge.

AppGameKit Classic Chat / The Do's and Dont's of making a program for ipod

Author
Message
3d point in space
15
Years of Service
User Offline
Joined: 30th Jun 2009
Location: Idaho
Posted: 18th Jan 2012 13:51 Edited at: 18th Jan 2012 16:53
I have learnt a lot about xcode ios programming and programming to small devices.

1.Use Text instead of making a picture of text.
2. Don’t load too many sprites it will crash the ipod and your game wont work.
This includes loading big pictures and laying them out side by side. Have smaller pictures.
Try only having 1 to 3 backgrounds for every thing. Chose a background you like and use it multiple times.
You will see an increase in game speed with less pictures then more pictures.

3.I have not seen that much problems with sounds but I think if you load big songs in your app it will perform worse or even crash.
4.I think it will be a while before they get 3d because of these things that I FOUND that crashed my app or made it perform badly.

How to fix

Get ride of any sprites that use text. And use the regular text command, or use a sprite text sheet.
Get rid of large sprites. Helps performance a lot.
Try and use sprites that you will clone. If you don’t use the sprite a lot in your game delete it and try using colored ascii code for the same sprite.
Don’t have a lot of spinning objects that are big sprites in nature. Try and use just one sprite to accomplish the same thing.

These are only tips if you have a large game and load tones of graphics.

Go through yourself at a wall.
bjadams
AGK Backer
16
Years of Service
User Offline
Joined: 29th Mar 2008
Location:
Posted: 18th Jan 2012 16:38
Can you explain point 4 better, as it does not click to me
3d point in space
15
Years of Service
User Offline
Joined: 30th Jun 2009
Location: Idaho
Posted: 18th Jan 2012 16:52
well they will have 3d but it, but with its current builds even loading a lot of big graphic files will slow down a small device like an ipod or iphone.
So I think the 3d will be simple shapes like boxes, and spheres if they go 3d. Or 3d image is very small.

Go through yourself at a wall.
3d point in space
15
Years of Service
User Offline
Joined: 30th Jun 2009
Location: Idaho
Posted: 18th Jan 2012 17:19 Edited at: 18th Jan 2012 17:21
i have fixed my game by changing some of the sprites to 1 frame, and getting ride of all the big sprite files. This actually worked and it looks like the same game it just doesn't have sprites that look like there rotating in 3d, and the end of the game is different.

Go through yourself at a wall.
baxslash
Valued Member
Bronze Codemaster
17
Years of Service
User Offline
Joined: 26th Dec 2006
Location: Duffield
Posted: 18th Jan 2012 22:19
Well AppGameKit doesn't have 3D yet but I have played COD on the iPhone and there was more than a few boxes.

My own iOS game uses a lot of large textures (512x512) for background sprites and I haven't personally noticed it running slowly at all but it is a fairly new device...

It would be nice to get more people's experiences because I haven't had any problems with large sprites or 3D games on my own device.

bjadams
AGK Backer
16
Years of Service
User Offline
Joined: 29th Mar 2008
Location:
Posted: 19th Jan 2012 08:19
I am testing my games on iphone 3gs. this is the lowest denominator device i set in my mind.

my projects run at 60fps, but you have to take care of not overloading big sprites if you want to make your game run on as many devices as possible.

problem is ipod has only 256mb of ram. i hope that the 5th gen ipod will have some decent ram
Digital Awakening
AGK Developer
22
Years of Service
User Offline
Joined: 27th Aug 2002
Location: Sweden
Posted: 19th Jan 2012 09:53
Just saying things doesn't work well on iPod, iPhone or iOS without specifying exactly what hardware you are using. And you also have to define what a large image actually is, people have different ideas especially when talking different platforms. Of course a little handheld device won't be able to do the same thing as a full size PC. But on a small screen you don't need the same kind of detail, and people also do not expect the same graphical quality. And you also need to consider storage space as well as download time.

3d point in space
15
Years of Service
User Offline
Joined: 30th Jun 2009
Location: Idaho
Posted: 19th Jan 2012 18:15
I just read on the forms that it looks like people plan on making a game with multiple pictures that are big and, laying them out like a level. Making a map editor like I did for my game I think was a smart idea. I have about a 100 50 by 50 small sprites that I use to display what the user sees over and over in different patterns to show rooms and maps of levels. I also have about only 4 backgrounds that I use consistantly. I left some sprite that have text on them that where smaller in size about 44 small pictures.
20 different monsters, most of them are 50 by 50 and some have moving parts so thats 5 or so extra sprites. about 40 different weapon pictures. 1 picture of the player.

This is what I removed from my game 4 extra backgrounds used text instead. Change 10 sprites to 1 frame. Removed big sprites at end of each level that told the user they have passed the current level that is about 12 big sprites. 8 big sprites of the player rotating in 3d they where big image files. I only have one picture that is used in equiping a player, and it only has 1 frame.
removing by big sprites got my app up and running.

I finally submitted my app but, next time I make an app I will not make any pictures of text.

Go through yourself at a wall.
xCept
21
Years of Service
User Offline
Joined: 15th Dec 2002
Location:
Posted: 20th Jan 2012 00:58
It is important to include two sets of images for iOS apps, retina and non-retina (then program accordingly so the lower res devices don't load in the larger graphics). Using gigantic background images can certainly eat up a lot of memory (use the Allocations/Performance tools in xCode to monitor this). I don't notice too many problems with many sprites, particles etc. on the screen even on an iPod 3, solid 59-60 FPS.
Digital Awakening
AGK Developer
22
Years of Service
User Offline
Joined: 27th Aug 2002
Location: Sweden
Posted: 20th Jan 2012 10:16
Lots of sprites should not be a problem but having large image files eats up graphical memory if they are all loaded at the same time. Also, drawing lots of images on screen at once is not a good idea. It is recommended that you use tiled images or atlas images as they render faster than separate images.

Also using lots of single 50x50 images is a bad idea. Each one will take up 64x64 in memory. Say you have 100 single images each 50x50, they will take up 640x640 in memory. If you instead made a single 500x500 tiled image it would only take up 512x512 in memory. Each side a multiple of 2. 1 image also renders faster than 100 images.

And yeah, it is a good idea to consider not using too many large images. But have you tried not loading all your images before the game starts? If you only load images when you need them, and then delete them when you are not using them any more, you save a lot of memory.

Login to post a reply

Server time is: 2024-11-22 23:59:40
Your offset time is: 2024-11-22 23:59:40