- Fog of Wall will fail when casted on top of a Volcano/Violent Gale

- Applied FlavioJS's fix to the npc whisper system.


git-svn-id: https://svn.code.sf.net/p/rathena/svn/trunk@9190 54d463be-8e91-2dee-dedb-b68131a5f0ec
This commit is contained in:
skotlex 2006-11-10 13:58:43 +00:00
parent 0b3a00dce8
commit 39f2b31168
3 changed files with 30 additions and 20 deletions

View File

@ -3,8 +3,11 @@ Date Added
AS OF SVN REV. 5091, WE ARE NOW USING TRUNK. ALL UNTESTED BUGFIXES/FEATURES GO INTO TRUNK. AS OF SVN REV. 5091, WE ARE NOW USING TRUNK. ALL UNTESTED BUGFIXES/FEATURES GO INTO TRUNK.
IF YOU HAVE A WORKING AND TESTED BUGFIX PUT IT INTO STABLE AS WELL AS TRUNK. IF YOU HAVE A WORKING AND TESTED BUGFIX PUT IT INTO STABLE AS WELL AS TRUNK.
2006/11/10
* Fog of Wall will fail when casted on top of a Volcano/Violent Gale
[Skotlex]
* Applied FlavioJS's fix to the npc whisper system. [Skotlex]
2006/11/09 2006/11/09
=======
* Fixed status-change loading not working. [Skotlex] * Fixed status-change loading not working. [Skotlex]
* Fixed permanent mob-spawn script-events not working. [Skotlex] * Fixed permanent mob-spawn script-events not working. [Skotlex]
* AL_CURE won't confuse undead players. [Skotlex] * AL_CURE won't confuse undead players. [Skotlex]

View File

@ -9044,7 +9044,6 @@ void clif_parse_Wis(int fd, struct map_session_data *sd) { // S 0096 <len>.w <ni
int i=0; int i=0;
struct npc_data *npc; struct npc_data *npc;
char split_data[10][50]; char split_data[10][50];
int j=0,k=0;
char target[NAME_LENGTH+1]; char target[NAME_LENGTH+1];
char output[256]; char output[256];
RFIFOHEAD(fd); RFIFOHEAD(fd);
@ -9089,32 +9088,36 @@ void clif_parse_Wis(int fd, struct map_session_data *sd) { // S 0096 <len>.w <ni
char *whisper_tmp = target+4; //Skip the NPC: string part. char *whisper_tmp = target+4; //Skip the NPC: string part.
if ((npc = npc_name2id(whisper_tmp))) if ((npc = npc_name2id(whisper_tmp)))
{ {
char *split, *str;
whisper_tmp=(char *)aMallocA((strlen((char *)(RFIFOP(fd,28)))+1)*sizeof(char)); whisper_tmp=(char *)aMallocA((strlen((char *)(RFIFOP(fd,28)))+1)*sizeof(char));
str=whisper_tmp;
sprintf(whisper_tmp, "%s", (const char*)RFIFOP(fd,28)); sprintf(whisper_tmp, "%s", (const char*)RFIFOP(fd,28));
for( j=0;whisper_tmp[j]!='\0';j++) for( i=0; i < 10; ++i )
{ {// Splits the message using '#' as separators
if(whisper_tmp[j]!='#') split = strchr(str,'#');
{ if( split == NULL )
split_data[i][j-k]=whisper_tmp[j]; { // use the remaining string
strncpy(split_data[i], str, sizeof(split_data[0])/sizeof(char));
split_data[i][sizeof(split_data[0])/sizeof(char)-1] = '\0';
for( ++i; i < 10; ++i )
split_data[i][0] = '\0';
break;
} }
else *split = '\0';
{ strncpy(split_data[i], str, sizeof(split_data[0])/sizeof(char));
split_data[i][j-k]='\0'; split_data[i][sizeof(split_data[0])/sizeof(char)-1] = '\0';
k=j+1; str = split+1;
i++; }
}
} // Splits the message using '#' as separators
split_data[i][j-k]='\0';
aFree(whisper_tmp); aFree(whisper_tmp);
whisper_tmp=(char *)aMallocA(15*sizeof(char)); whisper_tmp=(char *)aMallocA(15*sizeof(char));
for (j=0;j<=10;j++) for (i=0;i<10;i++)
{ {
sprintf(whisper_tmp, "@whispervar%d$", j); sprintf(whisper_tmp, "@whispervar%d$", i);
set_var(sd,whisper_tmp,(char *) split_data[j]); set_var(sd,whisper_tmp,(char *) split_data[i]);
}//You don't need to zero them, just reset them [Kevin] }//You don't need to zero them, iust reset them [Kevin]
aFree(whisper_tmp); aFree(whisper_tmp);
whisper_tmp=(char *)aMallocA((strlen(npc->name)+18)*sizeof(char)); whisper_tmp=(char *)aMallocA((strlen(npc->name)+18)*sizeof(char));

View File

@ -6662,6 +6662,10 @@ struct skill_unit_group *skill_unitsetting (struct block_list *src, int skillid,
val2 = skilllv*10; //Status ailment resistance val2 = skilllv*10; //Status ailment resistance
break; break;
case PF_FOGWALL: case PF_FOGWALL:
//When casted on top of Volcano/Violent Gale it fails.
if (map_find_skill_unit_oncell(src,x,y,SA_VOLCANO,NULL) ||
map_find_skill_unit_oncell(src,x,y,SA_VIOLENTGALE,NULL))
return NULL;
//When casted on top of Deluge/Suiton: Double duration. //When casted on top of Deluge/Suiton: Double duration.
if (map_find_skill_unit_oncell(src,x,y,SA_DELUGE,NULL) || if (map_find_skill_unit_oncell(src,x,y,SA_DELUGE,NULL) ||
map_find_skill_unit_oncell(src,x,y,NJ_SUITON,NULL)) map_find_skill_unit_oncell(src,x,y,NJ_SUITON,NULL))