Hot answers tagged

24

It's not clear by your question if you really want to know techniques that allow games to save disk space even when having large amounts of heavy image/resource files (that's what is in the body of the question), or if you just wanna know if there are less disk-space hungry ways of doing animation for your buildings (that's what is implied by the title of ...


7

Here are few pointer you can use Try to make sure all your Background and non transparent images are not in PNG format Try to have all animation loop-able i.e. if animation is 1,2,3,4,5,6 try to make it like 1,2,3,4,3,2,1 where these numbers are frame number of animation, it helps a lot if many image are same and only color differs (generally UI buttons,m ...


7

I would propose that you try TexturePacker you can simply drag and drop all your images and get them packed you can apply different compression - e.g. use indexed PNGs which consume way less memory - up to 70% less compared to a standard PNG file you can create a file data files that contain the name + position of each of your buildings the free version ...


4

A lot of games don't keep their graphical assets in the .apk; they only include the "basics" like UI graphics and the game code and download the rest of the assets once the game's been installed. This is especially true for games that use different graphic resources depending on the resolution of your display to keep the .apk from having to contain both low-...


4

Normally you would load your images on-the-fly from a normal file then pass the decompressed pixels to OpenGL, but I'm also fond of embedding resources into the executable :). For an extreme example, see my PS2 game. The whole thing consists of a single 4 Megabytes executable, all assets built-in. What I did, and you can also take the same approach if you ...


4

I came to this site looking for a similar question and there are indeed a few good resources pointed both in the answers to your question and in other questions. You should probably take a look at 2D animation: Animated 3D models or sprites with animation frames? for some debate on different types of animation. It helped me optimize my game. Also, you don't ...


3

There is never one best method. Only the method which works best for you and your game. But most tile-oriented game engines I know use a 2d array of integer values for each static map layer where each entry represents the tile-type at a given tile-coordinate pair. When your tiles have more properties than can be expressed with a single ID value, this 2d ...


3

Well, either one of them can be authored with existing tools, which is always a good thing. When I was making a rhythm game, I determined that it would be easier for me to just make my own format with only what I needed and no more. I actually did my transcription with Audacity label tracks, and wrote a Lua script to convert it to a Lua table that I could ...


2

Break the grid into chunks of 2d map. If you have some bounds theb store these chunks in a higher level grid and read/write the chunks to disk as they come in and out of the active area. If you truly have an infinte area store the chunks in a hastable instead but remember to remove chunks that are out of the active area or else the hashtable will be too full....


1

I'll focus on answerable bit of the question: I can't see why an entire database system would be implemented just to read a few saved variables, but at the same time, if it's more efficient or built into the engine there's likely no reason not to use it. You are missing the point. There is no real reason to invent bicycle (own DB system) when you can ...


1

To answer your main questions: Does your A* implementation expect undirected graph? Do you have one-way mirrors? no, unless you require logic for finding not-visible-paths And about saving memory, it all depends - how spare the adjacency matrix would be? (profile!) If most nodes see almost all nodes (a forest for example), you would lose a lot memory by ...



Only top voted, non community-wiki answers of a minimum length are eligible