[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 483: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 483: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 483: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 483: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 483: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 483: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 483: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 483: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 483: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 483: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 483: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 483: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 483: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 483: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 483: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 483: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 483: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 483: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 483: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 483: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 483: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 483: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 483: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 483: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 483: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 483: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 112: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 112: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 112: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 112: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 112: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 112: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 112: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 112: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 112: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/functions.php on line 4752: Cannot modify header information - headers already sent by (output started at [ROOT]/includes/functions.php:3887)
[phpBB Debug] PHP Warning: in file [ROOT]/includes/functions.php on line 4754: Cannot modify header information - headers already sent by (output started at [ROOT]/includes/functions.php:3887)
[phpBB Debug] PHP Warning: in file [ROOT]/includes/functions.php on line 4755: Cannot modify header information - headers already sent by (output started at [ROOT]/includes/functions.php:3887)
[phpBB Debug] PHP Warning: in file [ROOT]/includes/functions.php on line 4756: Cannot modify header information - headers already sent by (output started at [ROOT]/includes/functions.php:3887)
Master of Magic - Implode's Multiplayer Edition • View topic - Overral game performance

Overral game performance

Place to report bugs in MoM IME and suggest ideas for enhancements (please read rules before posting)

Overral game performance

Postby hammer » Sat Jan 06, 2007 9:48 pm

hammer
 
Posts: 9
Joined: Sat Jan 06, 2007 1:46 pm

Re: Overral game performance

Postby Implode » Sun Jan 07, 2007 2:01 am

User avatar
Implode
Site Admin
 
Posts: 432
Joined: Fri Feb 24, 2006 3:35 am
Location: Newfoundland, Canada

Postby hammer » Sun Jan 07, 2007 8:13 am

hammer
 
Posts: 9
Joined: Sat Jan 06, 2007 1:46 pm

Postby Implode » Sun Jan 07, 2007 7:57 pm

User avatar
Implode
Site Admin
 
Posts: 432
Joined: Fri Feb 24, 2006 3:35 am
Location: Newfoundland, Canada

Postby hammer » Sun Jan 07, 2007 10:46 pm

hammer
 
Posts: 9
Joined: Sat Jan 06, 2007 1:46 pm

Postby Suor » Wed Apr 11, 2007 7:15 pm

Suor
 
Posts: 1
Joined: Wed Apr 11, 2007 5:21 pm
Location: Russia, Krasnoyarsk

Postby Implode » Thu Apr 12, 2007 12:31 am

User avatar
Implode
Site Admin
 
Posts: 432
Joined: Fri Feb 24, 2006 3:35 am
Location: Newfoundland, Canada

Postby momfreeek » Fri Feb 22, 2008 8:01 pm

Have you considered keeping the entire map pre-drawn in a buffer? High memory usage, but its easy to calculate exactly what the usage would be and it could cut the intensive cpu usage massively.

use one of the following methods:
- blit the visible area from the map buffer every frame before drawing creatures and effects on top.
- pre-draw everything and use a 'dirty rect' system (mark areas to be redrawn when things move) then blit the visible area.
- a combination of the above

2d games would generally use these methods to improve performance. In days when memory was expensive, big scrolling maps would be implemented by keeping the visible area in memory, shifting that image then drawing the newly visible edges (google maps is a good example of this method).

Does any of that help? I understand that you want to add features first. Make it work first, then optimise.
momfreeek
 
Posts: 5
Joined: Fri Jul 20, 2007 12:55 am

Postby Implode » Tue Feb 26, 2008 1:23 am

User avatar
Implode
Site Admin
 
Posts: 432
Joined: Fri Feb 24, 2006 3:35 am
Location: Newfoundland, Canada

Postby momfreeek » Thu Feb 28, 2008 11:43 pm

momfreeek
 
Posts: 5
Joined: Fri Jul 20, 2007 12:55 am

Re: Overral game performance

Postby klausbreuer » Mon Oct 20, 2008 2:53 pm

A performance problem I find myself with is the animation speed (latest version, of course):

* Please add an option to simply snap units to the next tile instead of sloooowly moving them there.
* Dito for the map scrolling - it can take quite a while to scroll to the next unit on the map.

Together, these two animation delays, while not seeming to require more CPU power, slow down the game a *lot*.

And while we're at it - the creatures are shown including their ground square. This does not make them look particularly good, especially when moving them... any chance of changing that as well, merely showing the creature itself?

As to map creation speed: personally, I create a basic map in RAM, then create a copy. On that copy I place everything mobile and blit it into the screen. This makes things nice and fast. If something changes permanently (for example, a road is built), the basic background map is modified.

(Yes, I write stuff in Delphi 7 - been using Delphi/Turbo Pascal since '86 ;)

Looking at your FAQ under 'Performance':

* Yes, you do draw more graphics, but why use an API? Create an array, draw pixels into there, and then blit the whole thing on screen. Or (better yet, IMNSHO) use http://grhttp://graphics32.org/wiki/ - it's for Windozw graphics, it's for Delphi, it's free and very very fast.
* Why are you parsing the XML files more than once? Why not simply read them once at the start, parse them into global variables, and bingo?
* Yes, thread safety can slow you down quite a bit...

OTOH - seeing that you're switching to Java, does it matter anymore at all? ;)

Ciao,
Klaus
User avatar
klausbreuer
 
Posts: 19
Joined: Mon Oct 20, 2008 8:38 am


Return to Bug reports and ideas for enhancements

Who is online

Users browsing this forum: No registered users and 2 guests

cron