summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rwxr-xr-xconfigure13
-rw-r--r--configure.in11
-rw-r--r--src/char/int_storage.c2
-rw-r--r--src/map/battle.c4
4 files changed, 17 insertions, 13 deletions
diff --git a/configure b/configure
index 03f0dca11..71ca5bcfb 100755
--- a/configure
+++ b/configure
@@ -1,5 +1,5 @@
#! /bin/sh
-# From configure.in fd7cd2c.
+# From configure.in 98f4fcb.
# Guess values for system-dependent variables and create Makefiles.
# Generated by GNU Autoconf 2.69.
#
@@ -4570,17 +4570,22 @@ ac_compiler_gnu=$ac_cv_c_compiler_gnu
# -Wcast-qual use for check wrong casts. It cant be added by default, because some casts must be wrong.
# -Wconversion warning: conversion to 'long unsigned int' from 'int' may change the sign of the result
# -Wfloat-equal comparing floating point with == or != is unsafe
+# -Wunsuffixed-float-constants float issues
# -Wpedantic different pedantic checks. Not all can be fixed in nice way.
+# -Wtraditional-conversion some conversion issues
+# -Wunsafe-loop-optimizations possible optimisation issues
+# -Wunused-parameter -Wunused-but-set-parameter unused parameters
+# -Wunused-macros unused macro warnings, but it also enable unused parameters
# attributes suggestion
# -Wsuggest-attribute=const -Wsuggest-attribute=format -Wsuggest-attribute=pure
# flags what can be used but now return no warnings: -Warray-bounds -Wbool-compare -Wcast-align
# -Wchar-subscripts -Wchkp -Wclobbered -Wcomment -Wdisabled-optimization -Wempty-body
-# -Werror-implicit-function-declaration -Wignored-qualifiers
+# -Werror-implicit-function-declaration -Wignored-qualifiers -Wtrampolines -Wtype-limits
# -Wjump-misses-init -Wlogical-op -Wmissing-field-initializers -Wmissing-parameter-type
# -Wnested-externs -Wold-style-declaration -Wold-style-definition -Woverlength-strings -Woverride-init
-# -Wredundant-decls -Wstack-protector -Wstrict-prototypes
-# -Winit-self -Wpointer-arith
+# -Wredundant-decls -Wstack-protector -Wstrict-prototypes -Wundef
+# -Winit-self -Wpointer-arith -Wswitch-bool
CFLAGS="$CFLAGS -pipe -ffast-math -Wall -Wextra -Wno-sign-compare"
CPPFLAGS="$CPPFLAGS -I../common"
diff --git a/configure.in b/configure.in
index e23b6c44b..da52bc286 100644
--- a/configure.in
+++ b/configure.in
@@ -459,17 +459,22 @@ AC_LANG([C])
# -Wcast-qual use for check wrong casts. It cant be added by default, because some casts must be wrong.
# -Wconversion warning: conversion to 'long unsigned int' from 'int' may change the sign of the result
# -Wfloat-equal comparing floating point with == or != is unsafe
+# -Wunsuffixed-float-constants float issues
# -Wpedantic different pedantic checks. Not all can be fixed in nice way.
+# -Wtraditional-conversion some conversion issues
+# -Wunsafe-loop-optimizations possible optimisation issues
+# -Wunused-parameter -Wunused-but-set-parameter unused parameters
+# -Wunused-macros unused macro warnings, but it also enable unused parameters
# attributes suggestion
# -Wsuggest-attribute=const -Wsuggest-attribute=format -Wsuggest-attribute=pure
# flags what can be used but now return no warnings: -Warray-bounds -Wbool-compare -Wcast-align
# -Wchar-subscripts -Wchkp -Wclobbered -Wcomment -Wdisabled-optimization -Wempty-body
-# -Werror-implicit-function-declaration -Wignored-qualifiers
+# -Werror-implicit-function-declaration -Wignored-qualifiers -Wtrampolines -Wtype-limits
# -Wjump-misses-init -Wlogical-op -Wmissing-field-initializers -Wmissing-parameter-type
# -Wnested-externs -Wold-style-declaration -Wold-style-definition -Woverlength-strings -Woverride-init
-# -Wredundant-decls -Wstack-protector -Wstrict-prototypes
-# -Winit-self -Wpointer-arith
+# -Wredundant-decls -Wstack-protector -Wstrict-prototypes -Wundef
+# -Winit-self -Wpointer-arith -Wswitch-bool
CFLAGS="$CFLAGS -pipe -ffast-math -Wall -Wextra -Wno-sign-compare"
CPPFLAGS="$CPPFLAGS -I../common"
diff --git a/src/char/int_storage.c b/src/char/int_storage.c
index 9884cc6d1..30647233b 100644
--- a/src/char/int_storage.c
+++ b/src/char/int_storage.c
@@ -37,8 +37,6 @@
#include <stdio.h>
#include <stdlib.h>
-#define STORAGE_MEMINC 16
-
struct inter_storage_interface inter_storage_s;
struct inter_storage_interface *inter_storage;
diff --git a/src/map/battle.c b/src/map/battle.c
index 44adef051..4cf9a5b54 100644
--- a/src/map/battle.c
+++ b/src/map/battle.c
@@ -4783,12 +4783,10 @@ struct Damage battle_calc_weapon_attack(struct block_list *src,struct block_list
//Assuming that 99% of the cases we will not need to check for the flag.rh... we don't.
//ATK_RATE scales the damage. 100 = no change. 50 is halved, 200 is doubled, etc
#define ATK_RATE( a ) do { int64 temp__ = (a); wd.damage= wd.damage*temp__/100 ; if(flag.lh) wd.damage2= wd.damage2*temp__/100; } while(0)
-#define ATK_RATE2( a , b ) do { wd.damage= wd.damage*(a)/100 ; if(flag.lh) wd.damage2= wd.damage2*(b)/100; } while(0)
#define ATK_RATER(a) ( wd.damage = wd.damage*(a)/100 )
#define ATK_RATEL(a) ( wd.damage2 = wd.damage2*(a)/100 )
//Adds dmg%. 100 = +100% (double) damage. 10 = +10% damage
#define ATK_ADDRATE( a ) do { int64 temp__ = (a); wd.damage+= wd.damage*temp__/100; if(flag.lh) wd.damage2+= wd.damage2*temp__/100; } while(0)
-#define ATK_ADDRATE2( a , b ) do { wd.damage+= wd.damage*(a)/100 ; if(flag.lh) wd.damage2+= wd.damage2*(b)/100; } while(0)
//Adds an absolute value to damage. 100 = +100 damage
#define ATK_ADD( a ) do { int64 temp__ = (a); wd.damage += temp__; if (flag.lh) wd.damage2 += temp__; } while(0)
#define ATK_ADD2( a , b ) do { wd.damage += (a); if (flag.lh) wd.damage2 += (b); } while(0)
@@ -6373,11 +6371,9 @@ enum damage_lv battle_weapon_attack(struct block_list* src, struct block_list* t
return wd.dmg_lv;
}
#undef ATK_RATE
-#undef ATK_RATE2
#undef ATK_RATER
#undef ATK_RATEL
#undef ATK_ADDRATE
-#undef ATK_ADDRATE2
#undef ATK_ADD
#undef ATK_ADD2
#undef GET_NORMAL_ATTACK