[Freeciv-Dev] Patch: Explosion graphics for losing unit
[Top] [All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index] [Thread Index]
Hi,
Just as a bit of eye candy, I have made a patch that adds a little
explosion animation whenever a unit dies.
The images I use are stolen from xgalaga, which is GPL, so it should
be OK. If they get actually used in FreeCiv, we should find out who
draw them to give credits. I have scaled it and reduced the pallette
to fit the default tileset.
The patch also cleans up the tile loading routine by foldin some
lines that got copied-and-pasted several times into a function.
Also, I have added a delay of 100000 µs while the hit point bar gets
decreased (there was a delay of 100 µs, I guess the author dislikes
slow animations :).
I also made the smooth unit move routine work with transparent
map. But now I have tried it on another machine and it's so slow that
I suggest we leave that out first.
I use gettimeofday() to make sure each frame takes the same time
independend of drawing speed. If anybody knows a reasonable system
without gettimeofday(), I could add a check for it.
Falk
begin 600 freeciv-explosions.patch.gz
M'XL("#;@TC8"`V9R965C:78M97AP;&]S:6]N<RYP871C:`#M6WMWVM:6_SO^
M%*=AZ,66$'HA@6URXV"[S:PTZ6K2N5FKZPX+@3"ZQ:`!3&":\-EG/_1^`+&=
MIIU;[-@^.J_]V^]]=#+T1B-1?WTW'XKZ>_%>&<U==^"M1/"[,9AX[G39N)GW
M_;$W6"B#L*<^&HWSO4?U>KU\[I-W=ZZX=AVA&T*S3@WC5&\+K=UN'TF2M'OA
MU%3[5-=.=9VG/G\NZF93MH5$/Y\_/Q*+Y?QNL!1O_;FW=,7)R=*;N+T%M19G
MN6YONIS/>C>C=3`D/V+>'_;GJ1%UF"1^?OWR7>_=RU=7;V7Q]L>+[E78N'YU
M\1W_?78D'3A2%E?O?WSUYNW+-Z_#!Z]__J&7>0BTX7JOW_STP\4K>M3[Q\O+
M=]\7//_^ZN5WW[^##N)0JR5;0H*?ADHL>B+HHUEJ0Z]_:.BRL%19+&2$/G&G
MM<7Q,4S]!+.EQLGC?8ZDN;N\FT_%U/TPV8C^9#(;])?N4#!CQ6`^\WUHCN:S
M6[&8W<T'[I'TB/LWCJ2,;'''0*RU3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