diff options
Diffstat (limited to 'src')
-rw-r--r-- | src/common/grfio.c | 2 | ||||
-rw-r--r-- | src/map/atcommand.c | 4 | ||||
-rw-r--r-- | src/map/map.h | 7 | ||||
-rw-r--r-- | src/map/script.c | 4 | ||||
-rw-r--r-- | src/map/unit.c | 4 |
5 files changed, 8 insertions, 13 deletions
diff --git a/src/common/grfio.c b/src/common/grfio.c index 9c557849a..f5de9fbdb 100644 --- a/src/common/grfio.c +++ b/src/common/grfio.c @@ -445,7 +445,7 @@ void* grfio_reads(char* fname, int* size) lentry.declen = ftell(in); } fseek(in,0,SEEK_SET); - buf2 = (unsigned char *)malloc(lentry.declen + 1024); + buf2 = (unsigned char *)aMallocA(lentry.declen + 1024); fread(buf2, 1, lentry.declen, in); fclose(in); strncpy(lentry.fn, fname, sizeof(lentry.fn) - 1); diff --git a/src/map/atcommand.c b/src/map/atcommand.c index b72b46cc9..642a1f97e 100644 --- a/src/map/atcommand.c +++ b/src/map/atcommand.c @@ -9301,9 +9301,7 @@ int atcommand_request(const int fd, struct map_session_data* sd, const char* com /*========================================== * Feel (SG save map) Reset [HiddenDragon] *------------------------------------------*/ -int atcommand_feelreset( - const int fd, struct map_session_data* sd, - const char* command, const char* message) +int atcommand_feelreset(const int fd, struct map_session_data* sd, const char* command, const char* message) { pc_resetfeel(sd); clif_displaymessage(fd, "Reset 'Feeling' maps."); diff --git a/src/map/map.h b/src/map/map.h index 4ff29327b..32fea8239 100644 --- a/src/map/map.h +++ b/src/map/map.h @@ -38,7 +38,6 @@ #define LIFETIME_FLOORITEM 60 #define DAMAGELOG_SIZE 30 #define LOOTITEM_SIZE 10 -//#define MAX_STATUSCHANGE 300 //Quick defines to know which are the min-max common ailments. [Skotlex] //Because of the way the headers are included.. these must be replaced for actual values. //Remember to update as needed! Min is SC_STONE and max is SC_DPOISON currently. @@ -1033,9 +1032,9 @@ struct pet_data { // state of a single attack attempt; used in flee/def penalty calculations when mobbed enum { - ATK_LUCKY=1, // attack was lucky-dodged - ATK_FLEE, // attack was dodged - ATK_DEF // attack connected + ATK_LUCKY=1, // attack was lucky-dodged + ATK_FLEE, // attack was dodged + ATK_DEF // attack connected }; struct map_data { diff --git a/src/map/script.c b/src/map/script.c index 7432cad79..2a4c4ccc5 100644 --- a/src/map/script.c +++ b/src/map/script.c @@ -2375,7 +2375,7 @@ int isstr(struct script_data *c) return 0; } -/// Triary operators +/// Ternary operators /// test ? if_true : if_false void op_3(struct script_state* st, int op) { @@ -3825,9 +3825,7 @@ BUILDIN_FUNC(sleep); BUILDIN_FUNC(sleep2); BUILDIN_FUNC(awake); BUILDIN_FUNC(getvariableofnpc); -// [blackhole89] --> BUILDIN_FUNC(warpportal); -// <-- [blackhole89] BUILDIN_FUNC(homunculus_evolution) ; //[orn] BUILDIN_FUNC(eaclass); BUILDIN_FUNC(roclass); diff --git a/src/map/unit.c b/src/map/unit.c index b1612f986..77a305f18 100644 --- a/src/map/unit.c +++ b/src/map/unit.c @@ -1546,7 +1546,7 @@ static int unit_counttargeted_sub(struct block_list* bl, va_list ap) /*========================================== * Counts the number of units attacking 'bl' - *------------------------------------------*/ + *------------------------------------------*/ int unit_counttargeted(struct block_list* bl, int target_lv) { nullpo_retr(0, bl); @@ -1784,7 +1784,7 @@ int unit_free(struct block_list *bl, int clrtype) status_change_end(bl,SC_REGENERATION,-1); } if (battle_config.debuff_on_logout&2) - { //Food items are removed on logout. + { if(sd->sc.data[SC_MAXIMIZEPOWER].timer!=-1) status_change_end(bl,SC_MAXIMIZEPOWER,-1); if(sd->sc.data[SC_MAXOVERTHRUST].timer!=-1) |