From a4d3da615924d87a3feb4c4ab7725179fea0f030 Mon Sep 17 00:00:00 2001
From: DarkGod <darkgod@net-core.org>
Date: Sat, 26 Apr 2014 23:39:28 +0200
Subject: [PATCH] fix some warnings

---
 game/engines/default/modules/boot/dialogs/Credits.lua | 2 +-
 game/modules/tome/data/talents/celestial/glyphs.lua   | 2 +-
 src/fov.c                                             | 4 ++--
 src/fov/fov.c                                         | 4 ++--
 src/main.c                                            | 6 +++---
 5 files changed, 9 insertions(+), 9 deletions(-)

diff --git a/game/engines/default/modules/boot/dialogs/Credits.lua b/game/engines/default/modules/boot/dialogs/Credits.lua
index 580f333995..a9f0d0b96d 100644
--- a/game/engines/default/modules/boot/dialogs/Credits.lua
+++ b/game/engines/default/modules/boot/dialogs/Credits.lua
@@ -122,7 +122,7 @@ local credits = {
 	{"Community Managers", title=2},
 	{"Bradley 'AuraOfTheDawn' Kersey"},
 	{"Faeryan"},
-	{"Lord Xandor"},
+	{"Erik 'Lord Xandor' Tillford"},
 	{"Michael 'Dekar' Olscher"},
 	{"Reenen 'Canderel' Laurie"},
 	{"The Revanchist"},
diff --git a/game/modules/tome/data/talents/celestial/glyphs.lua b/game/modules/tome/data/talents/celestial/glyphs.lua
index 06d1748b3c..472fc32972 100644
--- a/game/modules/tome/data/talents/celestial/glyphs.lua
+++ b/game/modules/tome/data/talents/celestial/glyphs.lua
@@ -196,7 +196,7 @@ newTalent{
 		local trap = Trap.new{
 			name = "glyph of explosion",
 			type = "elemental", id_by_type=true, unided_name = "trap",
-			display = '^', color=colors.GOLD, image = "trap/trap_glyph_explosion_01_64.png",
+			display = '^', color=colors.GOLD, image = "trap/trap_glyph_explosion_02_64.png",
 			dam = dam,
 			canTrigger = function(self, x, y, who)
 				if who:reactionToward(self.summoner) < 0 then return mod.class.Trap.canTrigger(self, x, y, who) end
diff --git a/src/fov.c b/src/fov.c
index 46831132f2..188a6344df 100644
--- a/src/fov.c
+++ b/src/fov.c
@@ -648,7 +648,7 @@ static int lua_fov_line_step(lua_State *L)
 
 	fov_line_data *line = &(lua_line->line);
 	bool dont_stop_at_end = lua_toboolean(L, 2);
-	if (!dont_stop_at_end && line->dest_t == line->t || line->dest_t == 0) return 0;
+	if ((!dont_stop_at_end && line->dest_t == line->t) || line->dest_t == 0) return 0;
 
 	bool is_corner_blocked = false;
 	float fx, fy, x0, y0, fx2, fy2, dx, dy;
@@ -1194,7 +1194,7 @@ static int lua_hex_fov_line_step(lua_State *L)
 
 	hex_fov_line_data *line = &(lua_line->line);
 	bool dont_stop_at_end = lua_toboolean(L, 2);
-	if (!dont_stop_at_end && line->dest_t == line->t || line->dest_t == 0) return 0;
+	if ((!dont_stop_at_end && line->dest_t == line->t) || line->dest_t == 0) return 0;
 
 	line->t += 1;
 	float fx = INV_SQRT_3_2 * (line->source_x + (float)line->t * line->step_x + line->eps_x);
diff --git a/src/fov/fov.c b/src/fov/fov.c
index 840a690d91..4c7b3d92d0 100644
--- a/src/fov/fov.c
+++ b/src/fov/fov.c
@@ -2687,7 +2687,7 @@ void fov_create_los_line(fov_settings_type *settings, void *map, void *source, f
                 }
 
                 /* being "pinched" isn't blocked, because one can still look diagonally */
-                if (mb0 && b1 || b0 && mb1 ||
+                if ((mb0 && b1) || (b0 && mb1) ||
                         gabs * (lower_slope - upper_slope) > GRID_EPSILON ||
                         gy*((float)(sy - ty) + (float)(tx - sx)*lower_slope - gy*0.5f) > -GRID_EPSILON ||
                         gy*((float)(sy - ty) + (float)(tx - sx)*upper_slope + gy*0.5f) <  GRID_EPSILON)
@@ -2808,7 +2808,7 @@ void fov_create_los_line(fov_settings_type *settings, void *map, void *source, f
                 }
 
                 /* being "pinched" isn't blocked, because one can still look diagonally */
-                if (mb0 && b1 || b0 && mb1 ||
+                if ((mb0 && b1) || (b0 && mb1) ||
                         gabs * (lower_slope - upper_slope) > GRID_EPSILON ||
                         gx*((float)(sx - tx) + (float)(ty - sy)*lower_slope - gx*0.5f) > -GRID_EPSILON ||
                         gx*((float)(sx - tx) + (float)(ty - sy)*upper_slope + gx*0.5f) <  GRID_EPSILON)
diff --git a/src/main.c b/src/main.c
index d8d4b81c67..558d1579c9 100644
--- a/src/main.c
+++ b/src/main.c
@@ -350,13 +350,13 @@ void on_event(SDL_Event *event)
 				else if (wc < 0x800)
 				{
 					buf[0] = (0xC0 | wc>>6);
-					buf[1] = (0x80 | wc & 0x3F);
+					buf[1] = (0x80 | (wc & 0x3F));
 				}
 				else
 				{
 					buf[0] = (0xE0 | wc>>12);
-					buf[1] = (0x80 | wc>>6 & 0x3F);
-					buf[2] = (0x80 | wc & 0x3F);
+					buf[1] = (0x80 | (wc>>6 & 0x3F));
+					buf[2] = (0x80 | (wc & 0x3F));
 				}
 
 				lua_pushstring(L, buf);
-- 
GitLab