Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
View | Details | Raw Unified | Return to bug 66718 | Differences between
and this patch

Collapse All | Expand All

(-)src/explosion.cc (-3 / +3 lines)
Lines 159-165 Link Here
159
				}
159
				}
160
				if (distance <= (radius + TANKHEIGHT/2) && tank->l > 0) {
160
				if (distance <= (radius + TANKHEIGHT/2) && tank->l > 0) {
161
					_global->updateMenu = 1;
161
					_global->updateMenu = 1;
162
					tank->damage = (int) ((float) damage * ((float) 1 - ((fabs (distance) / (float)radius) / 2)) * player->damageMultiplier);
162
					tank->damage = (int) ((player ? (float) damage * player->damageMultiplier : (float) damage) * ((float) 1 - ((fabs (distance) / (float)radius) / 2)));
163
163
164
					tank->creditTo = player;
164
					tank->creditTo = player;
165
					tank->applyDamage ();
165
					tank->applyDamage ();
Lines 253-259 Link Here
253
		if (a > 1 && a <= EXPLODEFRAMES + 1) {
253
		if (a > 1 && a <= EXPLODEFRAMES + 1) {
254
			int startCirc = (radius / EXPLODEFRAMES) * a;
254
			int startCirc = (radius / EXPLODEFRAMES) * a;
255
			circlefill (_env->terrain, (int)x, (int)y, startCirc, PINK);
255
			circlefill (_env->terrain, (int)x, (int)y, startCirc, PINK);
256
			circle (dest, (int)x, (int)y, startCirc, player->color);
256
			circle (dest, (int)x, (int)y, startCirc, player ? player->color : WHITE);
257
			setUpdateArea ((int)x - (radius + 1), (int)y - (radius + 1), (radius + 1) * 2, (radius + 1) * 2);
257
			setUpdateArea ((int)x - (radius + 1), (int)y - (radius + 1), (radius + 1) * 2, (radius + 1) * 2);
258
		}
258
		}
259
	} else if ((type >= RIOT_CHARGE) && (type <= RIOT_BLAST)) {
259
	} else if ((type >= RIOT_CHARGE) && (type <= RIOT_BLAST)) {
Lines 261-267 Link Here
261
			double sx = x - _global->slope[angle][0] * 15;
261
			double sx = x - _global->slope[angle][0] * 15;
262
			double sy = y - _global->slope[angle][1] * 15;
262
			double sy = y - _global->slope[angle][1] * 15;
263
			int startCirc = (radius / EXPLODEFRAMES) * a;
263
			int startCirc = (radius / EXPLODEFRAMES) * a;
264
			triangle (dest, (int)sx, (int)sy, (int)(sx + _global->slope[(angle + 45) % 360][0] * startCirc), (int)(sy + _global->slope[(angle + 45) % 360][1] * startCirc),(int)(sx + _global->slope[(angle + 315) % 360][0] * startCirc),(int)(sy + _global->slope[(angle + 315) % 360][1] * startCirc), player->color);
264
			triangle (dest, (int)sx, (int)sy, (int)(sx + _global->slope[(angle + 45) % 360][0] * startCirc), (int)(sy + _global->slope[(angle + 45) % 360][1] * startCirc),(int)(sx + _global->slope[(angle + 315) % 360][0] * startCirc),(int)(sy + _global->slope[(angle + 315) % 360][1] * startCirc), player ? player->color : WHITE);
265
			setUpdateArea ((int)sx - (startCirc + 1), (int)sy - (startCirc + 1), (startCirc + 1) * 2, (startCirc + 1) * 2);
265
			setUpdateArea ((int)sx - (startCirc + 1), (int)sy - (startCirc + 1), (startCirc + 1) * 2, (startCirc + 1) * 2);
266
		}
266
		}
267
	} else {
267
	} else {
(-)src/beam.cc (-1 / +1 lines)
Lines 167-173 Link Here
167
		if (targetX > ltank->x - TANKWIDTH - radius && targetX < ltank->x + TANKWIDTH + radius && targetY > ltank->y - radius && targetY < ltank->y + TANKHEIGHT + radius && ltank->l > 0) {
167
		if (targetX > ltank->x - TANKWIDTH - radius && targetX < ltank->x + TANKWIDTH + radius && targetY > ltank->y - radius && targetY < ltank->y + TANKHEIGHT + radius && ltank->l > 0) {
168
			//hitSomething = 1;
168
			//hitSomething = 1;
169
			ltank->requireUpdate ();
169
			ltank->requireUpdate ();
170
			ltank->damage += damage * player->damageMultiplier;
170
			ltank->damage += player ? damage * player->damageMultiplier : damage;
171
			ltank->creditTo = player;
171
			ltank->creditTo = player;
172
			if (destroy)
172
			if (destroy)
173
				ltank->applyDamage ();
173
				ltank->applyDamage ();

Return to bug 66718