diff --git a/polymer/eduke32/build/include/build.h b/polymer/eduke32/build/include/build.h index 4d7efa7b6..bbca2407d 100644 --- a/polymer/eduke32/build/include/build.h +++ b/polymer/eduke32/build/include/build.h @@ -731,8 +731,6 @@ void setrollangle(int32_t rolla); // clamping is for sprites, repeating is for walls void invalidatetile(int16_t tilenume, int32_t pal, int32_t how); -int32_t animateoffs(int16_t tilenum, int16_t fakevar); - void setpolymost2dview(void); // sets up GL for 2D drawing int32_t polymost_drawtilescreen(int32_t tilex, int32_t tiley, int32_t wallnum, int32_t dimen, int32_t tilezoom, diff --git a/polymer/eduke32/build/src/engine.c b/polymer/eduke32/build/src/engine.c index a4aa18f23..40488d6aa 100644 --- a/polymer/eduke32/build/src/engine.c +++ b/polymer/eduke32/build/src/engine.c @@ -3037,7 +3037,7 @@ static void prepwall(int32_t z, walltype *wal) // // animateoffs (internal) // -inline int32_t animateoffs(int16_t tilenum, int16_t fakevar) +int32_t animateoffs(int16_t tilenum, int16_t fakevar) { int32_t i, k, offs; @@ -6859,8 +6859,6 @@ static void dorotatesprite(int32_t sx, int32_t sy, int32_t z, int16_t a, int16_t if ((dastat&1) == 0) #endif { - char bad; - int32_t xx, xend; int32_t y1ve[4], y2ve[4], u4, d4; if (((a&1023) == 0) && (ysiz <= 256)) //vlineasm4 has 256 high limit! @@ -6873,6 +6871,9 @@ static void dorotatesprite(int32_t sx, int32_t sy, int32_t z, int16_t a, int16_t for (x=x1; xz < daz2) && (daz2 < *florz #ifdef YAX_ENABLE - // can have a floor-sprite laying directly on the floor! + // can have a floor-sprite lying directly on the floor! || (daz2 == *florz && yax_getbunch(clipsectorlist[i], YAX_FLOOR)>=0) #endif )) @@ -13539,7 +13540,7 @@ void setbrightness(char dabrightness, uint8_t dapalid, uint8_t flags) if (!(flags&4)) { - curbrightness = min(max((int32_t)dabrightness,0),15); + curbrightness = clamp(dabrightness, 0, 15); // if (lastbright != (unsigned)curbrightness) // vid_gamma = 1.0 + ((float)curbrightness / 10.0); } diff --git a/polymer/eduke32/build/src/mdsprite.c b/polymer/eduke32/build/src/mdsprite.c index 25bb41bfc..7cd877e76 100644 --- a/polymer/eduke32/build/src/mdsprite.c +++ b/polymer/eduke32/build/src/mdsprite.c @@ -480,9 +480,8 @@ int32_t md_defineskin(int32_t modelid, const char *skinfn, int32_t palnum, int32 sk->param = param; sk->specpower = specpower; sk->specfactor = specfactor; - sk->fn = (char *)Bmalloc(strlen(skinfn)+1); + sk->fn = Bstrdup(skinfn); if (!sk->fn) return(-4); - strcpy(sk->fn, skinfn); return 0; } diff --git a/polymer/eduke32/source/demo.c b/polymer/eduke32/source/demo.c index 2a60a8adb..00c06c523 100644 --- a/polymer/eduke32/source/demo.c +++ b/polymer/eduke32/source/demo.c @@ -550,7 +550,9 @@ nextdemo: } if (foundemo == 0) // XXX: not better "demo is playing"? + { G_DrawBackground(); + } else { static uint32_t nextrender = 0, framewaiting = 0;