clintbellanger/flare-game — pull request #353 by stefanbeller (2013-10-02 09:07:24+00:00)
Title: Reduce image sizes to reduce RAM usage while playing.

The new version of
https://github.com/stefanbeller/RectangleBinPack
uses all heuristics for the MaxRectsBinPack and can find new packing
possibilities, which are even a little smaller than before.

The ember and shield powers were not packed before, hence they have a
larger improvement.

Here is a list of the packed sprites, they reduce area by about half a percent, so not very much.
I do not know whether this patch is worth it though, it certainly improves the game itself, but only to a small extent, while blowing up the version history by a few megabytes.

enemies: area change (w * h) (old_w * old_h)
scathelocke: 0.9968 3014x217 3382x194
antlion_small: 0.9904 2772x63 4198x42
minotaur: 0.9977 7161x311 14308x156
stealth: 0.9935 1638x138 2473x92

female hero assets:
chain_coif: 0.9982 42x3956 42x3963
chain_cuirass: 0.9841 97x2083 128x1604
head_long: 0.9993 63x2619 42x3931
leather_hood: 0.9961 1065x170 2634x69
leather_pants: 0.9944 1217x101 1648x75
mage_hood: 0.9975 113x1657 45x4171
mage_skirt: 0.9910 72x2519 127x1441
mage_vest: 0.9843 95x2166 127x1646
plate_cuirass: 0.9768 97x2198 53x4118
plate_greaves: 0.9890 998x128 1017x127
plate_helm: 0.9967 1713x102 2578x68

male assets:
cloth_pants: 0.9976 1043x126 2583x51
cloth_shirt: 0.9984 1669x135 3368x67
head_bald: 0.9975 1168x127 1533x97
leather_chest: 0.9806 110x2173 107x2278
leather_pants: 0.9985 1316x102 1331x101
mage_boots: 0.9997 125x1368 58x2949
plate_boots: 0.9978 120x1439 59x2933
plate_cuirass: 0.9999 1358x176 3464x69
plate_helm: 0.9967 1092x168 1787x103
steel_armor: 0.9987 156x3174 80x6197

loot:
boots: 0.9537 56x103 56x108
dagger: 0.9669 53x117 53x121
greatbow: 0.9502 95x157 144x109
mp_potion: 0.9913 50x114 50x115
scroll: 0.9032 43x28 43x31
steel_armor: 0.9580 108x120 167x81

powers:
ember: 0.2734 10x14 8x64
quake: 0.9934 594x288 820x210
shield: 0.5260 175x197 512x128

Signed-off-by: Stefan Beller