summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
Diffstat (limited to 'src')
-rw-r--r--src/char/char.c1
-rw-r--r--src/map/battle.c2
-rw-r--r--src/map/clif.c12
-rw-r--r--src/map/clif.h1
-rw-r--r--src/map/map.c2
-rw-r--r--src/map/map.h4
-rw-r--r--src/map/pc.c9
-rw-r--r--src/map/script.c6
-rw-r--r--src/map/skill.c19
-rw-r--r--src/map/skill.h2
10 files changed, 9 insertions, 49 deletions
diff --git a/src/char/char.c b/src/char/char.c
index 28ae5dea1..16f4135af 100644
--- a/src/char/char.c
+++ b/src/char/char.c
@@ -3068,7 +3068,6 @@ int lan_subnetcheck(long *p) {
}
int parse_char(int fd) {
-
int i, ch;
unsigned short cmd;
char email[40];
diff --git a/src/map/battle.c b/src/map/battle.c
index 72283688f..d33f31a2b 100644
--- a/src/map/battle.c
+++ b/src/map/battle.c
@@ -1565,8 +1565,6 @@ static struct Damage battle_calc_weapon_attack(
else if (!sd)
skillratio += 150; //Max damage for non players.
break;
- case NPC_COMBOATTACK:
- break;
case NPC_RANDOMATTACK:
skillratio += rand()%150-50;
break;
diff --git a/src/map/clif.c b/src/map/clif.c
index 8429b3d23..e83fc9ba9 100644
--- a/src/map/clif.c
+++ b/src/map/clif.c
@@ -3857,7 +3857,7 @@ void clif_getareachar_item(struct map_session_data* sd,struct flooritem_data* fi
*/
int clif_getareachar_skillunit(struct map_session_data *sd,struct skill_unit *unit)
{
- int fd/*, unit_id*/; // Unused? [Lance]
+ int fd;
struct block_list *bl;
fd=sd->fd;
@@ -3904,7 +3904,7 @@ int clif_getareachar_skillunit(struct map_session_data *sd,struct skill_unit *un
WFIFOL(fd, 2)=unit->bl.id;
WFIFOL(fd, 6)=unit->group->src_id;
WFIFOW(fd,10)=unit->bl.x;
- WFIFOW(fd,12)=unit_id;
+ WFIFOW(fd,12)=unit->bl.y;
WFIFOB(fd,14)=unit->group->unit_id;
WFIFOB(fd,15)=1;
if(unit->group->unit_id==UNT_GRAFFITI) { // Graffiti [Valaris]
@@ -8094,14 +8094,6 @@ void clif_parse_LoadEndAck(int fd,struct map_session_data *sd)
//[LuzZza]
clif_guild_send_onlineinfo(sd);
-/* Unneccesary due to mapflag "nosave" [Skotlex]
-// Stop players from spawning inside castles [Valaris]
- {
- struct guild_castle *gc=guild_mapname2gc(map[sd->bl.m].name);
- if (gc)
- pc_setpos(sd,sd->status.save_point.map,sd->status.save_point.x,sd->status.save_point.y,2);
- }
-*/
} else
//New 'night' effect by dynamix [Skotlex]
if (night_flag && map[sd->bl.m].flag.nightenabled)
diff --git a/src/map/clif.h b/src/map/clif.h
index 386703910..f7a78dbce 100644
--- a/src/map/clif.h
+++ b/src/map/clif.h
@@ -325,7 +325,6 @@ int do_init_clif(void);
void clif_get_weapon_view(TBL_PC* sd, short *rhand, short *lhand);
-
int clif_party_xy_remove(struct map_session_data *sd); //Fix for minimap [Kevin]
void clif_parse_ReqFeel(int fd, struct map_session_data *sd, int skilllv);
void clif_feel_info(struct map_session_data *sd, int feel_level);
diff --git a/src/map/map.c b/src/map/map.c
index 507c36b1c..9a97d7446 100644
--- a/src/map/map.c
+++ b/src/map/map.c
@@ -2737,7 +2737,7 @@ static int map_loadafm (struct map_data *m, char *fn)
xs = m->xs = afm_size[0];
ys = m->ys = afm_size[1];
m->water_height = map_waterheight(m->name);
-
+ // check this, unsigned where it might not need to be
m->gat = (unsigned char*)aCallocA(xs * ys, 1);
for (y = 0; y < ys; y++) {
diff --git a/src/map/map.h b/src/map/map.h
index 3f0871c8e..38e4d02a4 100644
--- a/src/map/map.h
+++ b/src/map/map.h
@@ -1376,10 +1376,6 @@ extern MYSQL mmysql_handle;
extern MYSQL_RES* sql_res ;
extern MYSQL_ROW sql_row ;
-extern MYSQL lmysql_handle;
-extern MYSQL_RES* lsql_res ;
-extern MYSQL_ROW lsql_row ;
-
extern MYSQL charsql_handle;
extern MYSQL_RES* charsql_res;
extern MYSQL_ROW charsql_row;
diff --git a/src/map/pc.c b/src/map/pc.c
index fc0dc4ae6..b39bd4a73 100644
--- a/src/map/pc.c
+++ b/src/map/pc.c
@@ -452,9 +452,9 @@ int pc_calcweapontype(struct map_session_data *sd)
{
nullpo_retr(0, sd);
- if(sd->weapontype1 != W_FIST && sd->weapontype2 == W_FIST)
+ if(sd->weapontype1 != W_FIST && sd->weapontype2 == W_FIST)
sd->status.weapon = sd->weapontype1;
- else if(sd->weapontype1 == W_FIST && sd->weapontype2 != W_FIST)// 左手武器 Only
+ else if(sd->weapontype1 == W_FIST && sd->weapontype2 != W_FIST)// 左手武器 Only
sd->status.weapon = sd->weapontype2;
else if(sd->weapontype1 == W_DAGGER && sd->weapontype2 == W_DAGGER)// ?短?
sd->status.weapon = MAX_WEAPON_TYPE+1;
@@ -1269,7 +1269,6 @@ int pc_bonus(struct map_session_data *sd,int type,int val)
else if(sd->state.lr_flag == 1)
sd->left_weapon.atk_ele=val;
else if(sd->state.lr_flag == 2)
-
sd->arrow_ele=val;
break;
case SP_DEFELE:
@@ -3820,7 +3819,6 @@ int pc_checkjoblevelup(struct map_session_data *sd)
if(!battle_config.multi_level_up && sd->status.job_exp > next-1)
sd->status.job_exp = next-1;
-
sd->status.job_level ++;
clif_updatestatus(sd,SP_JOBLEVEL);
@@ -4427,7 +4425,6 @@ int pc_resetfeel(struct map_session_data* sd)
{
int i;
char feel_var[3][NAME_LENGTH] = {"PC_FEEL_SUN","PC_FEEL_MOON","PC_FEEL_STAR"};
-
nullpo_retr(0, sd);
for (i=0; i<3; i++)
@@ -6041,7 +6038,6 @@ int pc_cleareventtimer(struct map_session_data *sd)
if (p) aFree(p);
}
-
return 0;
}
@@ -7389,7 +7385,6 @@ int pc_readdb(void)
skill_tree[atoi(split[0])][j].need[k].id=atoi(split[k*2+m]);
skill_tree[atoi(split[0])][j].need[k].lv=atoi(split[k*2+m+1]);
}
-
}
fclose(fp);
ShowStatus("Done reading '"CL_WHITE"%s"CL_RESET"'.\n","skill_tree.txt");
diff --git a/src/map/script.c b/src/map/script.c
index 08cd19569..81b98fa55 100644
--- a/src/map/script.c
+++ b/src/map/script.c
@@ -23,6 +23,7 @@
#include "../common/lock.h"
#include "../common/nullpo.h"
#include "../common/showmsg.h"
+#include "../common/strlib.h"
#include "map.h"
#include "clif.h"
@@ -45,11 +46,6 @@
#include "charcommand.h"
#include "log.h"
#include "unit.h"
-
-#if !defined(TXT_ONLY) && defined(MAPREGSQL)
-#include "strlib.h"
-#endif
-
#include "irc.h"
#define SCRIPT_BLOCK_SIZE 256
diff --git a/src/map/skill.c b/src/map/skill.c
index baeb2d571..67c55ac85 100644
--- a/src/map/skill.c
+++ b/src/map/skill.c
@@ -610,7 +610,6 @@ const struct skill_name_db skill_names[] = {
static const int dirx[8]={0,-1,-1,-1,0,1,1,1};
static const int diry[8]={1,1,0,-1,-1,-1,0,1};
-
static struct eri *skill_unit_ers = NULL; //For handling skill_unit's [Skotlex]
static struct eri *skill_timer_ers = NULL; //For handling skill_timerskills [Skotlex]
@@ -3195,17 +3194,12 @@ int skill_castend_nodamage_id (struct block_list *src, struct block_list *bl, in
return 0;
}
}
+ //These are actually ground placed.
case CR_GRANDCROSS:
case NPC_GRANDDARKNESS:
- //These are actually ground placed.
- return skill_castend_pos2(src,src->x,src->y,skillid,skilllv,tick,0);
-
//Until they're at right position - gs_ground- [Vicious]
case NJ_KAENSIN: /*火炎陣*/
case GS_DESPERADO: /*デスペラード*/
- return skill_castend_pos2(src,src->x,src->y,skillid,skilllv,tick,0);
- break;
-
case NJ_HYOUSYOURAKU:
case NJ_RAIGEKISAI:
return skill_castend_pos2(src,src->x,src->y,skillid,skilllv,tick,0);
@@ -3982,7 +3976,6 @@ int skill_castend_nodamage_id (struct block_list *src, struct block_list *bl, in
ar=skilllv/3;
skill_brandishspear_first(&tc,dir,x,y);
skill_brandishspear_dir(&tc,dir,4);
- clif_skill_nodamage(src,bl,skillid,skilllv,1);
/* 範?C */
if(skilllv == 10){
for(c=1;c<4;c++){
@@ -5901,6 +5894,7 @@ int skill_castend_pos2( struct block_list *src, int x,int y,int skillid,int skil
map_foreachinarea( status_change_timer_sub,
src->m, x-i, y-i, x+i,y+i,BL_CHAR,
src,status_get_sc(src),SC_SIGHT,tick);
+ if(battle_config.traps_setting&1)
map_foreachinarea( skill_reveal_trap,
src->m, x-i, y-i, x+i,y+i,BL_SKILL);
break;
@@ -6465,7 +6459,7 @@ struct skill_unit_group *skill_unitsetting( struct block_list *src, int skillid,
count=1; // Leave this at 1 [Valaris]
break;
case WE_CALLPARTNER:
- if (sd ) val1 = sd->status.partner_id;
+ if (sd) val1 = sd->status.partner_id;
break;
case WE_CALLPARENT:
if (sd) {
@@ -9586,13 +9580,6 @@ int skill_unit_timer_sub( struct block_list *bl, va_list ap )
group->bl_flag,bl,tick);
if (!unit->alive)
return 0;
- /*Apparently magnus shouldn't get it's cells deleted like this. [Skotlex]
- // マグヌスは発動したユニットは??怩キる
- if (group->skill_id==PR_MAGNUS && unit->val2) {
- skill_delunit(unit);
- return 0;
- }
- */
}
/* 時間?リれ?? */
if((DIFF_TICK(tick,group->tick)>=group->limit || DIFF_TICK(tick,group->tick)>=unit->limit)){
diff --git a/src/map/skill.h b/src/map/skill.h
index 5e1dbb22f..e57aba0be 100644
--- a/src/map/skill.h
+++ b/src/map/skill.h
@@ -246,7 +246,6 @@ int skill_arrow_create( struct map_session_data *sd,int nameid);
int skill_castend_nodamage_id( struct block_list *src, struct block_list *bl,int skillid,int skilllv,unsigned int tick,int flag );
int skill_castend_damage_id( struct block_list* src, struct block_list *bl,int skillid,int skilllv,unsigned int tick,int flag );
int skill_castend_pos2( struct block_list *src, int x,int y,int skillid,int skilllv,unsigned int tick,int flag);
-
int skill_blockpc_start (struct map_session_data*,int,int); // [celest]
// スキル攻?一括?理
@@ -790,7 +789,6 @@ enum {
AM_TWILIGHT2,
AM_TWILIGHT3,
HT_POWER,
-
GS_GLITTERING,
GS_FLING,
GS_TRIPLEACTION,