From ec218f423abf60b6e776d7a5a9ebee408de45a60 Mon Sep 17 00:00:00 2001 From: oroborus Date: Sat, 9 Feb 2008 20:49:15 +0000 Subject: - oprava chyby, pri zmeneni zbrane zo samopala, alebo lassera ( informoval xHire ) - prepis sietoveho protokolu, teraz je bezpecnejsi git-svn-id: http://opensvn.csie.org/tuxanci_ng@3 0ee4d065-81f0-4d1e-b06c-ff20ad07cc3e --- src/gun.c | 8 ++++++++ 1 file changed, 8 insertions(+) (limited to 'src/gun.c') diff --git a/src/gun.c b/src/gun.c index 199324f..f7fdc67 100644 --- a/src/gun.c +++ b/src/gun.c @@ -134,6 +134,7 @@ static void timer_addShotTimer(void *p) { tux_t *tux; int id; + int gun; id = * ((int *)p); free(p); @@ -142,7 +143,10 @@ static void timer_addShotTimer(void *p) if( tux == NULL )return; + gun = tux->gun; + tux->gun = GUN_SIMPLE; addShot(tux, 0, 0, +15, 0); + tux->gun = gun; } static void shotInGunTommy(tux_t *tux) @@ -159,6 +163,7 @@ static void timer_addLaserTimer(void *p) { tux_t *tux; int id; + int gun; id = * ((int *)p); free(p); @@ -167,7 +172,10 @@ static void timer_addLaserTimer(void *p) if( tux == NULL )return; + gun = tux->gun; + tux->gun = GUN_LASSER; addShot(tux, 0, 0, +20, 0); + tux->gun = gun; } static void shotInGunLasser(tux_t *tux) -- cgit v1.2.3