file props

git-svn-id: https://svn.code.sf.net/p/rathena/svn/branches/stable@516 54d463be-8e91-2dee-dedb-b68131a5f0ec
This commit is contained in:
amber 2004-12-08 22:53:15 +00:00
parent 0e2dc649d9
commit 01073deb62
8 changed files with 200 additions and 108 deletions

View File

@ -1,10 +1,10 @@
Post any NPCs/DBs that need to be done or Fixed Here. Post any NPCs/DBs that need to be done or Fixed Here.
Format is: Format is:
Description - A description of the task Description - A description of the task
Type - Whether DB, NPC or Both Type - Whether DB, NPC or Both
Status - The status of the task. The possible values are Pending and Completed Status - The status of the task. The possible values are Pending and Completed
Assignee - The nickname of the person whom is assigned the task Assignee - The nickname of the person whom is assigned the task
Notes - Miscellaneous notes concerning the task Notes - Miscellaneous notes concerning the task
-------------------------- --------------------------

View File

@ -1,30 +1,30 @@
//===== eAthena Script ======================================= //===== eAthena Script =======================================
//= Heal Npc //= Heal Npc
//===== By: ================================================== //===== By: ==================================================
//= MC Cameri //= MC Cameri
//===== Current Version: ===================================== //===== Current Version: =====================================
//= 1.0 //= 1.0
//===== Compatible With: ===================================== //===== Compatible With: =====================================
//= eAthena 0.1+; //= eAthena 0.1+;
//===== Description: ========================================= //===== Description: =========================================
//= Poring Which Heals For Free //= Poring Which Heals For Free
//===== Additional Comments: ================================= //===== Additional Comments: =================================
//= You can use this one if you want simple one-click healing //= You can use this one if you want simple one-click healing
//============================================================ //============================================================
prontera.gat,150,184,5 script Healring::Healring0 1002,{ prontera.gat,150,184,5 script Healring::Healring0 1002,{
npctalk "Booing!"; npctalk "Booing!";
emotion 21; emotion 21;
percentheal 100,100; percentheal 100,100;
} }
morocc.gat,159,96,5 duplicate(Healring0) Healring 1002 morocc.gat,159,96,5 duplicate(Healring0) Healring 1002
geffen.gat,121,61,5 duplicate(Healring0) Healring 1002 geffen.gat,121,61,5 duplicate(Healring0) Healring 1002
payon.gat,180,105,5 duplicate(Healring0) Healring 1002 payon.gat,180,105,5 duplicate(Healring0) Healring 1002
alberta.gat,185,144,5 duplicate(Healring0) Healring 1002 alberta.gat,185,144,5 duplicate(Healring0) Healring 1002
aldebaran.gat,134,123,5 duplicate(Healring0) Healring 1002 aldebaran.gat,134,123,5 duplicate(Healring0) Healring 1002
izlude.gat,125,118,5 duplicate(Healring0) Healring 1002 izlude.gat,125,118,5 duplicate(Healring0) Healring 1002
xmas.gat,149,136,5 duplicate(Healring0) Healring 1002 xmas.gat,149,136,5 duplicate(Healring0) Healring 1002
comodo.gat,188,162,5 duplicate(Healring0) Healring 1002 comodo.gat,188,162,5 duplicate(Healring0) Healring 1002
amatsu.gat,200,80,5 duplicate(Healring0) Healring 1002 amatsu.gat,200,80,5 duplicate(Healring0) Healring 1002
gonryun.gat,164,130,5 duplicate(Healring0) Healring 1002 gonryun.gat,164,130,5 duplicate(Healring0) Healring 1002

View File

@ -1,57 +1,57 @@
//===== eAthena Script ======================================= //===== eAthena Script =======================================
//= Fox Mask Quest //= Fox Mask Quest
//===== By: ================================================== //===== By: ==================================================
//= KitsuneStarWind (1.0) //= KitsuneStarWind (1.0)
//= Mass Zero (1.1) //= Mass Zero (1.1)
//===== Current Version: ===================================== //===== Current Version: =====================================
//= 1.2 //= 1.2
//===== Compatible With: ===================================== //===== Compatible With: =====================================
//= Any eAthena version. //= Any eAthena version.
//===== Description: ========================================= //===== Description: =========================================
// Seperate quest for the Fox Mask. // Seperate quest for the Fox Mask.
//===== Additional Comments: ================================= //===== Additional Comments: =================================
// 1.2 optimized [Lupus] // 1.2 optimized [Lupus]
//============================================================ //============================================================
pay_dun04.gat,204,152,2 script Nine Tail 1180,{ pay_dun04.gat,204,152,2 script Nine Tail 1180,{
mes "[Nine Tail]"; mes "[Nine Tail]";
mes "What do you want?"; mes "What do you want?";
next; next;
mes "[Nine Tail]"; mes "[Nine Tail]";
mes "Have you come here for a ^FF3300 Fox Mask^000000?"; mes "Have you come here for a ^FF3300 Fox Mask^000000?";
next; next;
menu "Yeah, Sure.",-,"No",M_EXIT; menu "Yeah, Sure.",-,"No",M_EXIT;
mes "[Nine Tail]"; mes "[Nine Tail]";
mes "Fine then. If I make one for you, will you go away?"; mes "Fine then. If I make one for you, will you go away?";
mes "You realize that it requires 999 Nine Tails to make, do you?"; mes "You realize that it requires 999 Nine Tails to make, do you?";
next; next;
menu "Sure.",M_MAKE,"Nah.",-; menu "Sure.",M_MAKE,"Nah.",-;
mes "[Nine Tail]"; mes "[Nine Tail]";
mes "Grrrr... I'll make one anyway but I hope my master gets you."; mes "Grrrr... I'll make one anyway but I hope my master gets you.";
next; next;
M_MAKE: M_MAKE:
mes "[Nine Tail]"; mes "[Nine Tail]";
mes "Ok then, I shall make one for you."; mes "Ok then, I shall make one for you.";
next; next;
if (countitem(1022) < 999) goto L_NOITEM;//Items: Nine Tails, if (countitem(1022) < 999) goto L_NOITEM;//Items: Nine Tails,
delitem 1022,999;//Items: Nine Tails, delitem 1022,999;//Items: Nine Tails,
getitem 5069,1;//Items: Fox Mask, getitem 5069,1;//Items: Fox Mask,
next; next;
mes "[Nine Tails]"; mes "[Nine Tails]";
mes "Have fun."; mes "Have fun.";
close; close;
L_NOITEM: L_NOITEM:
mes "[Nine Tail]"; mes "[Nine Tail]";
mes "You do not have have enough Nine Tails."; mes "You do not have have enough Nine Tails.";
mes "You need 999 of them."; mes "You need 999 of them.";
close; close;
M_EXIT: M_EXIT:
mes "[Nine Tail]"; mes "[Nine Tail]";
mes "Then leave me alone... I am waiting for my master."; mes "Then leave me alone... I am waiting for my master.";
close; close;
} }

View File

@ -1,3 +1,6 @@
DROP DATABASE erag;
CREATE DATABASE erag;
USE erag;
CREATE TABLE `item_db` ( CREATE TABLE `item_db` (
`id` smallint(5) unsigned NOT NULL default '0', `id` smallint(5) unsigned NOT NULL default '0',
`name_english` varchar(24) NOT NULL default '', `name_english` varchar(24) NOT NULL default '',
@ -1515,7 +1518,7 @@ INSERT INTO `item_db` VALUES (7252, 'Unknown_Item', '???', 3, NULL, NULL, 10, NU
INSERT INTO `item_db` VALUES (7253, 'Unknown_Item', '??????', 3, NULL, NULL, 10, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL); INSERT INTO `item_db` VALUES (7253, 'Unknown_Item', '??????', 3, NULL, NULL, 10, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL);
INSERT INTO `item_db` VALUES (7254, 'Unknown_Item', '???????', 3, NULL, NULL, 10, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL); INSERT INTO `item_db` VALUES (7254, 'Unknown_Item', '???????', 3, NULL, NULL, 10, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL);
INSERT INTO `item_db` VALUES (7262, 'Grave_Lump', 'Grave Lump', 3, 233, 10, 10, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL); INSERT INTO `item_db` VALUES (7262, 'Grave_Lump', 'Grave Lump', 3, 233, 10, 10, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL);
INSERT INTO `item_db` VALUES (7263, 'Cat's_Eye', 'Cat's-Eye', 3, NULL, 477, 10, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL); INSERT INTO `item_db` VALUES (7263, 'Cats_Eye', 'Cats-Eye', 3, NULL, 477, 10, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL);
INSERT INTO `item_db` VALUES (7264, 'Dried_Sand', 'Dried Sand', 3, NULL, 161, 10, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL); INSERT INTO `item_db` VALUES (7264, 'Dried_Sand', 'Dried Sand', 3, NULL, 161, 10, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL);
INSERT INTO `item_db` VALUES (7265, 'Dragon_Horn', 'Dragon Horn', 3, NULL, 272, 10, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL); INSERT INTO `item_db` VALUES (7265, 'Dragon_Horn', 'Dragon Horn', 3, NULL, 272, 10, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL);
INSERT INTO `item_db` VALUES (7266, 'Dragon_Teeth', 'Dragon Teeth', 3, 218, 10, 10, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL); INSERT INTO `item_db` VALUES (7266, 'Dragon_Teeth', 'Dragon Teeth', 3, 218, 10, 10, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL);

View File

@ -3426,9 +3426,20 @@ static struct Damage battle_calc_pc_weapon_attack(
damage2 += damage2*(30*skill_lv)/100; damage2 += damage2*(30*skill_lv)/100;
break; break;
case CG_ARROWVULCAN: /* アローバルカン */ case CG_ARROWVULCAN: /* アローバルカン */
if(!sd->state.arrow_atk && sd->arrow_atk > 0) {
int arr = rand()%(sd->arrow_atk+1);
damage += arr;
damage2 += arr;
}
damage = damage*(200+100*skill_lv)/100; damage = damage*(200+100*skill_lv)/100;
damage2 = damage2*(200+100*skill_lv)/100; damage2 = damage2*(200+100*skill_lv)/100;
div_=9; div_=9;
if(sd->arrow_ele > 0) {
s_ele = sd->arrow_ele;
s_ele_ = sd->arrow_ele;
}
flag=(flag&~BF_RANGEMASK)|BF_LONG;
sd->state.arrow_atk = 1;
break; break;
case AS_SPLASHER: /* ベナムスプラッシャー */ case AS_SPLASHER: /* ベナムスプラッシャー */
damage = damage*(200+20*skill_lv+20*pc_checkskill(sd,AS_POISONREACT))/100; damage = damage*(200+20*skill_lv+20*pc_checkskill(sd,AS_POISONREACT))/100;

View File

@ -980,17 +980,7 @@ int chrif_parse(int fd)
if (fd == char_fd) { if (fd == char_fd) {
printf("Map-server can't connect to char-server (connection #%d).\n", fd); printf("Map-server can't connect to char-server (connection #%d).\n", fd);
char_fd = -1; char_fd = -1;
check_connect_char_server(0, 0, 0, 0); // check_connect_char_server(0, 0, 0, 0);
while (char_fd <= 0 || session[char_fd] == NULL) {
struct map_session_data *sd;
int idx;
for (idx = 0; idx <fd_max; idx++)
if ((session[idx] != NULL) && (sd = session[idx]->session_data) && sd && sd->state.auth)
clif_displaymessage(idx, "Map server is paused waiting for char server to return..");
flush_fifos();
sleep(10);
check_connect_char_server(0, 0, 0, 0);
}
} }
close(fd); close(fd);
delete_session(fd); delete_session(fd);

View File

@ -54,10 +54,16 @@ extern int char_fd; // inter server
//----------------------------------------------------------------- //-----------------------------------------------------------------
// inter serverへの送信 // inter serverへの送信
int CheckForCharServer() {
return ((char_fd == -1) || session[char_fd] == NULL || session[char_fd]->wdata == NULL);
}
// pet // pet
int intif_create_pet(int account_id,int char_id,short pet_class,short pet_lv,short pet_egg_id, int intif_create_pet(int account_id,int char_id,short pet_class,short pet_lv,short pet_egg_id,
short pet_equip,short intimate,short hungry,char rename_flag,char incuvate,char *pet_name) short pet_equip,short intimate,short hungry,char rename_flag,char incuvate,char *pet_name)
{ {
if (CheckForCharServer())
return 0;
WFIFOW(inter_fd,0) = 0x3080; WFIFOW(inter_fd,0) = 0x3080;
WFIFOL(inter_fd,2) = account_id; WFIFOL(inter_fd,2) = account_id;
WFIFOL(inter_fd,6) = char_id; WFIFOL(inter_fd,6) = char_id;
@ -77,6 +83,8 @@ int intif_create_pet(int account_id,int char_id,short pet_class,short pet_lv,sho
int intif_request_petdata(int account_id,int char_id,int pet_id) int intif_request_petdata(int account_id,int char_id,int pet_id)
{ {
if (CheckForCharServer())
return 0;
WFIFOW(inter_fd,0) = 0x3081; WFIFOW(inter_fd,0) = 0x3081;
WFIFOL(inter_fd,2) = account_id; WFIFOL(inter_fd,2) = account_id;
WFIFOL(inter_fd,6) = char_id; WFIFOL(inter_fd,6) = char_id;
@ -88,6 +96,8 @@ int intif_request_petdata(int account_id,int char_id,int pet_id)
int intif_save_petdata(int account_id,struct s_pet *p) int intif_save_petdata(int account_id,struct s_pet *p)
{ {
if (CheckForCharServer())
return 0;
WFIFOW(inter_fd,0) = 0x3082; WFIFOW(inter_fd,0) = 0x3082;
WFIFOW(inter_fd,2) = sizeof(struct s_pet) + 8; WFIFOW(inter_fd,2) = sizeof(struct s_pet) + 8;
WFIFOL(inter_fd,4) = account_id; WFIFOL(inter_fd,4) = account_id;
@ -99,6 +109,8 @@ int intif_save_petdata(int account_id,struct s_pet *p)
int intif_delete_petdata(int pet_id) int intif_delete_petdata(int pet_id)
{ {
if (CheckForCharServer())
return 0;
WFIFOW(inter_fd,0) = 0x3083; WFIFOW(inter_fd,0) = 0x3083;
WFIFOL(inter_fd,2) = pet_id; WFIFOL(inter_fd,2) = pet_id;
WFIFOSET(inter_fd,6); WFIFOSET(inter_fd,6);
@ -110,6 +122,8 @@ int intif_delete_petdata(int pet_id)
int intif_GMmessage(char* mes,int len,int flag) int intif_GMmessage(char* mes,int len,int flag)
{ {
int lp = (flag&0x10) ? 8 : 4; int lp = (flag&0x10) ? 8 : 4;
if (CheckForCharServer())
return 0;
WFIFOW(inter_fd,0) = 0x3000; WFIFOW(inter_fd,0) = 0x3000;
WFIFOW(inter_fd,2) = lp + len; WFIFOW(inter_fd,2) = lp + len;
WFIFOL(inter_fd,4) = 0x65756c62; WFIFOL(inter_fd,4) = 0x65756c62;
@ -122,6 +136,8 @@ int intif_GMmessage(char* mes,int len,int flag)
// The transmission of Wisp/Page to inter-server (player not found on this server) // The transmission of Wisp/Page to inter-server (player not found on this server)
int intif_wis_message(struct map_session_data *sd, char *nick, char *mes, int mes_len) { int intif_wis_message(struct map_session_data *sd, char *nick, char *mes, int mes_len) {
nullpo_retr(0, sd); nullpo_retr(0, sd);
if (CheckForCharServer())
return 0;
WFIFOW(inter_fd,0) = 0x3001; WFIFOW(inter_fd,0) = 0x3001;
WFIFOW(inter_fd,2) = mes_len + 52; WFIFOW(inter_fd,2) = mes_len + 52;
@ -138,6 +154,8 @@ int intif_wis_message(struct map_session_data *sd, char *nick, char *mes, int me
// The reply of Wisp/page // The reply of Wisp/page
int intif_wis_replay(int id, int flag) { int intif_wis_replay(int id, int flag) {
if (CheckForCharServer())
return 0;
WFIFOW(inter_fd,0) = 0x3002; WFIFOW(inter_fd,0) = 0x3002;
WFIFOL(inter_fd,2) = id; WFIFOL(inter_fd,2) = id;
WFIFOB(inter_fd,6) = flag; // flag: 0: success to send wisper, 1: target character is not loged in?, 2: ignored by target WFIFOB(inter_fd,6) = flag; // flag: 0: success to send wisper, 1: target character is not loged in?, 2: ignored by target
@ -151,6 +169,8 @@ int intif_wis_replay(int id, int flag) {
// The transmission of GM only Wisp/Page from server to inter-server // The transmission of GM only Wisp/Page from server to inter-server
int intif_wis_message_to_gm(char *Wisp_name, int min_gm_level, char *mes, int mes_len) { int intif_wis_message_to_gm(char *Wisp_name, int min_gm_level, char *mes, int mes_len) {
if (CheckForCharServer())
return 0;
WFIFOW(inter_fd,0) = 0x3003; WFIFOW(inter_fd,0) = 0x3003;
WFIFOW(inter_fd,2) = mes_len + 30; WFIFOW(inter_fd,2) = mes_len + 30;
memcpy(WFIFOP(inter_fd,4), Wisp_name, 24); memcpy(WFIFOP(inter_fd,4), Wisp_name, 24);
@ -167,6 +187,8 @@ int intif_wis_message_to_gm(char *Wisp_name, int min_gm_level, char *mes, int me
// アカウント変数送信 // アカウント変数送信
int intif_saveaccountreg(struct map_session_data *sd) { int intif_saveaccountreg(struct map_session_data *sd) {
int j,p; int j,p;
if (CheckForCharServer())
return 0;
nullpo_retr(0, sd); nullpo_retr(0, sd);
@ -184,6 +206,8 @@ int intif_saveaccountreg(struct map_session_data *sd) {
int intif_request_accountreg(struct map_session_data *sd) int intif_request_accountreg(struct map_session_data *sd)
{ {
nullpo_retr(0, sd); nullpo_retr(0, sd);
if (CheckForCharServer())
return 0;
WFIFOW(inter_fd,0) = 0x3005; WFIFOW(inter_fd,0) = 0x3005;
WFIFOL(inter_fd,2) = sd->bl.id; WFIFOL(inter_fd,2) = sd->bl.id;
@ -194,6 +218,8 @@ int intif_request_accountreg(struct map_session_data *sd)
// 倉庫データ要求 // 倉庫データ要求
int intif_request_storage(int account_id) int intif_request_storage(int account_id)
{ {
if (CheckForCharServer())
return 0;
WFIFOW(inter_fd,0) = 0x3010; WFIFOW(inter_fd,0) = 0x3010;
WFIFOL(inter_fd,2) = account_id; WFIFOL(inter_fd,2) = account_id;
WFIFOSET(inter_fd,6); WFIFOSET(inter_fd,6);
@ -202,6 +228,8 @@ int intif_request_storage(int account_id)
// 倉庫データ送信 // 倉庫データ送信
int intif_send_storage(struct storage *stor) int intif_send_storage(struct storage *stor)
{ {
if (CheckForCharServer())
return 0;
nullpo_retr(0, stor); nullpo_retr(0, stor);
WFIFOW(inter_fd,0) = 0x3011; WFIFOW(inter_fd,0) = 0x3011;
WFIFOW(inter_fd,2) = sizeof(struct storage)+8; WFIFOW(inter_fd,2) = sizeof(struct storage)+8;
@ -213,6 +241,8 @@ int intif_send_storage(struct storage *stor)
int intif_request_guild_storage(int account_id,int guild_id) int intif_request_guild_storage(int account_id,int guild_id)
{ {
if (CheckForCharServer())
return 0;
WFIFOW(inter_fd,0) = 0x3018; WFIFOW(inter_fd,0) = 0x3018;
WFIFOL(inter_fd,2) = account_id; WFIFOL(inter_fd,2) = account_id;
WFIFOL(inter_fd,6) = guild_id; WFIFOL(inter_fd,6) = guild_id;
@ -221,6 +251,8 @@ int intif_request_guild_storage(int account_id,int guild_id)
} }
int intif_send_guild_storage(int account_id,struct guild_storage *gstor) int intif_send_guild_storage(int account_id,struct guild_storage *gstor)
{ {
if (CheckForCharServer())
return 0;
WFIFOW(inter_fd,0) = 0x3019; WFIFOW(inter_fd,0) = 0x3019;
WFIFOW(inter_fd,2) = sizeof(struct guild_storage)+12; WFIFOW(inter_fd,2) = sizeof(struct guild_storage)+12;
WFIFOL(inter_fd,4) = account_id; WFIFOL(inter_fd,4) = account_id;
@ -233,6 +265,8 @@ int intif_send_guild_storage(int account_id,struct guild_storage *gstor)
// パーティ作成要求 // パーティ作成要求
int intif_create_party(struct map_session_data *sd,char *name) int intif_create_party(struct map_session_data *sd,char *name)
{ {
if (CheckForCharServer())
return 0;
nullpo_retr(0, sd); nullpo_retr(0, sd);
WFIFOW(inter_fd,0) = 0x3020; WFIFOW(inter_fd,0) = 0x3020;
@ -249,6 +283,8 @@ int intif_create_party(struct map_session_data *sd,char *name)
// パーティ情報要求 // パーティ情報要求
int intif_request_partyinfo(int party_id) int intif_request_partyinfo(int party_id)
{ {
if (CheckForCharServer())
return 0;
WFIFOW(inter_fd,0) = 0x3021; WFIFOW(inter_fd,0) = 0x3021;
WFIFOL(inter_fd,2) = party_id; WFIFOL(inter_fd,2) = party_id;
WFIFOSET(inter_fd,6); WFIFOSET(inter_fd,6);
@ -260,6 +296,8 @@ int intif_request_partyinfo(int party_id)
int intif_party_addmember(int party_id,int account_id) int intif_party_addmember(int party_id,int account_id)
{ {
struct map_session_data *sd; struct map_session_data *sd;
if (CheckForCharServer())
return 0;
sd=map_id2sd(account_id); sd=map_id2sd(account_id);
// if(battle_config.etc_log) // if(battle_config.etc_log)
// printf("intif: party add member %d %d\n",party_id,account_id); // printf("intif: party add member %d %d\n",party_id,account_id);
@ -277,6 +315,8 @@ int intif_party_addmember(int party_id,int account_id)
// パーティ設定変更 // パーティ設定変更
int intif_party_changeoption(int party_id,int account_id,int exp,int item) int intif_party_changeoption(int party_id,int account_id,int exp,int item)
{ {
if (CheckForCharServer())
return 0;
WFIFOW(inter_fd,0)=0x3023; WFIFOW(inter_fd,0)=0x3023;
WFIFOL(inter_fd,2)=party_id; WFIFOL(inter_fd,2)=party_id;
WFIFOL(inter_fd,6)=account_id; WFIFOL(inter_fd,6)=account_id;
@ -288,6 +328,8 @@ int intif_party_changeoption(int party_id,int account_id,int exp,int item)
// パーティ脱退要求 // パーティ脱退要求
int intif_party_leave(int party_id,int account_id) int intif_party_leave(int party_id,int account_id)
{ {
if (CheckForCharServer())
return 0;
// if(battle_config.etc_log) // if(battle_config.etc_log)
// printf("intif: party leave %d %d\n",party_id,account_id); // printf("intif: party leave %d %d\n",party_id,account_id);
WFIFOW(inter_fd,0)=0x3024; WFIFOW(inter_fd,0)=0x3024;
@ -299,6 +341,8 @@ int intif_party_leave(int party_id,int account_id)
// パーティ移動要求 // パーティ移動要求
int intif_party_changemap(struct map_session_data *sd,int online) int intif_party_changemap(struct map_session_data *sd,int online)
{ {
if (CheckForCharServer())
return 0;
if(sd!=NULL){ if(sd!=NULL){
WFIFOW(inter_fd,0)=0x3025; WFIFOW(inter_fd,0)=0x3025;
WFIFOL(inter_fd,2)=sd->status.party_id; WFIFOL(inter_fd,2)=sd->status.party_id;
@ -315,6 +359,8 @@ int intif_party_changemap(struct map_session_data *sd,int online)
// パーティー解散要求 // パーティー解散要求
int intif_break_party(int party_id) int intif_break_party(int party_id)
{ {
if (CheckForCharServer())
return 0;
WFIFOW(inter_fd,0)=0x3026; WFIFOW(inter_fd,0)=0x3026;
WFIFOL(inter_fd,2)=party_id; WFIFOL(inter_fd,2)=party_id;
WFIFOSET(inter_fd,6); WFIFOSET(inter_fd,6);
@ -323,6 +369,8 @@ int intif_break_party(int party_id)
// パーティ会話送信 // パーティ会話送信
int intif_party_message(int party_id,int account_id,char *mes,int len) int intif_party_message(int party_id,int account_id,char *mes,int len)
{ {
if (CheckForCharServer())
return 0;
// if(battle_config.etc_log) // if(battle_config.etc_log)
// printf("intif_party_message: %s\n",mes); // printf("intif_party_message: %s\n",mes);
WFIFOW(inter_fd,0)=0x3027; WFIFOW(inter_fd,0)=0x3027;
@ -336,6 +384,8 @@ int intif_party_message(int party_id,int account_id,char *mes,int len)
// パーティ競合チェック要求 // パーティ競合チェック要求
int intif_party_checkconflict(int party_id,int account_id,char *nick) int intif_party_checkconflict(int party_id,int account_id,char *nick)
{ {
if (CheckForCharServer())
return 0;
WFIFOW(inter_fd,0)=0x3028; WFIFOW(inter_fd,0)=0x3028;
WFIFOL(inter_fd,2)=party_id; WFIFOL(inter_fd,2)=party_id;
WFIFOL(inter_fd,6)=account_id; WFIFOL(inter_fd,6)=account_id;
@ -347,6 +397,8 @@ int intif_party_checkconflict(int party_id,int account_id,char *nick)
// ギルド作成要求 // ギルド作成要求
int intif_guild_create(const char *name,const struct guild_member *master) int intif_guild_create(const char *name,const struct guild_member *master)
{ {
if (CheckForCharServer())
return 0;
nullpo_retr(0, master); nullpo_retr(0, master);
WFIFOW(inter_fd,0)=0x3030; WFIFOW(inter_fd,0)=0x3030;
@ -360,6 +412,8 @@ int intif_guild_create(const char *name,const struct guild_member *master)
// ギルド情報要求 // ギルド情報要求
int intif_guild_request_info(int guild_id) int intif_guild_request_info(int guild_id)
{ {
if (CheckForCharServer())
return 0;
WFIFOW(inter_fd,0) = 0x3031; WFIFOW(inter_fd,0) = 0x3031;
WFIFOL(inter_fd,2) = guild_id; WFIFOL(inter_fd,2) = guild_id;
WFIFOSET(inter_fd,6); WFIFOSET(inter_fd,6);
@ -368,6 +422,8 @@ int intif_guild_request_info(int guild_id)
// ギルドメンバ追加要求 // ギルドメンバ追加要求
int intif_guild_addmember(int guild_id,struct guild_member *m) int intif_guild_addmember(int guild_id,struct guild_member *m)
{ {
if (CheckForCharServer())
return 0;
WFIFOW(inter_fd,0) = 0x3032; WFIFOW(inter_fd,0) = 0x3032;
WFIFOW(inter_fd,2) = sizeof(struct guild_member)+8; WFIFOW(inter_fd,2) = sizeof(struct guild_member)+8;
WFIFOL(inter_fd,4) = guild_id; WFIFOL(inter_fd,4) = guild_id;
@ -378,6 +434,8 @@ int intif_guild_addmember(int guild_id,struct guild_member *m)
// ギルドメンバ脱退/追放要求 // ギルドメンバ脱退/追放要求
int intif_guild_leave(int guild_id,int account_id,int char_id,int flag,const char *mes) int intif_guild_leave(int guild_id,int account_id,int char_id,int flag,const char *mes)
{ {
if (CheckForCharServer())
return 0;
WFIFOW(inter_fd, 0) = 0x3034; WFIFOW(inter_fd, 0) = 0x3034;
WFIFOL(inter_fd, 2) = guild_id; WFIFOL(inter_fd, 2) = guild_id;
WFIFOL(inter_fd, 6) = account_id; WFIFOL(inter_fd, 6) = account_id;
@ -391,6 +449,8 @@ int intif_guild_leave(int guild_id,int account_id,int char_id,int flag,const cha
int intif_guild_memberinfoshort(int guild_id, int intif_guild_memberinfoshort(int guild_id,
int account_id,int char_id,int online,int lv,int class) int account_id,int char_id,int online,int lv,int class)
{ {
if (CheckForCharServer())
return 0;
WFIFOW(inter_fd, 0) = 0x3035; WFIFOW(inter_fd, 0) = 0x3035;
WFIFOL(inter_fd, 2) = guild_id; WFIFOL(inter_fd, 2) = guild_id;
WFIFOL(inter_fd, 6) = account_id; WFIFOL(inter_fd, 6) = account_id;
@ -404,6 +464,8 @@ int intif_guild_memberinfoshort(int guild_id,
// ギルド解散通知 // ギルド解散通知
int intif_guild_break(int guild_id) int intif_guild_break(int guild_id)
{ {
if (CheckForCharServer())
return 0;
WFIFOW(inter_fd, 0) = 0x3036; WFIFOW(inter_fd, 0) = 0x3036;
WFIFOL(inter_fd, 2) = guild_id; WFIFOL(inter_fd, 2) = guild_id;
WFIFOSET(inter_fd,6); WFIFOSET(inter_fd,6);
@ -412,6 +474,8 @@ int intif_guild_break(int guild_id)
// ギルド会話送信 // ギルド会話送信
int intif_guild_message(int guild_id,int account_id,char *mes,int len) int intif_guild_message(int guild_id,int account_id,char *mes,int len)
{ {
if (CheckForCharServer())
return 0;
WFIFOW(inter_fd,0)=0x3037; WFIFOW(inter_fd,0)=0x3037;
WFIFOW(inter_fd,2)=len+12; WFIFOW(inter_fd,2)=len+12;
WFIFOL(inter_fd,4)=guild_id; WFIFOL(inter_fd,4)=guild_id;
@ -423,6 +487,8 @@ int intif_guild_message(int guild_id,int account_id,char *mes,int len)
// ギルド競合チェック要求 // ギルド競合チェック要求
int intif_guild_checkconflict(int guild_id,int account_id,int char_id) int intif_guild_checkconflict(int guild_id,int account_id,int char_id)
{ {
if (CheckForCharServer())
return 0;
WFIFOW(inter_fd, 0)=0x3038; WFIFOW(inter_fd, 0)=0x3038;
WFIFOL(inter_fd, 2)=guild_id; WFIFOL(inter_fd, 2)=guild_id;
WFIFOL(inter_fd, 6)=account_id; WFIFOL(inter_fd, 6)=account_id;
@ -433,6 +499,8 @@ int intif_guild_checkconflict(int guild_id,int account_id,int char_id)
// ギルド基本情報変更要求 // ギルド基本情報変更要求
int intif_guild_change_basicinfo(int guild_id,int type,const void *data,int len) int intif_guild_change_basicinfo(int guild_id,int type,const void *data,int len)
{ {
if (CheckForCharServer())
return 0;
WFIFOW(inter_fd,0)=0x3039; WFIFOW(inter_fd,0)=0x3039;
WFIFOW(inter_fd,2)=len+10; WFIFOW(inter_fd,2)=len+10;
WFIFOL(inter_fd,4)=guild_id; WFIFOL(inter_fd,4)=guild_id;
@ -445,6 +513,8 @@ int intif_guild_change_basicinfo(int guild_id,int type,const void *data,int len)
int intif_guild_change_memberinfo(int guild_id,int account_id,int char_id, int intif_guild_change_memberinfo(int guild_id,int account_id,int char_id,
int type,const void *data,int len) int type,const void *data,int len)
{ {
if (CheckForCharServer())
return 0;
WFIFOW(inter_fd, 0)=0x303a; WFIFOW(inter_fd, 0)=0x303a;
WFIFOW(inter_fd, 2)=len+18; WFIFOW(inter_fd, 2)=len+18;
WFIFOL(inter_fd, 4)=guild_id; WFIFOL(inter_fd, 4)=guild_id;
@ -458,6 +528,8 @@ int intif_guild_change_memberinfo(int guild_id,int account_id,int char_id,
// ギルド役職変更要求 // ギルド役職変更要求
int intif_guild_position(int guild_id,int idx,struct guild_position *p) int intif_guild_position(int guild_id,int idx,struct guild_position *p)
{ {
if (CheckForCharServer())
return 0;
WFIFOW(inter_fd,0)=0x303b; WFIFOW(inter_fd,0)=0x303b;
WFIFOW(inter_fd,2)=sizeof(struct guild_position)+12; WFIFOW(inter_fd,2)=sizeof(struct guild_position)+12;
WFIFOL(inter_fd,4)=guild_id; WFIFOL(inter_fd,4)=guild_id;
@ -469,6 +541,8 @@ int intif_guild_position(int guild_id,int idx,struct guild_position *p)
// ギルドスキルアップ要求 // ギルドスキルアップ要求
int intif_guild_skillup(int guild_id,int skill_num,int account_id,int flag) int intif_guild_skillup(int guild_id,int skill_num,int account_id,int flag)
{ {
if (CheckForCharServer())
return 0;
WFIFOW(inter_fd, 0)=0x303c; WFIFOW(inter_fd, 0)=0x303c;
WFIFOL(inter_fd, 2)=guild_id; WFIFOL(inter_fd, 2)=guild_id;
WFIFOL(inter_fd, 6)=skill_num; WFIFOL(inter_fd, 6)=skill_num;
@ -480,6 +554,8 @@ int intif_guild_skillup(int guild_id,int skill_num,int account_id,int flag)
// ギルド同盟/敵対要求 // ギルド同盟/敵対要求
int intif_guild_alliance(int guild_id1,int guild_id2,int account_id1,int account_id2,int flag) int intif_guild_alliance(int guild_id1,int guild_id2,int account_id1,int account_id2,int flag)
{ {
if (CheckForCharServer())
return 0;
WFIFOW(inter_fd, 0)=0x303d; WFIFOW(inter_fd, 0)=0x303d;
WFIFOL(inter_fd, 2)=guild_id1; WFIFOL(inter_fd, 2)=guild_id1;
WFIFOL(inter_fd, 6)=guild_id2; WFIFOL(inter_fd, 6)=guild_id2;
@ -492,6 +568,8 @@ int intif_guild_alliance(int guild_id1,int guild_id2,int account_id1,int account
// ギルド告知変更要求 // ギルド告知変更要求
int intif_guild_notice(int guild_id,const char *mes1,const char *mes2) int intif_guild_notice(int guild_id,const char *mes1,const char *mes2)
{ {
if (CheckForCharServer())
return 0;
WFIFOW(inter_fd,0)=0x303e; WFIFOW(inter_fd,0)=0x303e;
WFIFOL(inter_fd,2)=guild_id; WFIFOL(inter_fd,2)=guild_id;
memcpy(WFIFOP(inter_fd,6),mes1,60); memcpy(WFIFOP(inter_fd,6),mes1,60);
@ -502,6 +580,8 @@ int intif_guild_notice(int guild_id,const char *mes1,const char *mes2)
// ギルドエンブレム変更要求 // ギルドエンブレム変更要求
int intif_guild_emblem(int guild_id,int len,const char *data) int intif_guild_emblem(int guild_id,int len,const char *data)
{ {
if (CheckForCharServer())
return 0;
if(guild_id<=0 || len<0 || len>2000) if(guild_id<=0 || len<0 || len>2000)
return 0; return 0;
WFIFOW(inter_fd,0)=0x303f; WFIFOW(inter_fd,0)=0x303f;
@ -515,6 +595,8 @@ int intif_guild_emblem(int guild_id,int len,const char *data)
//現在のギルド城占領ギルドを調べる //現在のギルド城占領ギルドを調べる
int intif_guild_castle_dataload(int castle_id,int index) int intif_guild_castle_dataload(int castle_id,int index)
{ {
if (CheckForCharServer())
return 0;
WFIFOW(inter_fd,0)=0x3040; WFIFOW(inter_fd,0)=0x3040;
WFIFOW(inter_fd,2)=castle_id; WFIFOW(inter_fd,2)=castle_id;
WFIFOB(inter_fd,4)=index; WFIFOB(inter_fd,4)=index;
@ -525,6 +607,8 @@ int intif_guild_castle_dataload(int castle_id,int index)
//ギルド城占領ギルド変更要求 //ギルド城占領ギルド変更要求
int intif_guild_castle_datasave(int castle_id,int index, int value) int intif_guild_castle_datasave(int castle_id,int index, int value)
{ {
if (CheckForCharServer())
return 0;
WFIFOW(inter_fd,0)=0x3041; WFIFOW(inter_fd,0)=0x3041;
WFIFOW(inter_fd,2)=castle_id; WFIFOW(inter_fd,2)=castle_id;
WFIFOB(inter_fd,4)=index; WFIFOB(inter_fd,4)=index;

View File

@ -547,8 +547,12 @@ void map_foreachinmovearea(int (*func)(struct block_list*,va_list),int m,int x0,
map_freeblock_lock(); // メモリからの解放を禁止する map_freeblock_lock(); // メモリからの解放を禁止する
for(i=blockcount;i<bl_list_count;i++) for(i=blockcount;i<bl_list_count;i++)
if(bl_list[i]->prev) // 有効かどうかチェック if(bl_list[i]->prev) { // 有効かどうかチェック
if (bl_list[i]->type == BL_PC
&& session[((struct map_session_data *) bl_list[i])->fd] == NULL)
continue;
func(bl_list[i],ap); func(bl_list[i],ap);
}
map_freeblock_unlock(); // 解放を許可する map_freeblock_unlock(); // 解放を許可する