summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorcelest <celest@54d463be-8e91-2dee-dedb-b68131a5f0ec>2005-03-30 11:44:12 +0000
committercelest <celest@54d463be-8e91-2dee-dedb-b68131a5f0ec>2005-03-30 11:44:12 +0000
commitc883ca205971275e576d34b54304c3c5c30f3580 (patch)
tree4d0a218a184099c61a311d65b50e93973c4c773a
parent230ba4e3dd84a19f7dee67fdc97532e5869bef63 (diff)
downloadhercules-c883ca205971275e576d34b54304c3c5c30f3580.tar.gz
hercules-c883ca205971275e576d34b54304c3c5c30f3580.tar.bz2
hercules-c883ca205971275e576d34b54304c3c5c30f3580.tar.xz
hercules-c883ca205971275e576d34b54304c3c5c30f3580.zip
* updated map server to jA1137~1159
* Some tidying up in mob.c and skill.c git-svn-id: https://rathena.svn.sourceforge.net/svnroot/rathena/branches/stable@1342 54d463be-8e91-2dee-dedb-b68131a5f0ec
-rw-r--r--Changelog-SVN.txt17
-rw-r--r--Readme-jap402
-rw-r--r--conf-tmpl/atcommand_athena.conf12
-rw-r--r--conf-tmpl/msg_athena.conf4
-rw-r--r--db/packet_db.txt2
-rw-r--r--db/skill_cast_db.txt6
-rw-r--r--db/skill_db.txt24
-rw-r--r--db/skill_require_db.txt2
-rw-r--r--db/skill_unit_db.txt2
-rw-r--r--src/map/atcommand.c71
-rw-r--r--src/map/atcommand.h4
-rw-r--r--src/map/battle.c4
-rw-r--r--src/map/clif.c56
-rw-r--r--src/map/guild.c20
-rw-r--r--src/map/mail.c39
-rw-r--r--src/map/map.c76
-rw-r--r--src/map/map.h15
-rw-r--r--src/map/mob.c76
-rw-r--r--src/map/mob.h1
-rw-r--r--src/map/party.c4
-rw-r--r--src/map/pc.c157
-rw-r--r--src/map/pc.h4
-rw-r--r--src/map/pet.c2
-rw-r--r--src/map/pet.h1
-rw-r--r--src/map/skill.c658
-rw-r--r--src/map/skill.h6
-rw-r--r--src/map/status.c11
-rw-r--r--src/map/status.h1
28 files changed, 1156 insertions, 521 deletions
diff --git a/Changelog-SVN.txt b/Changelog-SVN.txt
index cf19bf917..316f0d8c3 100644
--- a/Changelog-SVN.txt
+++ b/Changelog-SVN.txt
@@ -1,6 +1,23 @@
Date Added
+03/30
+ * updated map server to jA1137~1159
+ - Added @reloadatcommand, @reloadbattleconf, @reloadstatusdb, @reloadpcdb
+
+ (Note: You should copy the latest msg_athena.conf from conf-tmpl and replace
+ your current one EVERYTIME it's updated to prevent it from crashing when it
+ can't find the newer messages!)
+
+ - Updated packet DB to support /item and /monster
+ - Added pc_remove_map()
+ - Added 2 new mobs skills: NPC_RUNAWAY and RECALL
+ - Updated BioCannibalize
+ - Updated Hammerfall, Meteor Shower and Lord of Vermillion -- when MvP's
+ cast them they should have much more range
+ - Some other skill tweaks
+ * Some tidying up in mob.c and skill.c [celest]
+
03/29
* Please make sure to use the stable/sql-files/upgrade_svn1315.sql to
upgrade your mysql as a result of the new adoption system. Thank you
diff --git a/Readme-jap b/Readme-jap
index 3bc55cedd..f43c0499c 100644
--- a/Readme-jap
+++ b/Readme-jap
@@ -1,4 +1,406 @@
--------------------
+//1162 by pizza
+・スパイラルピアース・ソウルブレーカー・発勁・ファルコンアサルトについて本鯖準拠に修正
+
+ (db)
+ skill_db.txt
+ スパイラルピアース・ソウルブレーカーの射程
+ ソウルブレーカーが詠唱妨害可
+ skill_cast_db.txt
+ ソウルブレーカーの詠唱時間
+
+ (src/map)
+ battle.c
+ 発勁・ファルコンアサルトの計算式
+ スパイラルピアースがニュマで無効化
+
+--------------------
+//1161 by Nameless
+
+・バイオプラントによる召還mobのIDとスキルを本鯖準拠に修正
+ ※呼び出せる数についてはまだ未実装…
+
+ (db)
+ mob_avail.txt
+ クライアントによって発生する可能性のあるグラ問題の
+ 暫定対応
+ mob_db.txt
+ バイオプラント用mobのステを一部修正
+ mob_skill_db.txt
+ バイオプラント用mobにスキルを修正
+
+ (src/map)
+ skill.c - case AM_CANNIBALIZE: 修正
+
+--------------------
+//1160 by Nameless
+
+・1158のfix
+ フェアリーフの非移動化と呼び出されたMOBのHPを下方修正
+
+ (src/map)
+ skill.c - case AM_CANNIBALIZE: 修正
+
+--------------------
+//1158 by もっさり
+・mob後退実装  自分が向いてる方とは逆にskilllvの分ぐらい動きます
+ 離れすぎる呼び戻されないので取り巻き呼び戻しを修正
+ IWの斜め位置がおかしかったのを修正(バグ報告スレッド part8 >>110)
+
+ (src/map)
+ skill.c 呼び戻し修正、後退追加、IW修正
+ skill.h
+ mob.c
+ map.h
+ (db)
+ skill_db.txt
+--------------------
+//1158 by Nameless
+
+・アルケミのバイオプラントを修正
+ 各LVにあわせて、マンドラゴラ、ヒドラ、フローラ、フェアリーフ、ジオグラファー
+ を呼び出すようにした
+
+ (src/map)
+ skill.c - case AM_CANNIBALIZE: 修正
+
+--------------------
+//1157 by eigen
+
+・バードダンサースキルの使用でMAP鯖が落ちる不具合を修正
+
+ (src/map)
+ skill.c - skill_unit_onout() 修正
+
+--------------------
+//1156 by eigen
+
+・聖体降福使用時、モンクが人数カウントされていなかった不具合を修正
+(thanks to 本鯖相違スレpart3 >>121氏)
+・バードダンサースキルの効果が切れなかった不具合を修正
+
+ (src/map)
+ skill.c - skill_unit_onout(), skill_check_condition_char_sub() 修正
+
+--------------------
+//1155 by latte
+・ディボーションに詠唱時間付与
+・サクリファイス:倍率修正とボスに有効に。
+・グランドクロスのエフェクトの修正
+
+ (db)
+ skill_cast_db.txt
+ skill_db.txt
+ (src/map)
+ battle.c
+
+--------------------
+//1154 by eigen
+
+・バードダンサースキル使用でMAP鯖が落ちる問題を修正
+・ゴスペルの実装
+・マグナムブレイクの仕様を本鯖に合わせて変更(火属性追加ダメージは未実装です)
+
+ (db)
+ skill_cast_db.txt - ゴスペル, マグナムブレイクに関する修正
+ skill_require_db.txt - マグナムブレイクに関する修正
+ skill_unit_db.txt - ゴスペルに関する修正
+ (src/map)
+ battle.c - battle_calc_pet_weapon_attack(), battle_calc_mob_weapon_attack(),
+ battle_calc_pc_weapon_attack(), battle_calc_magic_attack() 修正
+ clif.c - clif_parse_UseSkillToId(), clif_parse_UseSkillToId(),
+ clif_parse_WalkToXY(), clif_parse_ActionRequest(),
+ clif_parse_UseSkillToId(), clif_parse_UseSkillMap() 修正
+ map.h - MAX_STATUSCHANGEの増加
+ pc.c - pc_natural_heal_sub() 修正
+ skill.h - マグナムブレイク, ゴスペルに関する状態異常テーブル追加
+ skill.c - skill_castend_damage_id(), skill_castend_nodamage_id(),
+ skill_unit_onout(), skill_unit_onplace_timer(),
+ skill_init_unit_layout() 修正
+ status.c - status_change_start(), status_change_end() 修正
+
+--------------------
+//1153 by ぽえ
+
+・ヒール、サンクの修正
+ (イビルドルイドC装備中にPv,Gv以外だとダメージが出ないように修正)
+ (該当PCにヒールを使用した場合SPだけ消費)
+・放置されてるversion.hの更新
+ (src/map)
+ skill.c - skill_castend_id(),skill_unit_onplace_timer() 修正
+ (src/common)
+ version.h - mod version 1153
+--------------------
+//1152 by p
+
+・鉱石発見修正
+ (db)
+ item_db.txt - 古い巻物の getitem 番号を戻し
+ (src/map)
+ itemdb.c - 鉱石発見時生成処理の変更
+ mob.c - 鉱石発見処理の変更
+--------------------
+//1151 by p
+
+・ブラックスミススキル鉱石発見の実装(仮)
+ (conf)
+ battle_athena.conf - 鉱石発見率の指定
+ (db)
+ item_findingore.txt - 鉱石ドロップ率の指定
+ item_db.txt - 古い巻物の getitem 番号変更
+ (src/map)
+ itemdb.c - db/item_findingore.txt の読み込みと発見時生成
+ battle.h - 設定保持用の項目追加
+ battle.c - 設定読み込み処理追加
+ mob.c - 鉱石発見処理追加
+
+--------------------
+//1150 by Theia
+
+・ベノムスプラッシャーをjRO仕様に変更
+ (完全ではないので補完希望)
+・シャープシューティングの計算式を変更
+ (今までの計算式だと必中していた)
+ (db)
+ skill_cast.txt
+ skill_require_db.txt
+ (src/map)
+ skill.c - ベノムスプラッシャーの発動条件を変更
+ battle.c - ベノムスプラッシャー,シャープシューティングの倍率を変更
+
+--------------------
+//1149 by eigen
+
+・一部のダンサーバードスキルの演奏スキル上から出るとMAP鯖が落ちる不具合を修正
+
+ (src/map)
+ skill.c - skill_unit_onout() 修正
+
+--------------------
+//1148 by eigen
+
+・ストリップスキルが詠唱中断されないよう変更
+・ストリップスキル成功率のスキルレベル比重を5に変更
+・バックスタブの射程を武器に関係なく1に変更
+・バックスタブ使用時、弓を装備しているならダメージ半減に変更
+・アシッドテラーとデモンストレーションが詠唱中断されるよう変更
+・アシッドテラー使用後、相手の鎧を破壊することに成功した場合ショックエモを出すよう変更
+・メルトダウンで破壊できる箇所を武器と鎧のみに変更
+・ダンサーバードの演奏スキル範囲外に出ても効果が20秒持続するよう変更
+(ただし私を忘れないでと合奏スキルは除く)
+・倉庫の最大収容量を300に変更
+(以上thanks to 本鯖相違スレPart3 >>115氏)
+・メルトダウン鎧破壊確率を0.7〜7%に変更
+
+ (db)
+ skill_db.txt - cast_cancel、rangeの修正
+ skill_unit_db.txt - (1148-fixの取り込み)
+ (src/common)
+ mmo.h - MAX_STORAGEを300に
+ (src/map)
+ battle.c - battle_calc_pc_weapon_attack() 修正
+ skill.c - skill_additional_effect(), skill_castend_nodamage_id(),
+ skill_castend_damage_id(), skill_unit_onout() 修正
+
+--------------------
+//1147 by eigen
+
+・インデュア使用後、10秒経たないと再使用できないよう変更
+・シーズモードではインデュアを使用するとMDEFが上がるだけに変更
+・残影使用後、2秒経たないと阿修羅を使用できないよう変更
+
+ (src/map)
+ map.h - #define MAX_SKILL_ID, unsigned int skillstatictimer[MAX_SKILL_ID] 追加
+ clif.c - clif_parse_UseSkillToId(), clif_damage() 修正
+ skill.c - skill_castend_nodamage_id(), skill_castend_pos2(), skill_use_id() 修正
+ pc.c - pc_setnewpc(), pc_authok() 修正
+ status.c - status_get_dmotion() 修正
+ battle.c - battle_calc_damage() 修正
+
+--------------------
+//1146 by eigen
+
+・インデュア使用時Lvに応じてMDEFが上がるように変更
+・インデュア使用中7回ダメージを受けると解除するよう変更
+・石投げの固定ダメージを50に変更
+
+ (src/map)
+ battle.c - battle_calc_damage(), battle_calc_misc_attack() 修正
+ status.c - status_calc_pc(), status_change_start(), status_change_end() 修正
+
+--------------------
+//1145 by End_of_exam
+
+・start のチェック間隔が短すぎたのを修正(start)
+・skill_unit_effect() から無限ループに突入して、スタックオーバーフローで落ちる
+ 可能性があるバグを修正(skill.c)
+・ペットの読み込みに失敗した時に落ちるバグを修正(pet.c)
+・2重ログインの切断処理が違っていたバグを修正(map.c)
+
+・1142のマグヌスエクソシズムの修正を元に戻す(skill.c)
+・メディタティオのSP回復量修正の取り込み(skill.c thanks to ななしさん)
+
+ (/)
+ start - チェック間隔を修正
+
+ (src/map)
+ map.c - map_quit() 修正
+ pet.c - pet_recv_petdata() 修正
+ skill.c - skill_unit_onplace_timer() , skill_unit_effect() 修正
+ status.c - status_calc_pc() 修正
+
+--------------------
+//1144 by 聖
+
+・VCでコンパイルしたとき警告が出るのを修正。
+・簡易アイテム・モンスター召還コマンド@imを追加。
+・@im追加に伴いAEGISで使われている/item,/monsterを実装。
+ (AEGISの仕様に則り装備は1個単位・未鑑定で
+ ほかのアイテムは30個単位・鑑定済みで出ます。)
+・@monsterを召還匹数入力なしで召還できるようにした。
+・コマンド入力の際とある条件を満たすと
+ バッファオーバーフローが発生するバグを修正。
+ (src/map)
+ atcommand.h 修正。
+ atcommand.c
+ atcommand_monster() 修正。
+ atcommand_itemmonster() 追加。
+ clif.c
+ clif_parse_GMkillall() 修正。
+ clif_parse_GMsummon() 修正。
+ clif_parse_GMitemmonster() 追加。
+ status.c
+ status_change_start() 修正。
+ (db)
+ packet_db.txt 修正。
+ (conf)
+ msg_athena.conf 修正。
+ atcommand_athena.conf 修正。
+
+--------------------
+//1143 by End_of_exam
+
+・map_quit(), pc_setpos() を色々整理(map.c pc.c)
+・モンスターがバシリカを使うと落ちるバグを修正(skill.c)
+・ボスモンスターにロキの叫びが効いていたのを修正(mob.c)
+・ダンス途中にサーバー内の別のマップに移動した場合、スキルユニットが消えない
+ (転送前のマップに残っている)バグを修正。(pc.c)
+・1134でサーバー間のワープポータルを使った時に、スキル使用者が乗ったらサーバーが
+ 落ちるバグを修正(skill.c)
+・1134でハエの羽を使ってサーバー間を移動した場合、アイテムが減らないバグを修正(pc.c)
+
+ (src/map)
+ map.c - map_quit() 修正
+ mob.c - mobskill_castend_id() , mobskill_castend_pos(),
+ mobskill_use_id(), mobskill_use_pos() 修正
+ pc.c - pc_useitem(), pc_setpos() 修正、pc_remove_map() 追加
+ pc.h - pc_remove_map() 追加
+ skill.c - skill_castend_nodamege_id(), skill_unit_onplace() 修正
+
+--------------------
+//1142 by づん
+・マグヌスエクソシズムで種族にアンデットを持つモンスターに当たらなかったのを修正
+ (src/map)
+ skill.c - && race!=1を追加
+
+--------------------
+//1141.1 by BDPQ銀 [ 2005/02/21 ]
+・1141の添付忘れの追加です。申し訳ありませんでした。
+・GMコマンドを行った時のメッセージを追加しました。
+
+ (conf)
+ msg_athena.conf - 113〜117 追加 (@reload〜 を行った時のメッセージを追加)
+
+--------------------
+//1141 by BDPQ銀 [ 2005/02/20 ]
+・GMコマンドを追加
+ @reloadatcommand - atcommand_athena.conf を再読込する
+ @reloadbattleconf - battle_athena.conf を再読込する
+ @reloadgmaccount - gm_account_filename (デフォルト GM_account.txt ) を再読込する
+ @reloadstatusdb - job_db1.txt / job_db2.txt / job_db2-2.txt / refine_db.txt / size_fix.txt を再読込する
+ @reloadpcdb - exp.txt / skill_tree.txt / attr_fix.txt を再読込する
+・GMコマンド「@reloadmobdb」でペットのデータベースも再読込するように変更
+ * @reload〜 にはクライアントのリログが必要な場合も有ります。
+・GMコマンド「@who+」でレベルも表示するように変更
+・ヒールを何レベル以上で9999固定にするかのオプション(heal_counterstop)追加
+
+ (conf)
+ atcommand_athena.conf - reloadatcommand reloadbattleconf reloadgmaccount reloadstatusdb reloadpcdb 追加 (デフォルト99)
+ battle_athena.conf - heal_counterstop 追加 (デフォルト11)
+ help.txt - reloadatcommand reloadbattleconf reloadgmaccount reloadstatusdb reloadpcdb who+ の説明を追加
+
+ (doc)
+ conf_ref.txt - 5. conf/battle_athena.conf 編集 (heal_counterstop の説明とサンプルを追加)
+ - 6. atcommand_athena.conf 編集 (説明とサンプルに再読込関連を追加)
+
+ (src/map)
+ atcommand.c - AtCommandInfo atcommand_info 編集 (構造体定義)
+ - atcommand_whop() 編集 (プレイヤーのレベルも表示するよう変更)
+ - atcommand_reloadatcommand() 追加 (atcommand_athena.conf 再読込)
+ - atcommand_reloadbattleconf() 追加 (battle_athena.conf 再読込)
+ - atcommand_reloadgmaccount() 追加 (gm_account_filename 再読込)
+ - atcommand_reloadstatusdb() 追加 (ステータス関連DB 再読込)
+ - atcommand_reloadpcdb() 追加 (プレイヤー関連DB 再読込)
+ - atcommand_reloadmobdb() 編集 (ペットのデータベースも読込むよう変更)
+ atcommand.h - AtCommandType 編集 (構造体定義)
+
+ battle.c - battle_config_read() 編集 (heal_counterstop の追加)
+ battle.h - Battle_Config 編集 (heal_counterstop の追加)
+
+ skill.c - skill_castend_nodamage_id() 編集 (9999ヒール部を battle_athena.conf を参照するよう変更)
+
+ pet.h - int read_petdb(); 追加 (ペット関連DB 再読込用)
+
+ pc.h - int pc_readdb(void); 追加 (プレイヤー関連DB 再読込用)
+
+ status.h - int status_readdb(void); 追加 (ステータス関連DB 再読込用)
+
+--------------------
+//1140 by eigen
+・一部の環境でathena-startとstartが正常に動作していなかったバグを修正
+
+ athena-start - 改行コードを0Aに統一
+ start - 改行コードを0Aに統一
+
+--------------------
+//1139 by もっさり
+・NPC取り巻き呼び戻しスキル実装
+・コメントされてる9999ヒール(skilllv>10の時)、広範囲メテオ(skilllv>10の時)、広範囲ハンマーフォール(skilllv>5の時)のコメント取り外し。
+・広範囲lovの付け加え(skilllv>10の時)
+例
+1312,取り巻き呼び戻し@タートルジェネラル,attack,354,1,3000,0,0,no,self,always,0,,,,,,10
+1063,9999ヒール@ルナティック,idle,28,11,10,2000,60000,yes,self,always,0,,,,,, 
+
+ (src/map)
+ skill.c npc_recallスキル追加,上記のコメント取り外し
+ skill.h NPC_RECALL = 354を追加
+ mob.c スキル追加のために「取り巻きモンスターの処理」部分に付け加え
+ mob.h int mob_countslave(struct mob_data *md);を追加
+ map.h struct mob_dataにrecall_flagとrecallmob_countメンバー追加
+ (db)
+ skill_db.txt スキル追加
+
+--------------------
+//1138 by End_of_exam
+
+・1132のsocket.cに紛れ込んでいたかなり深刻なバグ(送信データがランダムに
+ 書き換わる可能性があるバグ)を修正(socket.c)
+・1134で組み込んだアイテムdupe対策が不完全だったのを修正(pc.c party.c guild.c)
+
+ (src/common/)
+ socket.c - send_from_fifo() 修正
+
+ (src/map)
+ pc.c - pc_setpos() 修正
+ party.c - 色々修正
+ guild.c - 色々修正
+
+--------------------
+//1137 by いど
+
+・サーバースナップショット
+
+--------------------
//1136 by by eigen
・1135で消えていたbattle_athena.confの項目とデフォルト値を復活
diff --git a/conf-tmpl/atcommand_athena.conf b/conf-tmpl/atcommand_athena.conf
index 4bb17dbca..2d114a82c 100644
--- a/conf-tmpl/atcommand_athena.conf
+++ b/conf-tmpl/atcommand_athena.conf
@@ -618,6 +618,18 @@ setbattleflag: 99
// Refresh only status of players - SQL Only
refreshonline: 99
+// Re-load gm command config (admin command)
+reloadatcommand: 99
+
+// Re-load battle config (admin command)
+reloadbattleconf: 99
+
+// Re-load status database (admin command)
+reloadstatusdb: 99
+
+// Re-load player info database (admin command)
+reloadpcdb: 99
+
// [Un]Disguise All Players
disguiseall: 99
undisguiseall: 99
diff --git a/conf-tmpl/msg_athena.conf b/conf-tmpl/msg_athena.conf
index afb482043..c1121780b 100644
--- a/conf-tmpl/msg_athena.conf
+++ b/conf-tmpl/msg_athena.conf
@@ -265,6 +265,10 @@
251: You have already opened your guild storage. Close it first.
252: You are not in a guild.
253: You are not authorised to memo this map.
+254: GM commands configuration reloaded.
+255: Battle configuration reloaded.
+256: Status database reloaded.
+257: Player database reloaded.
// Messages of others (not for GM commands)
// ----------------------------------------
diff --git a/db/packet_db.txt b/db/packet_db.txt
index 95591eacf..81bcf2c89 100644
--- a/db/packet_db.txt
+++ b/db/packet_db.txt
@@ -237,7 +237,7 @@ prefer_packet_db: yes
0x013c,4
0x013d,6
0x013e,24
-0x013f,26
+0x013F,26,itemmonster,2
0x0140,22,mapmove,2:18:20
0x0141,14
0x0142,6
diff --git a/db/skill_cast_db.txt b/db/skill_cast_db.txt
index 247c77a25..d1b62cf0c 100644
--- a/db/skill_cast_db.txt
+++ b/db/skill_cast_db.txt
@@ -2,7 +2,7 @@
//id,cast_list,delay_list,upkeep_time,upkeep_time2
6,0,0,30000,0 //SM_PROVOKE#プロボック#
-
+7,0,2000,0,0 //SM_MAGNUM#マグナムブレイク#
8,0,0,10000:13000:16000:19000:22000:25000:28000:31000:34000:37000,0 //SM_ENDURE#インデュア#
10,0,0,10000,0 //MG_SIGHT#サイト#
@@ -156,7 +156,7 @@
252,0,0,300000,0 //CR_REFLECTSHIELD#リフレクトシールド#
253,0,0,0,10000:11000:12000:13000:14000:15000:16000:17000:18000:19000 //CR_HOLYCROSS#ホーリークロス#
254,3000,1500,1000,10000:11000:12000:13000:14000:15000:16000:17000:18000:19000 //CR_GRANDCROSS#グランドクロス#
-
+255,3000,0,0,0 //CR_DEVOTION#ディボーション
256,3000,0,180000,0 //CR_PROVIDENCE#プロヴィデンス#
257,0,800,180000,0 //CR_DEFENDER#ディフェンダー#
258,0,0,30000:60000:90000:120000:150000:180000:210000:240000:270000:300000,0 //CR_SPEARQUICKEN#スピアクイッケン#
@@ -232,7 +232,7 @@
365,300,300,0,0 //HW_MAGICCRASHER
366,700,0,30000,0 //HW_MAGICPOWER#魔法力増幅#
367,2000:2500:3000:3500:4000,2000:3000:4000:5000:6000,0,2000:3000:4000:5000:6000 //PA_PRESSURE
-369,0,0,100000,0 //PA_GOSPEL#ゴスペル#
+369,0,0,60000,20000 //PA_GOSPEL#ゴスペル#
370,0,300,0,0 //CH_PALMSTRIKE
371,0,0,0,2000:4000:6000:8000:10000 //CH_TIGERFIST#伏虎拳#
372,0,800:800:800:800:800:1000:1000:1000:1000:1000,0,0 //CH_CHAINCRUSH#連柱崩撃#
diff --git a/db/skill_db.txt b/db/skill_db.txt
index ac6acb17f..a1ed5b27f 100644
--- a/db/skill_db.txt
+++ b/db/skill_db.txt
@@ -6,7 +6,7 @@
4,0,0,0,0,0,10,0,no,0,0,0,none,0 //SM_RECOVERY#HP回復力向上#
5,-1,6,1,0,0,10,1,no,0,0,0,weapon,0 //SM_BASH#バッシュ#
6,8,6,1,0,1,10,1,no,0,0,0,none,0 //SM_PROVOKE#プロ?ック#
-7,0,6,4,3,2,10,5,no,0,0,0,weapon,2 //SM_MAGNUM#?グナ?ブレイク#
+7,0,6,4,3,2,10,5,no,0,16,0,weapon,2 //SM_MAGNUM#?グナ?ブレイク#
8,0,6,4,0,1,10,1,no,0,0,0,weapon,0 //SM_ENDURE#インデュア#
9,0,0,0,0,0,10,0,no,0,0,0,none,0 //MG_SRECOVERY#SP回復力向上#
10,8,6,4,3,1,1,1,yes,0,0,0,magic,0 //MG_SIGHT#サイト#
@@ -264,10 +264,10 @@
212,-1,6,1,0,0,10,1,no,0,0,0,weapon,1 //RG_BACKSTAP#バックス?ブ#
213,0,0,0,0,0,5,0,no,0,0,0,none,0 //RG_TUNNELDRIVE#トンネルドライブ#
214,0,6,4,0,1,5,1,no,0,0,0,weapon,0 //RG_RAID#サプライズア?ック#
-215,1,6,1,0,1,5,1,yes,0,0,0,weapon,0 //RG_STRIPWEAPON#ストリップウェ?ン#
-216,1,6,1,0,1,5,1,yes,0,0,0,weapon,0 //RG_STRIPSHIELD#ストリップシ?ルド#
-217,1,6,1,0,1,5,1,yes,0,0,0,weapon,0 //RG_STRIPARMOR#ストリップア???#
-218,1,6,1,0,1,5,1,yes,0,0,0,weapon,0 //RG_STRIPHELM#ストリップヘル?#
+215,1,6,1,0,1,5,1,no,0,0,0,weapon,0 //RG_STRIPWEAPON#ストリップウェ?ン#
+216,1,6,1,0,1,5,1,no,0,0,0,weapon,0 //RG_STRIPSHIELD#ストリップシ?ルド#
+217,1,6,1,0,1,5,1,no,0,0,0,weapon,0 //RG_STRIPARMOR#ストリップア???#
+218,1,6,1,0,1,5,1,no,0,0,0,weapon,0 //RG_STRIPHELM#ストリップヘル?#
219,-1,6,1,0,0,5,1,no,0,0,0,weapon,0 //RG_INTIMIDATE#インティ?デイト#
220,1,6,2,0,1,1,1,no,0,0,0,none,0 //RG_GRAFFITI#グラフィティ#
221,0,6,2,0,1,5,1,no,0,0,0,none,0 //RG_FLAGGRAFFITI#フラッググラフィティ#
@@ -278,8 +278,8 @@
226,0,0,0,0,0,10,0,no,0,0,0,weapon,0 //AM_AXEMASTERY#?修練#
227,0,0,0,0,0,10,0,no,0,0,0,none,0 //AM_LEARNINGPOTION#ラ?ニング??ション#
228,0,6,4,0,1,10,0,no,0,0,0,none,0 //AM_PHARMACY#フ???シ?#
-229,8,6,2,3,1,5,1,no,0,128,0,weapon,0 //AM_DEMONSTRATION#デモンストレ?ション#
-230,8,6,1,0,0,5,0,no,0,0,0,weapon,0 //AM_ACIDTERROR#アシッドテラ?#
+229,8,6,2,3,1,5,1,yes,0,128,0,weapon,0 //AM_DEMONSTRATION#デモンストレ?ション#
+230,8,6,1,0,0,5,0,yes,0,0,0,weapon,0 //AM_ACIDTERROR#アシッドテラ?#
231,8,6,16,0,1,5,1,yes,0,3072,0,none,0 //AM_POTIONPITCHER#??ションピッ?ャ?#
232,3,6,2,0,1,5,1,no,0,0,5,none,0 //AM_CANNIBALIZE#バイオプラント#
233,3,6,2,0,1,5,1,no,0,128,3,none,0 //AM_SPHEREMINE#スフィア??イン#
@@ -303,7 +303,7 @@
251,3:5:7:9:11,6,1,0,0,5,1,no,0,0,0,weapon,0 //CR_SHIELDBOOMERANG#シ?ルドブ?メラン#
252,0,6,4,0,1,10,1,no,0,0,0,weapon,0 //CR_REFLECTSHIELD#リフレクトシ?ルド#
253,-2,8,1,6,0,10,2,no,0,0,0,weapon,0 //CR_HOLYCROSS#ホ?リ?クロス#
-254,0,6,4,6,0,10,1,no,33,256,0,magic,0 //CR_GRANDCROSS#グランドクロス#
+254,0,5,4,6,0,10,1,no,33,256,0,magic,0 //CR_GRANDCROSS#グランドクロス#
255,8,6,16,0,1,5,1,yes,0,0,0,magic,0 //CR_DEVOTION#ディ??ション#
256,8,6,16,0,1,5,1,yes,0,0,0,magic,0 //CR_PROVIDENCE#プロヴィデンス#
257,0,6,4,0,1,5,1,no,0,0,0,weapon,0 //CR_DEFENDER#ディフェン??#
@@ -404,13 +404,13 @@
//345兜壊し
//346盾壊し
//347不死属性攻撃
-//348攻撃系エフェクト(後退?)
+348,2,6,4,0,1,20,0,no,0,0,0,magic,0 //NPC_RUNAWAY#後退#
349,0,6,4,0,1,5,0,no,0,0,0,weapon,0 //NPC_EXPLOSIONSPIRITS#NPC爆裂波動#
//350速度増加エフェクト
//351攻撃系スキルエフェクト
//352攻撃系スキルエフェクト
//353攻撃系スキルエフェクト
-//354攻撃系スキルエフェクト
+354,2,0,4,0,1,1,0,no,0,0,0,magic,0 //NPC_RECALL#取り巻き呼び戻し#
355,0,6,4,0,1,5,1,no,0,0,0,weapon,0 //LK_AURABLADE#オ?ラブレ?ド#
356,0,6,4,0,1,10,1,no,0,0,0,weapon,0 //LK_PARRYING#パリイング#
@@ -436,7 +436,7 @@
376,0,0,0,0,1,5,1,no,0,0,0,weapon,0 //ASC_KATAR#アドバンスドカ??ル研究#
377,0,0,4,0,1,10,1,no,0,0,0,misc,0 //ASC_HALLUCINATION#ハルシネ?ションウォ?ク#
378,0,6,4,5,1,5,1,no,0,1024,0,weapon,0 //ASC_EDP#エン?ャントデッドリ??イズン#
-379,5,6,1,0,0,10,1,no,0,0,0,weapon,0 //ASC_BREAKER#?ウルブレ?カ?#
+379,9,6,1,0,0,10,1,yes,0,0,0,weapon,0 //ASC_BREAKER#?ウルブレ?カ?#
380,0,6,4,0,1,10,1,no,0,0,0,weapon,0 //SN_SIGHT#トゥル?サイト#
381,9,8,1,0,0,5,1:2:3:4:5,yes,0,0,0,misc,0 //SN_FALCONASSAULT#フ?ルコンアサルト#
382,14,8,1,0,0,5,1,no,0,0,0,weapon,0 //SN_SHARPSHOOTING#シャ?プシュ?ティング#
@@ -454,7 +454,7 @@
394,8,8,1,0,0,10,9,no,0,0,0,weapon,0 //CG_ARROWVULCAN#アロ?バルカン#
395,0,0,4,0,1,1,1,yes,0,0,0,magic,0 //CG_MOONLIT#月明りの泉に落ちる花びら#
396,0,6,16,0,1,1,1,yes,0,0,0,magic,1 //CG_MARIONETTE#?リオネットコントロ?ル#
-397,4,8,1,0,0,5,5,no,0,0,0,weapon,0 //LK_SPIRALPIERCE#スパイラルピア?ス#
+397,5,8,1,0,0,5,5,no,0,0,0,weapon,0 //LK_SPIRALPIERCE#スパイラルピア?ス#
398,4,6,1,0,0,5,1,no,0,0,0,weapon,0 //LK_HEADCRUSH#ヘッドクラッシュ#
399,4,6,1,0,0,10,1,no,0,0,0,weapon,0 //LK_JOINTBEAT#ジョイントビ?ト#
400,8,8,1,8,0,5,1:2:3:4:5,yes,0,0,0,magic,0 //HW_NAPALMVULCAN#ナパ??バルカン#
diff --git a/db/skill_require_db.txt b/db/skill_require_db.txt
index 50578ac49..2cccdfe72 100644
--- a/db/skill_require_db.txt
+++ b/db/skill_require_db.txt
@@ -3,7 +3,7 @@
5,0,0,8:8:8:8:8:15:15:15:15:15,0,0,0,0:1:2:3:4:5:6:7:8:9:10:12:13:14:15:16:17:18:19:20:21:22,none,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0 //SM_BASH#バッシュ#
6,0,0,4:5:6:7:8:9:10:11:12:13,0,0,0,99,none,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0 //SM_PROVOKE#プロボック#
-7,15,0,15,0,0,0,0:1:2:3:4:5:6:7:8:9:10:12:13:14:15:16:17:18:19:20:21:22,none,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0 //SM_MAGNUM#マグナムブレイク#
+7,20:20:19:19:18:18:17:17:16:16,0,30,0,0,0,99,none,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0 //SM_MAGNUM#マグナムブレイク#
8,0,0,10,0,0,0,99,none,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0 //SM_ENDURE#インデュア#
10,0,0,10,0,0,0,99,none,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0 //MG_SIGHT#サイト#
diff --git a/db/skill_unit_db.txt b/db/skill_unit_db.txt
index e9e7dffaf..800548745 100644
--- a/db/skill_unit_db.txt
+++ b/db/skill_unit_db.txt
@@ -75,6 +75,6 @@
336,0xb2, , 0,-1, -1,all, 0x000,0 //WE_CALLPARTNER#あなたに逢いたい
339,0x86, , -1, 0, 300,enemy, 0x000,0 //NPC_DARKGRANDCROSS#闇グランドクロス
362,0xb4, , 0, 3, 300,all, 0x000,0 //HP_BASILICA#バジリカ
-369,0xb3, , 3, 0, -1,all, 0x000,0 //PA_GOSPEL#ゴスペル
+369,0xb3, , -1, 0,10000,all, 0x000,0 //PA_GOSPEL#ゴスペル
404,0xb6, , -1, 0, -1,all, 0x000,0 //PF_FOGWALL#フォグウォール
405,0xb7, , 0, 1,1000,enemy, 0x006,0 //PF_SPIDERWEB#スパイダーウェッブ
diff --git a/src/map/atcommand.c b/src/map/atcommand.c
index b236b211c..a420147bc 100644
--- a/src/map/atcommand.c
+++ b/src/map/atcommand.c
@@ -10,6 +10,7 @@
#include "../common/nullpo.h"
#include "../common/mmo.h"
#include "../common/db.h"
+#include "../common/core.h"
#include "log.h"
#include "clif.h"
@@ -29,7 +30,6 @@
#include "script.h"
#include "npc.h"
#include "trade.h"
-#include "core.h"
#ifndef TXT_ONLY
#include "mail.h"
@@ -142,6 +142,10 @@ ACMD_FUNC(reloadmobdb);
ACMD_FUNC(reloadskilldb);
ACMD_FUNC(reloadscript);
ACMD_FUNC(reloadgmdb); // by Yor
+ACMD_FUNC(reloadatcommand);
+ACMD_FUNC(reloadbattleconf);
+ACMD_FUNC(reloadstatusdb);
+ACMD_FUNC(reloadpcdb);
ACMD_FUNC(mapexit);
ACMD_FUNC(idsearch);
ACMD_FUNC(mapinfo);
@@ -389,6 +393,10 @@ static AtCommandInfo atcommand_info[] = {
{ AtCommand_ReloadSkillDB, "@reloadskilldb", 99, atcommand_reloadskilldb }, // admin command
{ AtCommand_ReloadScript, "@reloadscript", 99, atcommand_reloadscript }, // admin command
{ AtCommand_ReloadGMDB, "@reloadgmdb", 99, atcommand_reloadgmdb }, // admin command
+ { AtCommand_ReloadAtcommand, "@reloadatcommand", 99, atcommand_reloadatcommand },
+ { AtCommand_ReloadBattleConf, "@reloadbattleconf",99, atcommand_reloadbattleconf },
+ { AtCommand_ReloadStatusDB, "@reloadstatusdb", 99, atcommand_reloadstatusdb },
+ { AtCommand_ReloadPcDB, "@reloadpcdb", 99, atcommand_reloadpcdb },
{ AtCommand_CharModel, "@charmodel", 50, atcommand_charmodel },
{ AtCommand_CharSKPoint, "@charskpoint", 60, atcommand_charskpoint },
{ AtCommand_CharSTPoint, "@charstpoint", 60, atcommand_charstpoint },
@@ -5622,6 +5630,7 @@ int atcommand_reloadmobdb(
{
nullpo_retr(-1, sd);
mob_reload();
+ read_petdb();
clif_displaymessage(fd, msg_table[98]); // Monster database reloaded.
return 0;
@@ -5643,6 +5652,66 @@ int atcommand_reloadskilldb(
}
/*==========================================
+ * @reloadatcommand
+ * atcommand_athena.conf のリロード
+ *------------------------------------------
+ */
+int
+atcommand_reloadatcommand(
+ const int fd, struct map_session_data* sd,
+ const char* command, const char* message)
+{
+ atcommand_config_read(ATCOMMAND_CONF_FILENAME);
+ clif_displaymessage(fd, msg_table[254]);
+ return 0;
+}
+/*==========================================
+ * @reloadbattleconf
+ * battle_athena.conf のリロード
+ *------------------------------------------
+ */
+int
+atcommand_reloadbattleconf(
+ const int fd, struct map_session_data* sd,
+ const char* command, const char* message)
+{
+ battle_config_read(BATTLE_CONF_FILENAME);
+ clif_displaymessage(fd, msg_table[255]);
+ return 0;
+}
+/*==========================================
+ * @reloadstatusdb
+ * job_db1.txt job_db2.txt job_db2-2.txt
+ * refine_db.txt size_fix.txt
+ * のリロード
+ *------------------------------------------
+ */
+int
+atcommand_reloadstatusdb(
+ const int fd, struct map_session_data* sd,
+ const char* command, const char* message)
+{
+ status_readdb();
+ clif_displaymessage(fd, msg_table[256]);
+ return 0;
+}
+/*==========================================
+ * @reloadpcdb
+ * exp.txt skill_tree.txt attr_fix.txt
+ * のリロード
+ *------------------------------------------
+ */
+int
+atcommand_reloadpcdb(
+ const int fd, struct map_session_data* sd,
+ const char* command, const char* message)
+{
+ pc_readdb();
+ clif_displaymessage(fd, msg_table[257]);
+ return 0;
+}
+
+/*==========================================
*
*------------------------------------------
*/
diff --git a/src/map/atcommand.h b/src/map/atcommand.h
index 6dcd6cc59..a9678d6a3 100644
--- a/src/map/atcommand.h
+++ b/src/map/atcommand.h
@@ -122,6 +122,10 @@ enum AtCommandType {
AtCommand_ReloadSkillDB,
AtCommand_ReloadScript,
AtCommand_ReloadGMDB,
+ AtCommand_ReloadAtcommand,
+ AtCommand_ReloadBattleConf,
+ AtCommand_ReloadStatusDB,
+ AtCommand_ReloadPcDB,
AtCommand_MapInfo,
AtCommand_Dye,
AtCommand_Hstyle,
diff --git a/src/map/battle.c b/src/map/battle.c
index 78d8215ab..aa30ef0a9 100644
--- a/src/map/battle.c
+++ b/src/map/battle.c
@@ -928,6 +928,7 @@ static struct Damage battle_calc_pet_weapon_attack(
break;
case AS_SPLASHER: /* ベナムスプラッシャー */
damage = damage*(200+20*skill_lv)/100;
+ hitrate = 1000000;
break;
}
if (div_flag && div_ > 1) { // [Skotlex]
@@ -1432,6 +1433,7 @@ static struct Damage battle_calc_mob_weapon_attack(
break;
case AS_SPLASHER: /* ベナムスプラッシャー */
damage = damage*(200+20*skill_lv)/100;
+ hitrate = 1000000;
break;
}
if (div_flag && div_ > 1) { // [Skotlex]
@@ -2291,6 +2293,8 @@ static struct Damage battle_calc_pc_weapon_attack(
case AS_SPLASHER: /* ベナムスプラッシャー */
damage = damage*(200+20*skill_lv+20*pc_checkskill(sd,AS_POISONREACT))/100;
damage2 = damage2*(200+20*skill_lv+20*pc_checkskill(sd,AS_POISONREACT))/100;
+ no_cardfix = 1;
+ hitrate = 1000000;
break;
case ASC_BREAKER: // -- moonsoul (special damage for ASC_BREAKER skill)
if(sd){
diff --git a/src/map/clif.c b/src/map/clif.c
index 7ebf11b8a..20db97554 100644
--- a/src/map/clif.c
+++ b/src/map/clif.c
@@ -3706,7 +3706,8 @@ int clif_damage(struct block_list *src,struct block_list *dst,unsigned int tick,
if(type != 4 && dst->type == BL_PC && ((struct map_session_data *)dst)->special_state.infinite_endure)
type = 9;
if(sc_data) {
- if(type != 4 && sc_data[SC_ENDURE].timer != -1)
+ if(type != 4 && sc_data[SC_ENDURE].timer != -1 &&
+ (dst->type == BL_PC && !map[dst->m].flag.gvg))
type = 9;
if(sc_data[SC_HALLUCINATION].timer != -1) {
if(damage > 0)
@@ -9794,31 +9795,6 @@ void clif_parse_OpenVending(int fd,struct map_session_data *sd) {
}
/*==========================================
- * /monster /item rewriten by [Yor]
- *------------------------------------------
- */
-void clif_parse_GM_Monster_Item(int fd, struct map_session_data *sd) {
- char monster_item_name[25];
-
- nullpo_retv(sd);
-
- memset(monster_item_name, '\0', sizeof(monster_item_name));
-
- if (battle_config.atc_gmonly == 0 || pc_isGM(sd)) {
- memcpy(monster_item_name, RFIFOP(fd,2), 24);
-
- if (mobdb_searchname(monster_item_name) != 0) {
- if (pc_isGM(sd) >= get_atcommand_level(AtCommand_Monster))
- atcommand_spawn(fd, sd, "@spawn", monster_item_name); // as @spawn
- } else if (itemdb_searchname(monster_item_name) != NULL) {
- if (pc_isGM(sd) >= get_atcommand_level(AtCommand_Item))
- atcommand_item(fd, sd, "@item", monster_item_name); // as @item
- }
-
- }
-}
-
-/*==========================================
* ギルドを作る
*------------------------------------------
*/
@@ -10099,6 +10075,31 @@ void clif_parse_Recall(int fd, struct map_session_data *sd) { // Added by RoVeRT
return;
}
+/*==========================================
+ * /monster /item rewriten by [Yor]
+ *------------------------------------------
+ */
+void clif_parse_GM_Monster_Item(int fd, struct map_session_data *sd) {
+ char monster_item_name[25];
+
+ nullpo_retv(sd);
+
+ memset(monster_item_name, '\0', sizeof(monster_item_name));
+
+ if (battle_config.atc_gmonly == 0 || pc_isGM(sd)) {
+ memcpy(monster_item_name, RFIFOP(fd,2), 24);
+
+ if (mobdb_searchname(monster_item_name) != 0) {
+ if (pc_isGM(sd) >= get_atcommand_level(AtCommand_Monster))
+ atcommand_spawn(fd, sd, "@spawn", monster_item_name); // as @spawn
+ } else if (itemdb_searchname(monster_item_name) != NULL) {
+ if (pc_isGM(sd) >= get_atcommand_level(AtCommand_Item))
+ atcommand_item(fd, sd, "@item", monster_item_name); // as @item
+ }
+
+ }
+}
+
void clif_parse_GMHide(int fd, struct map_session_data *sd) { // Modified by [Yor]
nullpo_retv(sd);
@@ -10989,7 +10990,8 @@ static int packetdb_readdb(void)
{clif_parse_friends_list_add,"friendslistadd"},
{clif_parse_friends_list_remove,"friendslistremove"},
{clif_parse_GMkillall,"killall"},
- {clif_parse_GM_Monster_Item,"summon"},
+ {clif_parse_Recall,"summon"},
+ {clif_parse_GM_Monster_Item,"itemmonster"},
{clif_parse_Shift,"shift"},
{clif_parse_debug,"debug"},
diff --git a/src/map/guild.c b/src/map/guild.c
index c65c3963c..935377e19 100644
--- a/src/map/guild.c
+++ b/src/map/guild.c
@@ -386,7 +386,7 @@ int guild_check_member(const struct guild *g)
nullpo_retr(0, g);
for(i=0;i<fd_max;i++){
- if(session[i] && (sd=(struct map_session_data *) session[i]->session_data) && sd->state.auth){
+ if(session[i] && (sd=(struct map_session_data *) session[i]->session_data) && sd->state.auth && !sd->state.waitingdisconnect){
if(sd->status.guild_id==g->guild_id){
int j,f=1;
for(j=0;j<MAX_GUILD;j++){ // データがあるか
@@ -412,7 +412,7 @@ int guild_recv_noinfo(int guild_id)
int i;
struct map_session_data *sd;
for(i=0;i<fd_max;i++){
- if(session[i] && (sd=(struct map_session_data *) session[i]->session_data) && sd->state.auth){
+ if(session[i] && (sd=(struct map_session_data *) session[i]->session_data) && sd->state.auth && !sd->state.waitingdisconnect){
if(sd->status.guild_id==guild_id)
sd->status.guild_id=0;
}
@@ -442,9 +442,11 @@ int guild_recv_info(struct guild *sg)
for(i=bm=m=0;i<g->max_member;i++){ // sdの設定と人数の確認
if(g->member[i].account_id>0){
struct map_session_data *sd = map_id2sd(g->member[i].account_id);
- g->member[i].sd=(sd!=NULL &&
- sd->status.char_id==g->member[i].char_id &&
- sd->status.guild_id==g->guild_id)? sd:NULL;
+ if (sd && sd->status.char_id == g->member[i].char_id &&
+ sd->status.guild_id == g->guild_id &&
+ !sd->state.waitingdisconnect)
+ g->member[i].sd = sd;
+ else sd = NULL;
m++;
}else
g->member[i].sd=NULL;
@@ -795,9 +797,11 @@ int guild_recv_memberinfoshort(int guild_id,int account_id,int char_id,int onlin
for(i=0;i<g->max_member;i++){ // sd再設定
struct map_session_data *sd= map_id2sd(g->member[i].account_id);
- g->member[i].sd=(sd!=NULL &&
- sd->status.char_id==g->member[i].char_id &&
- sd->status.guild_id==guild_id)?sd:NULL;
+ if (sd && sd->status.char_id == g->member[i].char_id &&
+ sd->status.guild_id == g->guild_id &&
+ !sd->state.waitingdisconnect)
+ g->member[i].sd = sd;
+ else sd = NULL;
}
// ここにクライアントに送信処理が必要
diff --git a/src/map/mail.c b/src/map/mail.c
index c7939cca1..46e80be9f 100644
--- a/src/map/mail.c
+++ b/src/map/mail.c
@@ -15,6 +15,7 @@
#include "clif.h"
#include "chrif.h"
#include "intif.h"
+#include "atcommand.h"
#include "pc.h"
#include "mail.h"
@@ -22,7 +23,7 @@ char mail_db[32] = "mail";
int MAIL_CHECK_TIME = 120000;
int mail_timer;
-extern char msg_table[1000][256]; // Server messages (0-499 reserved for GM commands, 500-999 reserved for others)
+//extern char *msg_table[1000]; // Server messages (0-499 reserved for GM commands, 500-999 reserved for others)
#ifdef MEMWATCH
#include "memwatch.h"
@@ -47,7 +48,7 @@ int mail_check(struct map_session_data *sd,int type)
if(mail_res) {
if (mysql_num_rows(mail_res) == 0) {
//clif_displaymessage(sd->fd,"You have no messages.");
- clif_displaymessage(sd->fd,msg_table[516]);
+ clif_displaymessage(sd->fd, msg_txt(516));
mysql_free_result(mail_res);
return 0;
@@ -69,18 +70,18 @@ int mail_check(struct map_session_data *sd,int type)
if(type==2 || type==3) {
if(atoi(mail_row[4])) {
//sprintf(message, "%d - From : %s (New - Priority)", i, mail_row[2]);
- sprintf(message, msg_table[511], i, mail_row[2]);
+ sprintf(message, msg_txt(511), i, mail_row[2]);
clif_displaymessage(sd->fd, jstrescape(message));
} else {
//sprintf(message, "%d - From : %s (New)", i, mail_row[2]);
- sprintf(message, msg_table[512], i, mail_row[2]);
+ sprintf(message, msg_txt(512), i, mail_row[2]);
clif_displaymessage(sd->fd, jstrescape(message));
}
}
} else if(type==2){
//sprintf(message, "%d - From : %s", i, mail_row[2]);
- sprintf(message, msg_table[513], i, mail_row[2]);
+ sprintf(message, msg_txt(513), i, mail_row[2]);
clif_displaymessage(sd->fd, jstrescape(message));
}
}
@@ -93,18 +94,18 @@ int mail_check(struct map_session_data *sd,int type)
if(i>0 && new_>0 && type==1) {
//sprintf(message, "You have %d new messages.", new_);
- sprintf(message, msg_table[514], new_);
+ sprintf(message, msg_txt(514), new_);
clif_displaymessage(sd->fd, jstrescape(message));
}
if(i>0 && new_>0 && priority>0 && type==1) {
//sprintf(message, "You have %d unread priority messages.", priority);
- sprintf(message, msg_table[515], priority);
+ sprintf(message, msg_txt(515), priority);
clif_displaymessage(sd->fd, jstrescape(message));
}
if(!new_) {
//clif_displaymessage(sd->fd, "You have no new messages.");
- clif_displaymessage(sd->fd, msg_table[516]);
+ clif_displaymessage(sd->fd, msg_txt(516));
}
return 0;
@@ -129,7 +130,7 @@ int mail_read(struct map_session_data *sd, int message_id)
if (mysql_num_rows(mail_res) == 0) {
mysql_free_result(mail_res);
//clif_displaymessage(sd->fd, "Message not found.");
- clif_displaymessage(sd->fd, msg_table[517]);
+ clif_displaymessage(sd->fd, msg_txt(517));
return 0;
}
@@ -142,7 +143,7 @@ int mail_read(struct map_session_data *sd, int message_id)
}
//sprintf(message, "Reading message from %s", mail_row[2]);
- sprintf(message, msg_table[518], mail_row[2]);
+ sprintf(message, msg_txt(518), mail_row[2]);
clif_displaymessage(sd->fd, jstrescape(message));
sprintf(message, "%s", mail_row[3]);
@@ -179,7 +180,7 @@ int mail_delete(struct map_session_data *sd, int message_id)
if (mysql_num_rows(mail_res) == 0) {
mysql_free_result(mail_res);
//clif_displaymessage(sd->fd, "Message not found.");
- clif_displaymessage(sd->fd, msg_table[517]);
+ clif_displaymessage(sd->fd, msg_txt(517));
return 0;
}
@@ -187,14 +188,14 @@ int mail_delete(struct map_session_data *sd, int message_id)
if(!atoi(mail_row[2]) && atoi(mail_row[3])) {
mysql_free_result(mail_res);
//clif_displaymessage(sd->fd,"Cannot delete unread priority mail.");
- clif_displaymessage(sd->fd,msg_table[519]);
+ clif_displaymessage(sd->fd,msg_txt(519));
return 0;
}
if(!atoi(mail_row[4])) {
mysql_free_result(mail_res);
//clif_displaymessage(sd->fd,"You have recieved new mail, use @listmail before deleting.");
- clif_displaymessage(sd->fd,msg_table[520]);
+ clif_displaymessage(sd->fd,msg_txt(520));
return 0;
}
sprintf(tmp_msql,"DELETE FROM `%s` WHERE `message_id` = \"%d\"", mail_db, atoi(mail_row[0]));
@@ -204,7 +205,7 @@ int mail_delete(struct map_session_data *sd, int message_id)
return 0;
}
//else clif_displaymessage(sd->fd,"Message deleted.");
- else clif_displaymessage(sd->fd,msg_table[521]);
+ else clif_displaymessage(sd->fd,msg_txt(521));
}
mysql_free_result(mail_res);
@@ -222,14 +223,14 @@ int mail_send(struct map_session_data *sd, char *name, char *message, int flag)
if(pc_isGM(sd) < 80 && sd->mail_counter > 0) {
//clif_displaymessage(sd->fd,"You must wait 10 minutes before sending another message");
- clif_displaymessage(sd->fd,msg_table[522]);
+ clif_displaymessage(sd->fd,msg_txt(522));
return 0;
}
if(strcmp(name,"*")==0) {
if(pc_isGM(sd) < 80) {
//clif_displaymessage(sd->fd, "Access Denied.");
- clif_displaymessage(sd->fd, msg_table[523]);
+ clif_displaymessage(sd->fd, msg_txt(523));
return 0;
}
else
@@ -248,7 +249,7 @@ int mail_send(struct map_session_data *sd, char *name, char *message, int flag)
if (mysql_num_rows(mail_res) == 0) {
mysql_free_result(mail_res);
//clif_displaymessage(sd->fd,"Character does not exist.");
- clif_displaymessage(sd->fd,msg_table[524]);
+ clif_displaymessage(sd->fd,msg_txt(524));
return 0;
}
@@ -273,7 +274,7 @@ int mail_send(struct map_session_data *sd, char *name, char *message, int flag)
}
//clif_displaymessage(sd->fd,"Mail has been sent.");
- clif_displaymessage(sd->fd,msg_table[525]);
+ clif_displaymessage(sd->fd,msg_txt(525));
return 0;
}
@@ -310,7 +311,7 @@ int mail_check_timer(int tid,unsigned int tick,int id,int data)
sd->mail_counter--;
if(sd->status.account_id==atoi(mail_row[0]))
//clif_displaymessage(sd->fd, "You have new mail.");
- clif_displaymessage(sd->fd, msg_table[526]);
+ clif_displaymessage(sd->fd, msg_txt(526));
}
}
}
diff --git a/src/map/map.c b/src/map/map.c
index 19edfd08b..f04d64a79 100644
--- a/src/map/map.c
+++ b/src/map/map.c
@@ -110,6 +110,16 @@ int check_online_timer=0; // [Valaris]
#endif /* not TXT_ONLY */
+char *INTER_CONF_NAME;
+char *LOG_CONF_NAME;
+char *MAP_CONF_NAME;
+char *BATTLE_CONF_FILENAME;
+char *ATCOMMAND_CONF_FILENAME;
+char *CHARCOMMAND_CONF_FILENAME;
+char *SCRIPT_CONF_NAME;
+char *MSG_CONF_NAME;
+char *GRF_PATH_FILENAME;
+
#define USE_AFM
#define USE_AF2
@@ -1460,60 +1470,20 @@ int map_quit(struct map_session_data *sd) {
}
}
- if(sd->chatID) // チャットから出る
- chat_leavechat(sd);
-
- if(sd->trade_partner) // 取引を中?する
- trade_tradecancel(sd);
-
- if(sd->party_invite>0) // パ?ティ?誘を拒否する
- party_reply_invite(sd,sd->party_invite_account,0);
-
- if(sd->guild_invite>0) // ギルド?誘を拒否する
- guild_reply_invite(sd,sd->guild_invite,0);
- if(sd->guild_alliance>0) // ギルド同盟?誘を拒否する
- guild_reply_reqalliance(sd,sd->guild_alliance_account,0);
+ if(sd->sc_data && sd->sc_data[SC_BERSERK].timer!=-1) //バ?サ?ク中の終了はHPを100に
+ sd->status.hp = 100;
party_send_logout(sd); // パ?ティのログアウトメッセ?ジ送信
-
guild_send_memberinfoshort(sd,0); // ギルドのログアウトメッセ?ジ送信
-
- pc_cleareventtimer(sd); // イベントタイマを破棄する
-
- if(sd->state.storage_flag)
- storage_guild_storage_quit(sd,0);
- else
- storage_storage_quit(sd); // 倉庫を開いてるなら保存する
-
- // check if we've been authenticated [celest]
- if (sd->state.auth)
- skill_castcancel(&sd->bl,0); // 詠唱を中?する
-
skill_stop_dancing(&sd->bl,1);// ダンス/演奏中?
-
- if(sd->sc_data && sd->sc_data[SC_BERSERK].timer!=-1) //バ?サ?ク中の終了はHPを100に
- sd->status.hp = 100;
-
status_change_clear(&sd->bl,1); // ステ?タス異常を解除する
- skill_clear_unitgroup(&sd->bl); // スキルユニットグル?プの削除
- skill_cleartimerskill(&sd->bl);
-
- // check if we've been authenticated [celest]
- if (sd->state.auth) {
- pc_stop_walking(sd,0);
- pc_stopattack(sd);
- pc_delinvincibletimer(sd);
- }
+ pc_cleareventtimer(sd);
pc_delspiritball(sd,sd->spiritball,1);
- skill_gangsterparadise(sd,0);
- skill_unit_move(&sd->bl,gettick(),0);
if (sd->state.auth)
status_calc_pc(sd,4);
// skill_clear_unitgroup(&sd->bl); // [Sara-chan]
- clif_clearchar_area(&sd->bl,2);
-
if(sd->status.pet_id && sd->pd) {
pet_lootitem_drop(sd->pd,sd);
pet_remove_map(sd);
@@ -1530,11 +1500,11 @@ int map_quit(struct map_session_data *sd) {
if(pc_isdead(sd))
pc_setrestartvalue(sd,2);
+ pc_remove_map(sd,2);
pc_makesavestatus(sd);
chrif_save(sd);
storage_storage_dirty(sd);
storage_storage_save(sd);
- map_delblock(&sd->bl);
}
if( sd->npc_stackbuf && sd->npc_stackbuf != NULL) {
@@ -3266,15 +3236,15 @@ int do_init(int argc, char *argv[]) {
GC_enable_incremental();
#endif
- char *INTER_CONF_NAME="conf/inter_athena.conf";
- char *LOG_CONF_NAME="conf/log_athena.conf";
- char *MAP_CONF_NAME = "conf/map_athena.conf";
- char *BATTLE_CONF_FILENAME = "conf/battle_athena.conf";
- char *ATCOMMAND_CONF_FILENAME = "conf/atcommand_athena.conf";
- char *CHARCOMMAND_CONF_FILENAME = "conf/charcommand_athena.conf";
- char *SCRIPT_CONF_NAME = "conf/script_athena.conf";
- char *MSG_CONF_NAME = "conf/msg_athena.conf";
- char *GRF_PATH_FILENAME = "conf/grf-files.txt";
+ INTER_CONF_NAME="conf/inter_athena.conf";
+ LOG_CONF_NAME="conf/log_athena.conf";
+ MAP_CONF_NAME = "conf/map_athena.conf";
+ BATTLE_CONF_FILENAME = "conf/battle_athena.conf";
+ ATCOMMAND_CONF_FILENAME = "conf/atcommand_athena.conf";
+ CHARCOMMAND_CONF_FILENAME = "conf/charcommand_athena.conf";
+ SCRIPT_CONF_NAME = "conf/script_athena.conf";
+ MSG_CONF_NAME = "conf/msg_athena.conf";
+ GRF_PATH_FILENAME = "conf/grf-files.txt";
chrif_connected = 0;
diff --git a/src/map/map.h b/src/map/map.h
index b25e6f05a..81d1b8cbc 100644
--- a/src/map/map.h
+++ b/src/map/map.h
@@ -220,6 +220,7 @@ struct map_session_data {
struct skill_unit_group_tickset skillunittick[MAX_SKILLUNITGROUPTICKSET];
struct skill_timerskill skilltimerskill[MAX_SKILLTIMERSKILL];
char blockskill[MAX_SKILL]; // [celest]
+ //unsigned int skillstatictimer[MAX_SKILL];
unsigned short timerskill_count; // [celest]
int cloneskill_id;
int potion_hp,potion_sp,potion_per_hp,potion_per_sp;
@@ -490,7 +491,9 @@ struct mob_data {
struct skill_unit_group_tickset skillunittick[MAX_SKILLUNITGROUPTICKSET];
char npc_event[50];
unsigned char size;
- int owner;
+ short recall_flag;
+ int recallmob_count;
+ short recallcount;
};
struct pet_data {
struct block_list bl;
@@ -800,6 +803,16 @@ int cleanup_sub(struct block_list *bl, va_list ap);
void map_helpscreen(); // [Valaris]
int map_delmap(char *mapname);
+extern char *INTER_CONF_NAME;
+extern char *LOG_CONF_NAME;
+extern char *MAP_CONF_NAME;
+extern char *BATTLE_CONF_FILENAME;
+extern char *ATCOMMAND_CONF_FILENAME;
+extern char *CHARCOMMAND_CONF_FILENAME;
+extern char *SCRIPT_CONF_NAME;
+extern char *MSG_CONF_NAME;
+extern char *GRF_PATH_FILENAME;
+
#ifndef TXT_ONLY
// MySQL
diff --git a/src/map/mob.c b/src/map/mob.c
index 80cd6e346..b46b2a317 100644
--- a/src/map/mob.c
+++ b/src/map/mob.c
@@ -196,8 +196,8 @@ int mob_once_spawn (struct map_session_data *sd, char *mapname,
md->m = m;
md->x0 = x;
md->y0 = y;
- md->xs = 0;
- md->ys = 0;
+ //md->xs = 0;
+ //md->ys = 0;
md->spawndelay1 = -1; // 一度のみフラグ
md->spawndelay2 = -1; // 一度のみフラグ
@@ -297,14 +297,8 @@ int mob_spawn_guardian(struct map_session_data *sd,char *mapname,
for(count=0;count<amount;count++){
struct guild_castle *gc;
md=(struct mob_data *) aCalloc(sizeof(struct mob_data), 1);
- if(md==NULL){
- printf("mob_spawn_guardian: out of memory !\n");
- exit(1);
- }
memset(md, '\0', sizeof *md);
-
-
mob_spawn_dataset(md,mobname,class_);
md->bl.m=m;
md->bl.x=x;
@@ -334,7 +328,6 @@ int mob_spawn_guardian(struct map_session_data *sd,char *mapname,
if(guardian==5) { md->hp=gc->Ghp5; gc->GID5=md->bl.id; }
if(guardian==6) { md->hp=gc->Ghp6; gc->GID6=md->bl.id; }
if(guardian==7) { md->hp=gc->Ghp7; gc->GID7=md->bl.id; }
-
}
}
@@ -760,9 +753,6 @@ static int mob_timer(int tid,unsigned int tick,int id,int data)
nullpo_retr(1, md=(struct mob_data*)bl);
- if(!md->bl.type || md->bl.type!=BL_MOB)
- return 1;
-
if(md->timer != tid){
if(battle_config.error_log)
printf("mob_timer %d != %d\n",md->timer,tid);
@@ -1069,7 +1059,6 @@ int mob_stop_walking(struct mob_data *md,int type)
{
nullpo_retr(0, md);
-
if(md->state.state == MS_WALK || md->state.state == MS_IDLE) {
int dx=0,dy=0;
@@ -1405,6 +1394,18 @@ static int mob_ai_sub_hard_slavemob(struct mob_data *md,unsigned int tick)
if(!mmd || mmd->bl.type!=BL_MOB || mmd->bl.id!=md->master_id)
return 0;
+ // 呼び戻し
+ if(mmd->recall_flag == 1){
+ if (mmd->recallcount < (mmd->recallmob_count+2) ){
+ mob_warp(md,-1,mmd->bl.x,mmd->bl.y,3);
+ mmd->recallcount += 1;
+ } else{
+ mmd->recall_flag = 0;
+ mmd->recallcount=0;
+ }
+ md->state.master_check = 1;
+ return 0;
+ }
// Since it is in the map on which the master is not, teleport is carried out and it pursues.
if( mmd->bl.m != md->bl.m ){
mob_warp(md,mmd->bl.m,mmd->bl.x,mmd->bl.y,3);
@@ -1598,7 +1599,6 @@ static int mob_ai_sub_hard(struct block_list *bl,va_list ap)
tick=va_arg(ap,unsigned int);
-
if(DIFF_TICK(tick,md->last_thinktime)<MIN_MOBTHINKTIME)
return 0;
md->last_thinktime=tick;
@@ -1898,19 +1898,20 @@ static int mob_ai_hard(int tid,unsigned int tick,int id,int data)
static int mob_ai_sub_lazy(void * key,void * data,va_list app)
{
struct mob_data *md=(struct mob_data *)data;
+ struct mob_data *mmd=NULL;
unsigned int tick;
va_list ap;
nullpo_retr(0, md);
nullpo_retr(0, app);
-
- ap=va_arg(app,va_list);
+ nullpo_retr(0, ap=va_arg(app,va_list));
if(md->bl.type!=BL_MOB)
return 0;
- if(!md->bl.type || md->bl.type!=BL_MOB)
- return 0;
+ if (md->master_id > 0) {
+ mmd = (struct mob_data *)map_id2bl(md->master_id); //自分のBOSSの情報
+ }
tick=va_arg(ap,unsigned int);
@@ -1924,6 +1925,12 @@ static int mob_ai_sub_lazy(void * key,void * data,va_list app)
return 0;
}
+ // 取り巻きモンスターの処理(呼び戻しされた時)
+ if(mmd && md->state.special_mob_ai == 0 && mmd->recall_flag == 1) {
+ mob_ai_sub_hard_slavemob (md,tick);
+ return 0;
+ }
+
if(DIFF_TICK(md->next_walktime,tick)<0 &&
(mob_db[md->class_].mode&1) && mob_can_move(md) ){
@@ -2130,15 +2137,10 @@ int mob_catch_delete(struct mob_data *md,int type)
int mob_timer_delete(int tid, unsigned int tick, int id, int data)
{
- struct block_list *bl=map_id2bl(id);
- struct mob_data *md;
-
- nullpo_retr(0, bl);
+ struct mob_data *md=(struct mob_data *)map_id2bl(id);
+ nullpo_retr(0, md);
- md = (struct mob_data *)bl;
//for Alchemist CANNIBALIZE [Lupus]
-
-
mob_catch_delete(md,3);
return 0;
}
@@ -2476,10 +2478,6 @@ int mob_damage(struct block_list *src,struct mob_data *md,int damage,int type)
// [MouseJstr]
if((map[md->bl.m].flag.pvp == 0) || (battle_config.pvp_exp == 1)) {
-/* if((double)max_hp < tdmg)
- dmg_rate = ((double)max_hp) / tdmg;
- else dmg_rate = 1;*/
-
// 経験値の分配
for(i=0;i<DAMAGELOG_SIZE;i++){
int pid,base_exp,job_exp,flag=1,zeny=0;
@@ -2490,7 +2488,6 @@ int mob_damage(struct block_list *src,struct mob_data *md,int damage,int type)
if (battle_config.exp_calc_type == 0) {
// jAthena's exp formula
- // per = ((double)md->dmglog[i].dmg)*(9.+(double)((count > 6)? 6:count))/10./((double)max_hp) * dmg_rate;
per = ((double)md->dmglog[i].dmg)*(9.+(double)((count > 6)? 6:count))/10./tdmg;
temp = (double)mob_db[md->class_].base_exp * per;
base_exp = (temp > 2147483647.)? 0x7fffffff:(int)temp;
@@ -2552,7 +2549,7 @@ int mob_damage(struct block_list *src,struct mob_data *md,int damage,int type)
}
if((pid=tmpsd[i]->status.party_id)>0){ // パーティに入っている
- int j=0;
+ int j;
for(j=0;j<pnum;j++) // 公平パーティリストにいるかどうか
if(pt[j].id==pid)
break;
@@ -3006,7 +3003,6 @@ int mob_countslave_sub(struct block_list *bl,va_list ap)
nullpo_retr(0, c=va_arg(ap,int *));
nullpo_retr(0, md = (struct mob_data *)bl);
-
if( md->master_id==id )
(*c)++;
return 0;
@@ -3196,7 +3192,9 @@ int mobskill_castend_id( int tid, unsigned int tick, int id,int data )
md->skilltimer=-1;
//沈黙や状態異常など
if(md->sc_data){
- if(md->opt1>0 || md->sc_data[SC_DIVINA].timer != -1 || md->sc_data[SC_ROKISWEIL].timer != -1 || md->sc_data[SC_STEELBODY].timer != -1)
+ if(md->opt1>0 || md->sc_data[SC_DIVINA].timer != -1 ||
+ (!(mob_db[md->class_].mode & 0x20) && md->sc_data[SC_ROKISWEIL].timer != -1) ||
+ md->sc_data[SC_STEELBODY].timer != -1)
return 0;
if(md->sc_data[SC_AUTOCOUNTER].timer != -1 && md->skillid != KN_AUTOCOUNTER) //オートカウンター
return 0;
@@ -3279,7 +3277,9 @@ int mobskill_castend_pos( int tid, unsigned int tick, int id,int data )
md->skilltimer=-1;
if(md->sc_data){
- if(md->opt1>0 || md->sc_data[SC_DIVINA].timer != -1 || md->sc_data[SC_ROKISWEIL].timer != -1 || md->sc_data[SC_STEELBODY].timer != -1)
+ if(md->opt1>0 || md->sc_data[SC_DIVINA].timer != -1 ||
+ (!(mob_db[md->class_].mode & 0x20) && md->sc_data[SC_ROKISWEIL].timer != -1) ||
+ md->sc_data[SC_STEELBODY].timer != -1)
return 0;
if(md->sc_data[SC_AUTOCOUNTER].timer != -1 && md->skillid != KN_AUTOCOUNTER) //オートカウンター
return 0;
@@ -3354,7 +3354,9 @@ int mobskill_use_id(struct mob_data *md,struct block_list *target,int skill_idx)
// 沈黙や異常
if(md->sc_data){
- if(md->opt1>0 || md->sc_data[SC_DIVINA].timer != -1 || md->sc_data[SC_ROKISWEIL].timer != -1 || md->sc_data[SC_STEELBODY].timer != -1)
+ if(md->opt1>0 || md->sc_data[SC_DIVINA].timer != -1 ||
+ (!(mob_db[md->class_].mode & 0x20) && md->sc_data[SC_ROKISWEIL].timer != -1) ||
+ md->sc_data[SC_STEELBODY].timer != -1)
return 0;
if(md->sc_data[SC_AUTOCOUNTER].timer != -1 && md->skillid != KN_AUTOCOUNTER) //オートカウンター
return 0;
@@ -3471,7 +3473,9 @@ int mobskill_use_pos( struct mob_data *md,
//沈黙や状態異常など
if(md->sc_data){
- if(md->opt1>0 || md->sc_data[SC_DIVINA].timer != -1 || md->sc_data[SC_ROKISWEIL].timer != -1 || md->sc_data[SC_STEELBODY].timer != -1)
+ if(md->opt1>0 || md->sc_data[SC_DIVINA].timer != -1 ||
+ (!(mob_db[md->class_].mode & 0x20) && md->sc_data[SC_ROKISWEIL].timer != -1) ||
+ md->sc_data[SC_STEELBODY].timer != -1)
return 0;
if(md->sc_data[SC_AUTOCOUNTER].timer != -1 && md->skillid != KN_AUTOCOUNTER) //オートカウンター
return 0;
diff --git a/src/map/mob.h b/src/map/mob.h
index aa5753902..e5e95879e 100644
--- a/src/map/mob.h
+++ b/src/map/mob.h
@@ -139,6 +139,7 @@ int mobskill_event(struct mob_data *md,int flag);
int mobskill_castend_id( int tid, unsigned int tick, int id,int data );
int mobskill_castend_pos( int tid, unsigned int tick, int id,int data );
int mob_summonslave(struct mob_data *md2,int *value,int amount,int flag);
+int mob_countslave(struct mob_data *md);
int mob_gvmobcheck(struct map_session_data *sd, struct block_list *bl);
void mob_reload(void);
diff --git a/src/map/party.c b/src/map/party.c
index e33dc37cc..17f0cf5eb 100644
--- a/src/map/party.c
+++ b/src/map/party.c
@@ -175,7 +175,7 @@ int party_recv_info(struct party *sp)
for(i=0;i<MAX_PARTY;i++){ // sdの設定
struct map_session_data *sd = map_id2sd(p->member[i].account_id);
- p->member[i].sd=(sd!=NULL && sd->status.party_id==p->party_id)?sd:NULL;
+ p->member[i].sd=(sd!=NULL && sd->status.party_id==p->party_id && !sd->state.waitingdisconnect)?sd:NULL;
}
clif_party_info(p,-1);
@@ -419,7 +419,7 @@ int party_recv_movemap(int party_id,int account_id,char *map,int online,int lv)
for(i=0;i<MAX_PARTY;i++){ // sd再設定
struct map_session_data *sd= map_id2sd(p->member[i].account_id);
- p->member[i].sd=(sd!=NULL && sd->status.party_id==p->party_id)?sd:NULL;
+ p->member[i].sd=(sd!=NULL && sd->status.party_id==p->party_id && !sd->state.waitingdisconnect)?sd:NULL;
}
party_send_xy_clear(p); // 座標再通知要請
diff --git a/src/map/pc.c b/src/map/pc.c
index 3dcb08f3b..b9185c8b8 100644
--- a/src/map/pc.c
+++ b/src/map/pc.c
@@ -714,8 +714,7 @@ int pc_authok(int id, int login_id2, time_t connect_until_time, struct mmo_chars
sd->skilltimerskill[i].timer = -1;
sd->timerskill_count=0;
- for (i=0; i<MAX_SKILL; i++)
- sd->blockskill[i]=0;
+ memset(sd->blockskill,0,sizeof(sd->blockskill));
memset(&sd->dev,0,sizeof(struct square));
for(i = 0; i < 5; i++) {
@@ -2037,25 +2036,24 @@ int pc_skill(struct map_session_data *sd,int id,int level,int flag)
*/
int pc_blockskill_end(int tid,unsigned int tick,int id,int data)
{
- struct map_session_data *sd;
-
- nullpo_retr (-1, sd = map_id2sd(id));
- sd->blockskill[data] = 0;
+ struct map_session_data *sd = map_id2sd(id);
+ if (data <= 0 || data >= MAX_SKILL)
+ return 0;
+ if (sd) sd->blockskill[data] = 0;
return 1;
}
-void pc_blockskill_start (struct map_session_data *sd, int skillid, int tick)
+int pc_blockskill_start (struct map_session_data *sd, int skillid, int tick)
{
- nullpo_retv(sd);
+ nullpo_retr (-1, sd);
if (skillid >= 10000 && skillid < 10015)
skillid -= 9500;
else if (skillid < 1 || skillid > MAX_SKILL)
- return;
+ return -1;
sd->blockskill[skillid] = 1;
- add_timer(gettick()+tick,pc_blockskill_end,sd->bl.id,skillid);
- return;
+ return add_timer(gettick()+tick,pc_blockskill_end,sd->bl.id,skillid);
}
/*==========================================
@@ -2460,6 +2458,7 @@ int pc_useitem(struct map_session_data *sd,int n)
nullpo_retr(1, sd);
if(n >=0 && n < MAX_INVENTORY) {
+ char *script;
sd->itemid = sd->status.inventory[n].nameid;
amount = sd->status.inventory[n].amount;
if(sd->status.inventory[n].nameid <= 0 ||
@@ -2474,12 +2473,10 @@ int pc_useitem(struct map_session_data *sd,int n)
clif_useitemack(sd,n,0,0);
return 1;
}
-
- if(sd->inventory_data[n])
- run_script(sd->inventory_data[n]->use_script,0,sd->bl.id,0);
-
+ script = sd->inventory_data[n]->use_script;
amount = sd->status.inventory[n].amount;
clif_useitemack(sd,n,amount-1,1);
+ run_script(script,0,sd->bl.id,0);
pc_delitem(sd,n,1,1);
}
@@ -2878,40 +2875,53 @@ int pc_steal_coin(struct map_session_data *sd,struct block_list *bl)
//
//
/*==========================================
- * PCの位置設定
+ * PCをマップから離脱する
*------------------------------------------
*/
-int pc_setpos(struct map_session_data *sd,char *mapname_org,int x,int y,int clrtype)
-{
- char mapname[24];
- int m=0,disguise=0;
+int pc_remove_map(struct map_session_data *sd,int clrtype) {
nullpo_retr(0, sd);
- if(sd->chatID) // チャットから出る
+ // map 上に登録されていない
+ if(!sd->bl.prev)
+ return 1;
+
+ // チャットから出る
+ if(sd->chatID)
chat_leavechat(sd);
- if(sd->trade_partner) // 取引を中?する
+
+ // 取引を中断する
+ if(sd->trade_partner)
trade_tradecancel(sd);
+
+ // 倉庫を開いてるなら保存する
if(sd->state.storage_flag)
storage_guild_storage_quit(sd,0);
else
- storage_storage_quit(sd); // 倉庫を開いてるなら保存する
+ storage_storage_quit(sd);
- if(sd->party_invite>0) // パ?ティ?誘を拒否する
+ // パーティ勧誘を拒否する
+ if(sd->party_invite>0)
party_reply_invite(sd,sd->party_invite_account,0);
- if(sd->guild_invite>0) // ギルド?誘を拒否する
+
+ // ギルド勧誘を拒否する
+ if(sd->guild_invite>0)
guild_reply_invite(sd,sd->guild_invite,0);
- if(sd->guild_alliance>0) // ギルド同盟?誘を拒否する
+
+ // ギルド同盟勧誘を拒否する
+ if(sd->guild_alliance>0)
guild_reply_reqalliance(sd,sd->guild_alliance_account,0);
- skill_castcancel(&sd->bl,0); // 詠唱中?
- pc_stop_walking(sd,0); // ?行中?
- pc_stopattack(sd); // 攻?中?
+ // check if we've been authenticated [celest]
+ //if (sd->state.auth) {
+ pc_stop_walking(sd,0); // 歩行中断
+ pc_stopattack(sd); // 攻撃中断
+ pc_delinvincibletimer(sd); // 無敵タイマー削除
+ //}
- if(pc_issit(sd)) {
- pc_setstand(sd);
- skill_gangsterparadise(sd,0);
- }
+ // ブレードストップを終わらせる
+ if(sd->sc_data[SC_BLADESTOP].timer!=-1)
+ status_change_end(&sd->bl,SC_BLADESTOP,-1);
if (sd->sc_count) {
if(sd->sc_data[SC_TRICKDEAD].timer != -1)
@@ -2933,6 +2943,35 @@ int pc_setpos(struct map_session_data *sd,char *mapname_org,int x,int y,int clrt
}
}
+ // check if we've been authenticated [celest]
+ //if (sd->state.auth)
+ skill_castcancel(&sd->bl,0); // 詠唱中断
+ skill_gangsterparadise(sd,0); // ギャングスターパラダイス削除
+ skill_unit_move(&sd->bl,gettick(),0); // スキルユニットから離脱
+ skill_cleartimerskill(&sd->bl); // タイマースキルクリア
+ skill_clear_unitgroup(&sd->bl); // スキルユニットグループの削除
+
+ clif_clearchar_area(&sd->bl,clrtype&0xffff);
+ map_delblock(&sd->bl);
+ return 0;
+}
+
+/*==========================================
+ * PCの位置設定
+ *------------------------------------------
+ */
+int pc_setpos(struct map_session_data *sd,char *mapname_org,int x,int y,int clrtype)
+{
+ char mapname[24];
+ int m=0,disguise=0;
+
+ nullpo_retr(0, sd);
+
+ if(pc_issit(sd)) {
+ pc_setstand(sd);
+ skill_gangsterparadise(sd,0);
+ }
+
if(sd->status.option&2)
status_change_end(&sd->bl, SC_HIDING, -1);
if(sd->status.option&4)
@@ -2940,11 +2979,6 @@ int pc_setpos(struct map_session_data *sd,char *mapname_org,int x,int y,int clrt
if(sd->status.option&16384)
status_change_end(&sd->bl, SC_CHASEWALK, -1);
- if(sd->status.pet_id > 0 && sd->pd && sd->pet.intimate > 0) {
- pet_stopattack(sd->pd);
- pet_changestate(sd->pd,MS_IDLE,0);
- }
-
if(sd->disguise) { // clear disguises when warping [Valaris]
clif_clearchar(&sd->bl, 9);
disguise=sd->disguise;
@@ -2960,14 +2994,9 @@ int pc_setpos(struct map_session_data *sd,char *mapname_org,int x,int y,int clrt
m=map_mapname2mapid(mapname);
if(m<0){
- if(sd->mapname[0]){
+ //if(sd->mapname[0]){
int ip,port;
if(map_mapname2ipport(mapname,&ip,&port)==0){
- skill_stop_dancing(&sd->bl,1);
- skill_unit_move(&sd->bl,gettick(),0);
- clif_clearchar_area(&sd->bl,clrtype&0xffff);
- skill_gangsterparadise(sd,0);
- map_delblock(&sd->bl);
if(sd->status.pet_id > 0 && sd->pd) {
if(sd->pd->bl.m != m && sd->pet.intimate <= 0) {
pet_remove_map(sd);
@@ -2985,6 +3014,15 @@ int pc_setpos(struct map_session_data *sd,char *mapname_org,int x,int y,int clrt
map_delblock(&sd->pd->bl);
}
}
+
+ party_send_logout(sd); // パーティのログアウトメッセージ送信
+ guild_send_memberinfoshort(sd,0); // ギルドのログアウトメッセージ送信
+ status_change_clear(&sd->bl,1); // ステータス異常を解除する
+ skill_stop_dancing(&sd->bl,1); // ダンス/演奏中断
+ pc_cleareventtimer(sd); // イベントタイマを破棄する
+ pc_delspiritball(sd,sd->spiritball,1); // 気功削除
+ pc_remove_map(sd,clrtype);
+
memcpy(sd->mapname,mapname,24);
sd->bl.x=x;
sd->bl.y=y;
@@ -2998,7 +3036,7 @@ int pc_setpos(struct map_session_data *sd,char *mapname_org,int x,int y,int clrt
chrif_changemapserver(sd, mapname, x, y, ip, port);
return 0;
}
- }
+ //}
#if 0
clif_authfail_fd(sd->fd,0); // cancel
clif_setwaitclose(sd->fd);
@@ -3019,12 +3057,17 @@ int pc_setpos(struct map_session_data *sd,char *mapname_org,int x,int y,int clrt
} while(map_getcell(m,x,y,CELL_CHKNOPASS));
}
- if(sd->mapname[0] && sd->bl.prev != NULL){
- skill_unit_move(&sd->bl,gettick(),0);
- clif_clearchar_area(&sd->bl,clrtype&0xffff);
- skill_gangsterparadise(sd,0);
- map_delblock(&sd->bl);
- // pet
+ if(m == sd->bl.m) {
+ // 同じマップなのでダンスユニット引き継ぎ
+ sd->to_x = x;
+ sd->to_y = y;
+ skill_stop_dancing(&sd->bl, 2); //移動先にユニットを移動するかどうかの判断もする
+ } else {
+ // 違うマップなのでダンスユニット削除
+ skill_stop_dancing(&sd->bl, 1);
+ }
+ if(sd->bl.prev != NULL){
+ pc_remove_map(sd,clrtype);
if(sd->status.pet_id > 0 && sd->pd) {
if(sd->pd->bl.m != m && sd->pet.intimate <= 0) {
pet_remove_map(sd);
@@ -3034,9 +3077,6 @@ int pc_setpos(struct map_session_data *sd,char *mapname_org,int x,int y,int clrt
sd->petDB = NULL;
if(battle_config.pet_status_support)
status_calc_pc(sd,2);
- pc_makesavestatus(sd);
- chrif_save(sd);
- storage_storage_save(sd);
}
else if(sd->pet.intimate > 0) {
pet_stopattack(sd->pd);
@@ -3053,13 +3093,8 @@ int pc_setpos(struct map_session_data *sd,char *mapname_org,int x,int y,int clrt
memcpy(sd->mapname,mapname,24);
sd->bl.m = m;
- sd->to_x = x;
- sd->to_y = y;
-
- // moved and changed dance effect stopping
-
- sd->bl.x = x;
- sd->bl.y = y;
+ sd->bl.x = x;
+ sd->bl.y = y;
if(sd->status.pet_id > 0 && sd->pd && sd->pet.intimate > 0) {
sd->pd->bl.m = m;
diff --git a/src/map/pc.h b/src/map/pc.h
index 1e5b3408f..b1db3a254 100644
--- a/src/map/pc.h
+++ b/src/map/pc.h
@@ -65,6 +65,7 @@ int pc_setsavepoint(struct map_session_data*,char*,int,int);
int pc_randomwarp(struct map_session_data *sd,int type);
int pc_memo(struct map_session_data *sd,int i);
int pc_randomwalk(struct map_session_data*,int tick);
+int pc_remove_map(struct map_session_data *sd,int clrtype);
int pc_checkadditem(struct map_session_data*,int,int);
int pc_inventoryblank(struct map_session_data*);
@@ -92,7 +93,7 @@ int pc_bonus3(struct map_session_data *sd,int,int,int,int);
int pc_bonus4(struct map_session_data *sd,int,int,int,int,int);
int pc_skill(struct map_session_data*,int,int,int);
-void pc_blockskill_start (struct map_session_data*,int,int); // [celest]
+int pc_blockskill_start (struct map_session_data*,int,int); // [celest]
int pc_insert_card(struct map_session_data *sd,int idx_card,int idx_equip);
@@ -202,6 +203,7 @@ int pc_delspiritball(struct map_session_data *sd,int,int);
int pc_eventtimer(int tid,unsigned int tick,int id,int data); // for npc_dequeue
+int pc_readdb(void);
int do_init_pc(void);
void do_final_pc(void);
diff --git a/src/map/pet.c b/src/map/pet.c
index 87257f6be..351782e7f 100644
--- a/src/map/pet.c
+++ b/src/map/pet.c
@@ -816,7 +816,7 @@ int pet_recv_petdata(int account_id,struct s_pet *p,int flag)
pet_birth_process(sd);
else {
pet_data_init(sd);
- if(sd->bl.prev != NULL) {
+ if(sd->pd && sd->bl.prev != NULL) {
map_addblock(&sd->pd->bl);
clif_spawnpet(sd->pd);
clif_send_petdata(sd,0,0);
diff --git a/src/map/pet.h b/src/map/pet.h
index 6f532b140..4d81583b1 100644
--- a/src/map/pet.h
+++ b/src/map/pet.h
@@ -61,6 +61,7 @@ int pet_mag_timer(int tid,unsigned int tick,int id,int data); // [Valaris]
int pet_heal_timer(int tid,unsigned int tick,int id,int data); // [Valaris]
int pet_skillattack_timer(int tid,unsigned int tick,int id,int data); // [Valaris]
+int read_petdb();
int do_init_pet(void);
int do_final_pet(void);
diff --git a/src/map/skill.c b/src/map/skill.c
index 8420f0ac5..40626fa57 100644
--- a/src/map/skill.c
+++ b/src/map/skill.c
@@ -2757,20 +2757,16 @@ int skill_castend_damage_id( struct block_list* src, struct block_list *bl,int s
* スキル使用(詠唱完了、ID指定支援系)
*------------------------------------------
*/
-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_nodamage_id (struct block_list *src, struct block_list *bl, int skillid, int skilllv, unsigned int tick, int flag)
{
- struct map_session_data *sd=NULL;
- struct map_session_data *dstsd=NULL;
- struct mob_data *md=NULL;
- struct mob_data *dstmd=NULL;
- int i,abra_skillid=0,abra_skilllv;
- int sc_def_vit,sc_def_mdef;
- int sc_dex,sc_luk;
- //クラスチェンジ用ボスモンスタ?ID
- int changeclass[]={1038,1039,1046,1059,1086,1087,1112,1115
- ,1157,1159,1190,1272,1312,1373,1492};
- int poringclass[]={1002};
-
+ struct map_session_data *sd = NULL;
+ struct map_session_data *dstsd = NULL;
+ struct mob_data *md = NULL;
+ struct mob_data *dstmd = NULL;
+ int i;
+ int sc_def_vit, sc_def_mdef;
+ int sc_dex, sc_luk;
+
if(skillid < 0)
{ // remove the debug print when this case is finished
printf("skill_castend_damage_id: skillid=%i\ncall: %p %p %i %i %i %i",skillid,
@@ -2782,23 +2778,24 @@ int skill_castend_nodamage_id( struct block_list *src, struct block_list *bl,int
nullpo_retr(1, src);
nullpo_retr(1, bl);
- if(src->type==BL_PC)
- sd=(struct map_session_data *)src;
- else if(src->type==BL_MOB)
- md=(struct mob_data *)src;
+ if (src->type == BL_PC) {
+ nullpo_retr (1, sd = (struct map_session_data *)src);
+ } else if (src->type == BL_MOB) {
+ nullpo_retr (1, md = (struct mob_data *)src);
+ }
- sc_dex=status_get_mdef(bl);
- sc_luk=status_get_luk(bl);
- sc_def_vit = status_get_sc_def_vit(bl);
+ sc_dex = status_get_mdef (bl);
+ sc_luk = status_get_luk (bl);
+ sc_def_vit = status_get_sc_def_vit (bl);
sc_def_mdef = status_get_sc_def_mdef (bl);
- if(bl->type==BL_PC){
- nullpo_retr(1, dstsd=(struct map_session_data *)bl);
- }else if(bl->type==BL_MOB){
- nullpo_retr(1, dstmd=(struct mob_data *)bl);
+ if (bl->type == BL_PC){
+ nullpo_retr (1, dstsd = (struct map_session_data *)bl);
+ } else if (bl->type == BL_MOB){
+ nullpo_retr (1, dstmd = (struct mob_data *)bl);
}
- if(bl == NULL || bl->prev == NULL)
+ if(bl->prev == NULL)
return 1;
if(sd && pc_isdead(sd))
return 1;
@@ -2814,44 +2811,42 @@ int skill_castend_nodamage_id( struct block_list *src, struct block_list *bl,int
{
case AL_HEAL: /* ヒ?ル */
{
- int heal=skill_calc_heal( src, skilllv );
+ int heal = skill_calc_heal(src, skilllv);
int heal_get_jobexp;
int skill;
- struct pc_base_job s_class;
-
- if( dstsd && dstsd->special_state.no_magic_damage )
+
+ if (skilllv > 10)
+ heal = 9999; //9999ヒール
+ if (dstsd && dstsd->special_state.no_magic_damage)
heal=0; /* ?金蟲カ?ド(ヒ?ル量0) */
- if (sd){
- s_class = pc_calc_base_job(sd->status.class_);
- if((skill=pc_checkskill(sd,HP_MEDITATIO))>0) // メディテイティオ
- heal += heal*skill*2/100;
- if(sd && dstsd && sd->status.partner_id == dstsd->status.char_id && s_class.job == 23 && sd->status.sex == 0) //自分も?象もPC、?象が自分のパ?トナ?、自分がスパノビ、自分が♀なら
+ if (sd) {
+ if ((skill = pc_checkskill(sd, HP_MEDITATIO)) > 0) // メディテイティオ
+ heal += heal * skill * 2 / 100;
+ if (sd && dstsd && sd->status.partner_id == dstsd->status.char_id &&
+ pc_calc_base_job2(sd->status.class_) == 23 && sd->status.sex == 0) //自分も?象もPC、?象が自分のパ?トナ?、自分がスパノビ、自分が♀なら
heal = heal*2; //スパノビの嫁が旦那にヒ?ルすると2倍になる
}
-
- clif_skill_nodamage(src,bl,skillid,heal,1);
+ clif_skill_nodamage (src, bl, skillid, heal, 1);
heal_get_jobexp = battle_heal(NULL,bl,heal,0,0);
// JOB??値獲得
- if(src->type == BL_PC && bl->type==BL_PC && heal > 0 && src != bl && battle_config.heal_exp > 0){
+ if(sd && dstsd && heal > 0 && sd != dstsd && battle_config.heal_exp > 0){
heal_get_jobexp = heal_get_jobexp * battle_config.heal_exp / 100;
- if(heal_get_jobexp <= 0)
+ if (heal_get_jobexp <= 0)
heal_get_jobexp = 1;
- pc_gainexp((struct map_session_data *)src,0,heal_get_jobexp);
+ pc_gainexp (sd, 0, heal_get_jobexp);
}
}
break;
case ALL_RESURRECTION: /* リザレクション */
- if(bl->type==BL_PC){
- int per=0;
- struct map_session_data *tsd = (struct map_session_data*)bl;
- nullpo_retr(1, tsd);
- if( (map[bl->m].flag.pvp) && tsd->pvp_point<0 )
+ if(dstsd) {
+ int per = 0;
+ if (map[bl->m].flag.pvp && dstsd->pvp_point < 0)
break; /* PVPで復活不可能?態 */
- if(pc_isdead(tsd)){ /* 死亡判定 */
+ if (pc_isdead(dstsd)) { /* 死亡判定 */
clif_skill_nodamage(src,bl,skillid,skilllv,1);
switch(skilllv){
case 1: per=10; break;
@@ -2859,60 +2854,58 @@ int skill_castend_nodamage_id( struct block_list *src, struct block_list *bl,int
case 3: per=50; break;
case 4: per=80; break;
}
- tsd->status.hp=tsd->status.max_hp*per/100;
- if(tsd->status.hp<=0) tsd->status.hp=1;
- if(tsd->special_state.restart_full_recover ){ /* オシリスカ?ド */
- tsd->status.hp=tsd->status.max_hp;
- tsd->status.sp=tsd->status.max_sp;
+ dstsd->status.hp = dstsd->status.max_hp * per / 100;
+ if (dstsd->status.hp <= 0) dstsd->status.hp = 1;
+ if (dstsd->special_state.restart_full_recover) { /* オシリスカ?ド */
+ dstsd->status.hp = dstsd->status.max_hp;
+ dstsd->status.sp = dstsd->status.max_sp;
}
- pc_setstand(tsd);
+ pc_setstand(dstsd);
if(battle_config.pc_invincible_time > 0)
- pc_setinvincibletimer(tsd,battle_config.pc_invincible_time);
- clif_updatestatus(tsd,SP_HP);
- clif_resurrection(&tsd->bl,1);
- if(src != bl && sd && battle_config.resurrection_exp > 0) {
+ pc_setinvincibletimer(dstsd, battle_config.pc_invincible_time);
+ clif_updatestatus(dstsd, SP_HP);
+ clif_resurrection(bl, 1);
+ if(sd && sd != dstsd && battle_config.resurrection_exp > 0) {
int exp = 0,jexp = 0;
- int lv = tsd->status.base_level - sd->status.base_level, jlv = tsd->status.job_level - sd->status.job_level;
+ int lv = dstsd->status.base_level - sd->status.base_level, jlv = dstsd->status.job_level - sd->status.job_level;
if(lv > 0) {
- exp = (int)((double)tsd->status.base_exp * (double)lv * (double)battle_config.resurrection_exp / 1000000.);
- if(exp < 1) exp = 1;
+ exp = (int)((double)dstsd->status.base_exp * (double)lv * (double)battle_config.resurrection_exp / 1000000.);
+ if (exp < 1) exp = 1;
}
if(jlv > 0) {
- jexp = (int)((double)tsd->status.job_exp * (double)lv * (double)battle_config.resurrection_exp / 1000000.);
- if(jexp < 1) jexp = 1;
+ jexp = (int)((double)dstsd->status.job_exp * (double)lv * (double)battle_config.resurrection_exp / 1000000.);
+ if (jexp < 1) jexp = 1;
}
if(exp > 0 || jexp > 0)
- pc_gainexp(sd,exp,jexp);
+ pc_gainexp (sd, exp, jexp);
}
}
}
break;
case AL_DECAGI: /* 速度減少 */
- if( bl->type==BL_PC && ((struct map_session_data *)bl)->special_state.no_magic_damage )
+ if (dstsd && dstsd->special_state.no_magic_damage)
break;
- if( rand()%100 < (50+skilllv*3+(status_get_lv(src)+status_get_int(src)/5)-sc_def_mdef) ) {
- clif_skill_nodamage(src,bl,skillid,skilllv,1);
- status_change_start(bl,SkillStatusChangeTable[skillid],skilllv,0,0,0,skill_get_time(skillid,skilllv),0);
+ if (rand() % 100 < (50 + skilllv * 3 + (status_get_lv(src) + status_get_int(src) / 5) - sc_def_mdef)) {
+ clif_skill_nodamage (src, bl, skillid, skilllv, 1);
+ status_change_start (bl, SkillStatusChangeTable[skillid], skilllv, 0, 0, 0, skill_get_time(skillid,skilllv), 0);
}
break;
case AL_CRUCIS:
- if(flag&1) {
- int race = status_get_race(bl),ele = status_get_elem_type(bl);
- if(battle_check_target(src,bl,BCT_ENEMY) && (race == 6 || battle_check_undead(race,ele))) {
- int slv=status_get_lv(src),tlv=status_get_lv(bl),rate;
- rate = 25 + skilllv*2 + slv - tlv;
- if(rand()%100 < rate)
+ if (flag & 1) {
+ int race = status_get_race (bl), ele = status_get_elem_type (bl);
+ if (battle_check_target (src, bl, BCT_ENEMY) && (race == 6 || battle_check_undead (race, ele))) {
+ int slv = status_get_lv (src),tlv = status_get_lv (bl);
+ int rate = 25 + skilllv*2 + slv - tlv;
+ if (rand()%100 < rate)
status_change_start(bl,SkillStatusChangeTable[skillid],skilllv,0,0,0,0,0);
}
- }
- else {
- int range = 15;
- clif_skill_nodamage(src,bl,skillid,skilllv,1);
+ } else {
+ clif_skill_nodamage(src, bl, skillid, skilllv, 1);
map_foreachinarea(skill_area_sub,
- src->m,src->x-range,src->y-range,src->x+range,src->y+range,0,
- src,skillid,skilllv,tick, flag|BCT_ENEMY|1,
+ src->m, src->x-15, src->y-15, src->x+15, src->y+15, 0,
+ src, skillid, skilllv, tick, flag|BCT_ENEMY|1,
skill_castend_nodamage_id);
}
break;
@@ -2920,78 +2913,90 @@ int skill_castend_nodamage_id( struct block_list *src, struct block_list *bl,int
case PR_LEXDIVINA: /* レックスディビ?ナ */
{
struct status_change *sc_data = status_get_sc_data(bl);
- clif_skill_nodamage(src,bl,skillid,skilllv,1);
- if( bl->type==BL_PC && ((struct map_session_data *)bl)->special_state.no_magic_damage )
+ clif_skill_nodamage (src, bl, skillid, skilllv, 1);
+ if (dstsd && dstsd->special_state.no_magic_damage)
break;
- if(sc_data && sc_data[SC_DIVINA].timer != -1)
- status_change_end(bl,SC_DIVINA,-1);
- else if( rand()%100 < sc_def_vit ) {
+ if (sc_data && sc_data[SC_DIVINA].timer != -1)
+ status_change_end(bl,SC_DIVINA, -1);
+ else if (rand() % 100 < sc_def_vit) {
status_change_start(bl,SkillStatusChangeTable[skillid],skilllv,0,0,0,skill_get_time(skillid,skilllv),0);
}
}
break;
+
case SA_ABRACADABRA:
- //require 1 yellow gemstone even with mistress card or Into the Abyss
- if ((i=pc_search_inventory(sd, 715)) < 0 ) { //bug fixed by Lupus (item pos can be 0, too!)
- clif_skill_fail(sd,sd->skillid,0,0);
- break;
+ {
+ int skill, abra_skillid = 0, abra_skilllv;
+ //require 1 yellow gemstone even with mistress card or Into the Abyss
+ if ((i = pc_search_inventory(sd, 715)) < 0 ) { //bug fixed by Lupus (item pos can be 0, too!)
+ clif_skill_fail(sd,sd->skillid,0,0);
+ break;
+ }
+ pc_delitem(sd, i, 1, 0);
+ do {
+ abra_skillid = skill_abra_dataset(skilllv);
+ } while (abra_skillid == 0);
+ skill = pc_checkskill(sd,SA_ABRACADABRA);
+ abra_skilllv = skill_get_max(abra_skillid) > skill ? skill : skill_get_max(abra_skillid);
+ clif_skill_nodamage (src, bl, skillid, skilllv, 1);
+ sd->skillitem = abra_skillid;
+ sd->skillitemlv = abra_skilllv;
+ clif_item_skill (sd, abra_skillid, abra_skilllv, "Abracadabra");
}
- //pc_delitem(sd, pc_search_inventory(sd, 715), 1, 0);
- pc_delitem(sd, i, 1, 0);
- //
- do{
- abra_skillid=skill_abra_dataset(skilllv);
- }while(abra_skillid == 0);
- abra_skilllv=skill_get_max(abra_skillid)>pc_checkskill(sd,SA_ABRACADABRA)?pc_checkskill(sd,SA_ABRACADABRA):skill_get_max(abra_skillid);
- clif_skill_nodamage(src,bl,skillid,skilllv,1);
- sd->skillitem=abra_skillid;
- sd->skillitemlv=abra_skilllv;
- clif_item_skill(sd,abra_skillid,abra_skilllv,"アブラカダブラ");
break;
+
case SA_COMA:
clif_skill_nodamage(src,bl,skillid,skilllv,1);
- if( bl->type==BL_PC && ((struct map_session_data *)bl)->special_state.no_magic_damage )
- break;
- if(dstsd){
- dstsd->status.hp=1;
- dstsd->status.sp=1;
- clif_updatestatus(dstsd,SP_HP);
- clif_updatestatus(dstsd,SP_SP);
+ if (dstsd) {
+ if (dstsd->special_state.no_magic_damage)
+ break;
+ dstsd->status.hp = 1;
+ dstsd->status.sp = 1;
+ clif_updatestatus(dstsd, SP_HP);
+ clif_updatestatus(dstsd, SP_SP);
}
- if(dstmd) dstmd->hp=1;
+ if(dstmd) dstmd->hp = 1;
break;
case SA_FULLRECOVERY:
clif_skill_nodamage(src,bl,skillid,skilllv,1);
- if( bl->type==BL_PC && ((struct map_session_data *)bl)->special_state.no_magic_damage )
- break;
- if(dstsd) pc_heal(dstsd,dstsd->status.max_hp,dstsd->status.max_sp);
- if(dstmd) dstmd->hp=status_get_max_hp(&dstmd->bl);
+ if (dstsd) {
+ if (dstsd->special_state.no_magic_damage)
+ break;
+ pc_heal (dstsd, dstsd->status.max_hp, dstsd->status.max_sp);
+ }
+ if (dstmd) dstmd->hp = status_get_max_hp(bl);
break;
case SA_SUMMONMONSTER:
clif_skill_nodamage(src,bl,skillid,skilllv,1);
- if (sd) mob_once_spawn(sd,map[sd->bl.m].name,sd->bl.x,sd->bl.y,"--ja--",-1,1,"");
+ if (sd) mob_once_spawn(sd,map[src->m].name,src->x,src->y,"--ja--",-1,1,"");
break;
case SA_LEVELUP:
clif_skill_nodamage(src,bl,skillid,skilllv,1);
- if (sd && pc_nextbaseexp(sd)) pc_gainexp(sd,pc_nextbaseexp(sd)*10/100,0);
+ if (sd && pc_nextbaseexp(sd)) pc_gainexp(sd, pc_nextbaseexp(sd) * 10 / 100, 0);
break;
-
case SA_INSTANTDEATH:
clif_skill_nodamage(src,bl,skillid,skilllv,1);
if (sd) pc_damage(NULL,sd,sd->status.max_hp);
break;
-
case SA_QUESTION:
case SA_GRAVITY:
clif_skill_nodamage(src,bl,skillid,skilllv,1);
break;
case SA_CLASSCHANGE:
- clif_skill_nodamage(src,bl,skillid,skilllv,1);
- if(dstmd) mob_class_change(dstmd,changeclass);
+ {
+ //クラスチェンジ用ボスモンスタ?ID
+ int changeclass[]={1038,1039,1046,1059,1086,1087,1112,1115
+ ,1157,1159,1190,1272,1312,1373,1492};
+ clif_skill_nodamage(src,bl,skillid,skilllv,1);
+ if(dstmd) mob_class_change(dstmd,changeclass);
+ }
break;
case SA_MONOCELL:
- clif_skill_nodamage(src,bl,skillid,skilllv,1);
- if(dstmd) mob_class_change(dstmd,poringclass);
+ {
+ int poringclass[]={1002};
+ clif_skill_nodamage(src,bl,skillid,skilllv,1);
+ if(dstmd) mob_class_change(dstmd,poringclass);
+ }
break;
case SA_DEATH:
clif_skill_nodamage(src,bl,skillid,skilllv,1);
@@ -3008,15 +3013,16 @@ int skill_castend_nodamage_id( struct block_list *src, struct block_list *bl,int
break;
case SA_TAMINGMONSTER:
clif_skill_nodamage(src,bl,skillid,skilllv,1);
- if (dstmd){
- for(i=0;i<MAX_PET_DB;i++){
- if(dstmd->class_ == pet_db[i].class_){
- pet_catch_process1(sd,dstmd->class_);
+ if (dstmd) {
+ for (i = 0; i < MAX_PET_DB; i++) {
+ if (dstmd->class_ == pet_db[i].class_) {
+ pet_catch_process1 (sd, dstmd->class_);
break;
}
}
}
break;
+
case AL_INCAGI: /* 速度?加 */
case AL_BLESSING: /* ブレッシング */
case PR_SLOWPOISON:
@@ -3025,23 +3031,22 @@ int skill_castend_nodamage_id( struct block_list *src, struct block_list *bl,int
case PR_SUFFRAGIUM: /* サフラギウム */
case PR_BENEDICTIO: /* 聖?降福 */
case CR_PROVIDENCE: /* プロヴィデンス */
- if( bl->type==BL_PC && ((struct map_session_data *)bl)->special_state.no_magic_damage ){
+ if (dstsd && dstsd->special_state.no_magic_damage)
clif_skill_nodamage(src,bl,skillid,skilllv,1);
- }else{
+ else {
status_change_start(bl,SkillStatusChangeTable[skillid],skilllv,0,0,0,skill_get_time(skillid,skilllv),0 );
clif_skill_nodamage(src,bl,skillid,skilllv,1);
}
break;
case CG_MARIONETTE: /* マリオネットコントロ?ル */
- if(sd && dstsd){
+ if (sd && dstsd){
struct status_change *sc_data = status_get_sc_data(src);
struct status_change *tsc_data = status_get_sc_data(bl);
int sc = SkillStatusChangeTable[skillid];
int sc2 = SC_MARIONETTE2;
- if((dstsd->bl.type!=BL_PC)
- || (sd->bl.id == dstsd->bl.id)
+ if ((sd == dstsd)
|| (!sd->status.party_id)
|| (sd->status.party_id != dstsd->status.party_id)) {
clif_skill_fail(sd,skillid,0,0);
@@ -3049,12 +3054,12 @@ int skill_castend_nodamage_id( struct block_list *src, struct block_list *bl,int
return 1;
}
if(sc_data && tsc_data){
- if(sc_data[sc].timer == -1 && tsc_data[sc2].timer == -1) {
+ if (sc_data[sc].timer == -1 && tsc_data[sc2].timer == -1) {
status_change_start (src,sc,skilllv,0,bl->id,0,skill_get_time(skillid,skilllv),0);
status_change_start (bl,sc2,skilllv,0,src->id,0,skill_get_time(skillid,skilllv),0);
}
else if (sc_data[sc].timer != -1 && tsc_data[sc2].timer != -1 &&
- sc_data[sc].val3 == bl->id && tsc_data[sc2].val3 == src->id) {
+ sc_data[sc].val3 == bl->id && tsc_data[sc2].val3 == src->id) {
status_change_end(src, sc, -1);
status_change_end(bl, sc2, -1);
}
@@ -3072,16 +3077,18 @@ int skill_castend_nodamage_id( struct block_list *src, struct block_list *bl,int
case SA_FROSTWEAPON:
case SA_LIGHTNINGLOADER:
case SA_SEISMICWEAPON:
- if(bl->type==BL_PC) {
- struct map_session_data *sd2 = (struct map_session_data *)bl;
- if (sd2->special_state.no_magic_damage) {
+ if (dstsd) {
+ if (dstsd->special_state.no_magic_damage) {
clif_skill_nodamage(src,bl,skillid,skilllv,0);
break;
}
- if(sd2->status.weapon==0 || (sd && sd->status.party_id > 0 && sd->status.party_id != sd2->status.party_id) ||
- sd2->sc_data[SC_FLAMELAUNCHER].timer!=-1 || sd2->sc_data[SC_FROSTWEAPON].timer!=-1 ||
- sd2->sc_data[SC_LIGHTNINGLOADER].timer!=-1 || sd2->sc_data[SC_SEISMICWEAPON].timer!=-1 ||
- sd2->sc_data[SC_ENCPOISON].timer!=-1) {
+ if(dstsd->status.weapon == 0 ||
+ (sd && sd->status.party_id > 0 && sd->status.party_id != dstsd->status.party_id) ||
+ dstsd->sc_data[SC_FLAMELAUNCHER].timer != -1 ||
+ dstsd->sc_data[SC_FROSTWEAPON].timer != -1 ||
+ dstsd->sc_data[SC_LIGHTNINGLOADER].timer != -1 ||
+ dstsd->sc_data[SC_SEISMICWEAPON].timer != -1 ||
+ dstsd->sc_data[SC_ENCPOISON].timer != -1) {
if (sd) clif_skill_fail(sd,skillid,0,0);
clif_skill_nodamage(src,bl,skillid,skilllv,0);
break;
@@ -3090,14 +3097,12 @@ int skill_castend_nodamage_id( struct block_list *src, struct block_list *bl,int
if(skilllv < 5 && rand()%100 > (60+skilllv*10) ) { //fixed by Lupus (4 -> 5) or else it has 100% success even at lv4
if (sd) clif_skill_fail(sd,skillid,0,0);
clif_skill_nodamage(src,bl,skillid,skilllv,0);
- if(bl->type==BL_PC && battle_config.equipment_breaking) {
- struct map_session_data *sd2 = (struct map_session_data *)bl;
- if(sd && sd != sd2) clif_displaymessage(sd->fd,"You broke target's weapon");
- pc_breakweapon(sd2);
+ if(dstsd && battle_config.equipment_breaking) {
+ if(sd && sd != dstsd) clif_displaymessage(sd->fd,"You broke target's weapon");
+ pc_breakweapon(dstsd);
}
break;
- }
- else {
+ } else {
status_change_start(bl,SkillStatusChangeTable[skillid],skilllv,0,0,0,skill_get_time(skillid,skilllv),0 );
clif_skill_nodamage(src,bl,skillid,skilllv,1);
}
@@ -3105,18 +3110,20 @@ int skill_castend_nodamage_id( struct block_list *src, struct block_list *bl,int
case PR_ASPERSIO: /* アスペルシオ */
clif_skill_nodamage(src,bl,skillid,skilllv,1);
- if( bl->type==BL_PC && ((struct map_session_data *)bl)->special_state.no_magic_damage )
+ if (dstsd && dstsd->special_state.no_magic_damage)
break;
- if(bl->type==BL_MOB)
+ if (dstmd)
break;
status_change_start(bl,SkillStatusChangeTable[skillid],skilllv,0,0,0,skill_get_time(skillid,skilllv),0 );
break;
+
case PR_KYRIE: /* キリエエレイソン */
clif_skill_nodamage(bl,bl,skillid,skilllv,1);
- if( bl->type==BL_PC && ((struct map_session_data *)bl)->special_state.no_magic_damage )
+ if (dstsd && dstsd->special_state.no_magic_damage)
break;
status_change_start(bl,SkillStatusChangeTable[skillid],skilllv,0,0,0,skill_get_time(skillid,skilllv),0 );
break;
+
case KN_AUTOCOUNTER: /* オ?トカウンタ? */
case KN_TWOHANDQUICKEN: /* ツ?ハンドクイッケン */
case CR_SPEARQUICKEN: /* スピアクイッケン */
@@ -3146,6 +3153,7 @@ int skill_castend_nodamage_id( struct block_list *src, struct block_list *bl,int
clif_skill_nodamage(src,bl,skillid,skilllv,1);
status_change_start(bl,SkillStatusChangeTable[skillid],skilllv,0,0,0,skill_get_time(skillid,skilllv),0 );
break;
+
case SM_ENDURE: /* インデュア */
clif_skill_nodamage(src,bl,skillid,skilllv,1);
status_change_start(bl,SkillStatusChangeTable[skillid],skilllv,0,0,0,skill_get_time(skillid,skilllv),0 );
@@ -3156,26 +3164,25 @@ int skill_castend_nodamage_id( struct block_list *src, struct block_list *bl,int
case SM_AUTOBERSERK: // Celest
{
struct status_change *tsc_data = status_get_sc_data(bl);
- int sc=SkillStatusChangeTable[skillid];
+ int sc = SkillStatusChangeTable[skillid];
clif_skill_nodamage(src,bl,skillid,skilllv,1);
- if( tsc_data ){
- if( tsc_data[sc].timer==-1 )
- status_change_start(bl,sc,skilllv,0,0,0,0,0);
- else
- status_change_end(bl, sc, -1);
- }
+ if (tsc_data && tsc_data[sc].timer != -1)
+ status_change_end(bl, sc, -1);
+ else
+ status_change_start(bl,sc,skilllv,0,0,0,0,0);
}
break;
case AS_ENCHANTPOISON: // Prevent spamming [Valaris]
- if(bl->type==BL_PC) {
- struct map_session_data *sd2=(struct map_session_data *)bl;
- if(sd2->sc_data[SC_FLAMELAUNCHER].timer!=-1 || sd2->sc_data[SC_FROSTWEAPON].timer!=-1 ||
- sd2->sc_data[SC_LIGHTNINGLOADER].timer!=-1 || sd2->sc_data[SC_SEISMICWEAPON].timer!=-1 ||
- sd2->sc_data[SC_ENCPOISON].timer!=-1) {
- clif_skill_nodamage(src,bl,skillid,skilllv,0);
- clif_skill_fail(sd,skillid,0,0);
- break;
+ if (dstsd) {
+ if(dstsd->sc_data[SC_FLAMELAUNCHER].timer != -1 ||
+ dstsd->sc_data[SC_FROSTWEAPON].timer != -1 ||
+ dstsd->sc_data[SC_LIGHTNINGLOADER].timer != -1 ||
+ dstsd->sc_data[SC_SEISMICWEAPON].timer != -1 ||
+ dstsd->sc_data[SC_ENCPOISON].timer != -1) {
+ clif_skill_nodamage(src,bl,skillid,skilllv,0);
+ clif_skill_fail(sd,skillid,0,0);
+ break;
}
}
clif_skill_nodamage(src,bl,skillid,skilllv,1);
@@ -3214,8 +3221,7 @@ int skill_castend_nodamage_id( struct block_list *src, struct block_list *bl,int
struct status_change *sc_data = status_get_sc_data(bl);
/* MVPmobと不死には?かない */
- if((bl->type==BL_MOB && status_get_mode(bl)&0x20) || battle_check_undead(status_get_race(bl),status_get_elem_type(bl))) //不死には?かない
- {
+ if((dstmd && status_get_mode(bl)&0x20) || battle_check_undead(status_get_race(bl),status_get_elem_type(bl))) { //不死には?かない
map_freeblock_unlock();
return 1;
}
@@ -3240,8 +3246,6 @@ int skill_castend_nodamage_id( struct block_list *src, struct block_list *bl,int
if(dstmd) {
int range = skill_get_range(skillid,skilllv);
- if(range < 0)
- range = status_get_range(src) - (range + 1);
dstmd->state.provoke_flag = src->id;
mob_target(dstmd,src,range);
}
@@ -3251,27 +3255,27 @@ int skill_castend_nodamage_id( struct block_list *src, struct block_list *bl,int
case CR_DEVOTION: /* ディボ?ション */
if(sd && dstsd){
//?生や養子の場合の元の職業を算出する
- struct pc_base_job dst_s_class = pc_calc_base_job(dstsd->status.class_);
-
- int lv = sd->status.base_level-dstsd->status.base_level;
- lv = (lv<0)?-lv:lv;
- if((dstsd->bl.type!=BL_PC) // 相手はPCじゃないとだめ
- ||(sd->bl.id == dstsd->bl.id) // 相手が自分はだめ
- ||(lv > battle_config.devotion_level_difference) // レベル差±10まで
- ||(!sd->status.party_id && !sd->status.guild_id) // PTにもギルドにも所?無しはだめ
- ||((sd->status.party_id != dstsd->status.party_id) // 同じパ?ティ?か、
- &&(sd->status.guild_id != dstsd->status.guild_id)) // 同じギルドじゃないとだめ
- ||(dst_s_class.job==14||dst_s_class.job==21)){ // クルセだめ
+ int s_class = pc_calc_base_job2 (dstsd->status.class_);
+
+ int lv = sd->status.base_level - dstsd->status.base_level;
+ if (lv < 0) lv = -lv;
+ if ((sd == dstsd) // 相手はPCじゃないとだめ
+ || (sd->bl.id == dstsd->bl.id) // 相手が自分はだめ
+ || (lv > battle_config.devotion_level_difference) // レベル差±10まで
+ || (!sd->status.party_id && !sd->status.guild_id) // PTにもギルドにも所?無しはだめ
+ || ((sd->status.party_id != dstsd->status.party_id) // 同じパ?ティ?か、
+ &&(sd->status.guild_id != dstsd->status.guild_id)) // 同じギルドじゃないとだめ
+ || (s_class == 14 || s_class == 21)) { // クルセだめ
clif_skill_fail(sd,skillid,0,0);
map_freeblock_unlock();
return 1;
}
- for(i=0;i<skilllv;i++){
- if(!sd->dev.val1[i]){ // 空きがあったら入れる
+ for (i = 0; i < skilllv; i++) {
+ if (!sd->dev.val1[i]) { // 空きがあったら入れる
sd->dev.val1[i] = bl->id;
sd->dev.val2[i] = bl->id;
break;
- }else if(i==skilllv-1){ // 空きがなかった
+ } else if (i == skilllv - 1) { // 空きがなかった
clif_skill_fail(sd,skillid,0,0);
map_freeblock_unlock();
return 1;
@@ -3281,30 +3285,34 @@ int skill_castend_nodamage_id( struct block_list *src, struct block_list *bl,int
clif_devotion(sd,bl->id);
status_change_start(bl,SkillStatusChangeTable[skillid],src->id,1,0,0,1000*(15+15*skilllv),0 );
}
- else clif_skill_fail(sd,skillid,0,0);
+ else clif_skill_fail(sd,skillid,0,0);
break;
+
case MO_CALLSPIRITS: // ?功
if(sd) {
clif_skill_nodamage(src,bl,skillid,skilllv,1);
pc_addspiritball(sd,skill_get_time(skillid,skilllv),skilllv);
}
break;
+
case CH_SOULCOLLECT: // 狂?功
if(sd) {
clif_skill_nodamage(src,bl,skillid,skilllv,1);
- for(i=0;i<5;i++)
+ for (i = 0; i < 5; i++)
pc_addspiritball(sd,skill_get_time(skillid,skilllv),5);
}
break;
+
case MO_BLADESTOP: // 白刃取り
clif_skill_nodamage(src,bl,skillid,skilllv,1);
status_change_start(src,SkillStatusChangeTable[skillid],skilllv,0,0,0,skill_get_time(skillid,skilllv),0 );
break;
+
case MO_ABSORBSPIRITS: // ?奪
i=0;
- if(dstsd) {
- if((sd && sd == dstsd) || map[src->m].flag.pvp || map[src->m].flag.gvg) {
- if(dstsd->spiritball > 0) {
+ if (dstsd) {
+ if ((sd && sd == dstsd) || map[src->m].flag.pvp || map[src->m].flag.gvg) {
+ if (dstsd->spiritball > 0) {
clif_skill_nodamage(src,bl,skillid,skilllv,1);
i = dstsd->spiritball * 7;
pc_delspiritball(dstsd,dstsd->spiritball,0);
@@ -3314,14 +3322,14 @@ int skill_castend_nodamage_id( struct block_list *src, struct block_list *bl,int
i = sd->status.max_sp - sd->status.sp;
}
}
- } else if (dstmd){ //?象がモンスタ?の場合
+ } else if (dstmd) { //?象がモンスタ?の場合
//20%の確率で?象のLv*2のSPを回復する。成功したときはタ?ゲット(σ?Д?)σ????!!
- if(rand()%100<20){
- i=2*mob_db[dstmd->class_].lv;
+ if(rand() % 100 < 20) {
+ i = 2 * mob_db[dstmd->class_].lv;
mob_target(dstmd,src,0);
}
}
- if(i && sd){
+ if (i && sd){
sd->status.sp += i;
clif_heal(sd->fd,SP_SP,i);
} else clif_skill_nodamage(src,bl,skillid,skilllv,0);
@@ -3361,11 +3369,10 @@ int skill_castend_nodamage_id( struct block_list *src, struct block_list *bl,int
break;
case BS_HAMMERFALL: /* ハンマ?フォ?ル */
clif_skill_nodamage(src,bl,skillid,skilllv,1);
- if( bl->type==BL_PC && ((struct map_session_data *)bl)->special_state.no_weapon_damage )
+ if(dstsd && dstsd->special_state.no_weapon_damage)
break;
- if( rand()%100 < (20+ 10*skilllv)*sc_def_vit/100 ) {
+ if(rand() % 100 < (20 + 10 * skilllv) * sc_def_vit / 100 )
status_change_start(bl,SC_STAN,skilllv,0,0,0,skill_get_time2(skillid,skilllv),0);
- }
break;
case RG_RAID: /* サプライズアタック */
@@ -3440,30 +3447,29 @@ int skill_castend_nodamage_id( struct block_list *src, struct block_list *bl,int
case PR_MAGNIFICAT: /* マグニフィカ?ト */
case PR_GLORIA: /* グロリア */
case SN_WINDWALK: /* ウインドウォ?ク */
- if(sd == NULL || sd->status.party_id==0 || (flag&1) ){
+ if (sd == NULL || sd->status.party_id == 0 || (flag & 1)) {
/* 個別の?理 */
clif_skill_nodamage(bl,bl,skillid,skilllv,1);
- if( bl->type==BL_PC && ((struct map_session_data *)bl)->special_state.no_magic_damage )
+ if(dstsd && dstsd->special_state.no_magic_damage)
break;
status_change_start(bl,SkillStatusChangeTable[skillid],skilllv,0,0,0,skill_get_time(skillid,skilllv),0);
- }
- else{
+ } else if (sd) {
/* パ?ティ全?への?理 */
- party_foreachsamemap(skill_area_sub,
+ party_foreachsamemap (skill_area_sub,
sd,1,
src,skillid,skilllv,tick, flag|BCT_PARTY|1,
skill_castend_nodamage_id);
}
break;
+
case BS_ADRENALINE: /* アドレナリンラッシュ */
case BS_WEAPONPERFECT: /* ウェポンパ?フェクション */
case BS_OVERTHRUST: /* オ?バ?トラスト */
- if(sd == NULL || sd->status.party_id==0 || (flag&1) ){
+ if (sd == NULL || sd->status.party_id == 0 || (flag & 1)) {
/* 個別の?理 */
clif_skill_nodamage(bl,bl,skillid,skilllv,1);
status_change_start(bl,SkillStatusChangeTable[skillid],skilllv,(src == bl)? 1:0,0,0,skill_get_time(skillid,skilllv),0);
- }
- else{
+ } else if (sd) {
/* パ?ティ全?への?理 */
party_foreachsamemap(skill_area_sub,
sd,1,
@@ -3479,30 +3485,24 @@ int skill_castend_nodamage_id( struct block_list *src, struct block_list *bl,int
case CR_AUTOGUARD: /* オ?トガ?ド */
{
struct status_change *tsc_data = status_get_sc_data(bl);
- int sc=SkillStatusChangeTable[skillid];
+ int sc = SkillStatusChangeTable[skillid];
clif_skill_nodamage(src,bl,skillid,skilllv,1);
- if( tsc_data ){
- if( tsc_data[sc].timer==-1 )
- /* 付加する */
- status_change_start(bl,sc,skilllv,0,0,0,skill_get_time(skillid,skilllv),0);
- else
- /* 解除する */
- status_change_end(bl, sc, -1);
- }
+ if (tsc_data && tsc_data[sc].timer != -1)
+ status_change_end(bl, sc, -1);
+ else
+ status_change_start(bl,sc,skilllv,0,0,0,skill_get_time(skillid,skilllv),0);
}
break;
case TF_HIDING: /* ハイディング */
{
struct status_change *tsc_data = status_get_sc_data(bl);
- int sc=SkillStatusChangeTable[skillid];
+ int sc = SkillStatusChangeTable[skillid];
clif_skill_nodamage(src,bl,skillid,-1,1);
- if(tsc_data && tsc_data[sc].timer!=-1 )
- /* 解除する */
+ if (tsc_data && tsc_data[sc].timer != -1)
status_change_end(bl, sc, -1);
else
- /* 付加する */
- status_change_start(bl,sc,skilllv,0,0,0,skill_get_time(skillid,skilllv),0);
+ status_change_start(bl,sc,skilllv,0,0,0,skill_get_time(skillid,skilllv),0);
}
break;
@@ -3604,7 +3604,7 @@ int skill_castend_nodamage_id( struct block_list *src, struct block_list *bl,int
break;
case RG_STEALCOIN: // スティ?ルコイン
- if(sd) {
+ if(sd) {
if(pc_steal_coin(sd,bl)) {
int range = skill_get_range(skillid,skilllv);
if(range < 0)
@@ -3622,12 +3622,12 @@ int skill_castend_nodamage_id( struct block_list *src, struct block_list *bl,int
struct status_change *sc_data = status_get_sc_data(bl);
// Level 6-10 doesn't consume a red gem if it fails [celest]
int i, gem_flag = 1;
- if (bl->type==BL_MOB && status_get_mode(bl)&0x20) {
+ if (dstmd && status_get_mode(bl)&0x20) {
clif_skill_fail(sd,sd->skillid,0,0);
break;
}
clif_skill_nodamage(src,bl,skillid,skilllv,1);
- if( bl->type==BL_PC && ((struct map_session_data *)bl)->special_state.no_magic_damage )
+ if(dstsd && dstsd->special_state.no_magic_damage )
break;
if (sc_data && sc_data[SC_STONE].timer != -1) {
status_change_end(bl,SC_STONE,-1);
@@ -3701,7 +3701,7 @@ int skill_castend_nodamage_id( struct block_list *src, struct block_list *bl,int
break;
case WZ_ESTIMATION: /* モンスタ?情報 */
- if(src->type==BL_PC){
+ if(sd) {
clif_skill_nodamage(src,bl,skillid,skilllv,1);
clif_skill_estimation((struct map_session_data *)src,bl);
}
@@ -3730,20 +3730,20 @@ int skill_castend_nodamage_id( struct block_list *src, struct block_list *bl,int
break;
case AL_TELEPORT: /* テレポ?ト */
- if( sd ){
- if(map[sd->bl.m].flag.noteleport){ /* テレポ禁止 */
+ if(sd) {
+ if (map[sd->bl.m].flag.noteleport) { /* テレポ禁止 */
clif_skill_teleportmessage(sd,0);
break;
}
clif_skill_nodamage(src,bl,skillid,skilllv,1);
- if( sd->skilllv==1 )
+ if(sd->skilllv == 1)
clif_skill_warppoint(sd,sd->skillid,"Random","","","");
- else{
+ else {
clif_skill_warppoint(sd,sd->skillid,"Random",
sd->status.save_point.map,"","");
}
- }else if( bl->type==BL_MOB )
- mob_warp((struct mob_data *)bl,-1,-1,-1,3);
+ } else if(dstmd)
+ mob_warp(dstmd,-1,-1,-1,3);
break;
case AL_HOLYWATER: /* アクアベネディクタ */
@@ -3827,7 +3827,7 @@ int skill_castend_nodamage_id( struct block_list *src, struct block_list *bl,int
strip_fix = status_get_dex(src) - status_get_dex(bl);
if(strip_fix < 0)
strip_fix=0;
- strip_per = 5+2*skilllv+strip_fix/5;
+ strip_per = 5+5*skilllv+strip_fix/5;
if (rand()%100 >= strip_per)
break;
@@ -3858,7 +3858,7 @@ int skill_castend_nodamage_id( struct block_list *src, struct block_list *bl,int
strip_fix = status_get_dex(src) - status_get_dex(bl);
if(strip_fix < 0)
strip_fix = 0;
- strip_per = 5+2*skilllv+strip_fix/5;
+ strip_per = 5+5*skilllv+strip_fix/5;
if (rand()%100 >= strip_per)
break;
strip_time = skill_get_time(skillid,skilllv)+strip_fix/2;
@@ -3967,7 +3967,7 @@ int skill_castend_nodamage_id( struct block_list *src, struct block_list *bl,int
{
int i;
clif_skill_nodamage(src,bl,skillid,skilllv,1);
- if( bl->type==BL_PC && ((struct map_session_data *)bl)->special_state.no_magic_damage )
+ if(dstsd && dstsd->special_state.no_magic_damage )
break;
for(i=0;i<136;i++){
if(i==SC_RIDING || i== SC_FALCON || i==SC_HALLUCINATION || i==SC_WEIGHT50
@@ -3983,12 +3983,12 @@ int skill_castend_nodamage_id( struct block_list *src, struct block_list *bl,int
case TF_BACKSLIDING: /* バックステップ */
battle_stopwalking(src,1);
skill_blown(src,bl,skill_get_blewcount(skillid,skilllv)|0x10000);
- if(src->type == BL_MOB)
- clif_fixmobpos((struct mob_data *)src);
- else if(src->type == BL_PET)
- clif_fixpetpos((struct pet_data *)src);
- else if(src->type == BL_PC)
+ if (sd)
clif_fixpos(src);
+ else if (md)
+ clif_fixmobpos(md);
+ else if (src->type == BL_PET)
+ clif_fixpetpos((struct pet_data *)src);
skill_addtimerskill(src,tick + 200,src->id,0,0,skillid,skilllv,0,flag);
break;
@@ -4067,7 +4067,7 @@ int skill_castend_nodamage_id( struct block_list *src, struct block_list *bl,int
}
break;
case SA_MAGICROD:
- if( bl->type==BL_PC && ((struct map_session_data *)bl)->special_state.no_magic_damage )
+ if (dstsd && dstsd->special_state.no_magic_damage )
break;
status_change_start(bl,SkillStatusChangeTable[skillid],skilllv,0,0,0,skill_get_time(skillid,skilllv),0 );
break;
@@ -4133,7 +4133,7 @@ int skill_castend_nodamage_id( struct block_list *src, struct block_list *bl,int
case NPC_HALLUCINATION:
clif_skill_nodamage(src,bl,skillid,skilllv,1);
- if( bl->type==BL_PC && ((struct map_session_data *)bl)->special_state.no_magic_damage )
+ if(dstsd && dstsd->special_state.no_magic_damage )
break;
status_change_start(bl,SkillStatusChangeTable[skillid],skilllv,0,0,0,skill_get_time(skillid,skilllv),0 );
break;
@@ -4144,9 +4144,9 @@ int skill_castend_nodamage_id( struct block_list *src, struct block_list *bl,int
int skill_time = skill_get_time(skillid,skilllv);
clif_skill_nodamage(src,bl,skillid,skilllv,1);
status_change_start(bl,SkillStatusChangeTable[skillid],skilllv,0,0,0,skill_time,0 );
- if (src->type == BL_MOB)
- mob_changestate((struct mob_data *)src,MS_DELAY,skill_time);
- else if (src->type == BL_PC)
+ if (md)
+ mob_changestate(md,MS_DELAY,skill_time);
+ else if (sd)
sd->attackabletime = sd->canmove_tick = tick + skill_time;
}
break;
@@ -4155,7 +4155,7 @@ int skill_castend_nodamage_id( struct block_list *src, struct block_list *bl,int
{
int sc_def = 100 - status_get_mdef(bl);
clif_skill_nodamage(src,bl,skillid,skilllv,1);
- if( bl->type==BL_PC && ((struct map_session_data *)bl)->special_state.no_magic_damage )
+ if(dstsd && dstsd->special_state.no_magic_damage )
break;
if(status_get_elem_type(bl) == 7 || status_get_race(bl) == 6)
break;
@@ -4176,10 +4176,11 @@ int skill_castend_nodamage_id( struct block_list *src, struct block_list *bl,int
break;
case NPC_LICK:
clif_skill_nodamage(src,bl,skillid,skilllv,1);
- if( bl->type==BL_PC && ((struct map_session_data *)bl)->special_state.no_weapon_damage )
- break;
- if(dstsd)
+ if (dstsd) {
+ if (dstsd->special_state.no_weapon_damage )
+ break;
pc_heal(dstsd,0,-100);
+ }
if(rand()%100 < (skilllv*5)*sc_def_vit/100)
status_change_start(bl,SC_STAN,skilllv,0,0,0,skill_get_time2(skillid,skilllv),0);
break;
@@ -4200,6 +4201,57 @@ int skill_castend_nodamage_id( struct block_list *src, struct block_list *bl,int
mob_summonslave(md,mob_db[md->class_].skill[md->skillidx].val,skilllv,(skillid==NPC_SUMMONSLAVE)?1:0);
break;
+ case NPC_RECALL: //取り巻き呼び戻し
+ if(md) {
+ int mobcount;
+ md->recallcount = 0;//初期化
+ md->recall_flag = 0;
+ mobcount = mob_countslave(md);
+ if(mobcount > 0) {
+ md->recall_flag = 1; //mob.cの[取り巻きモンスターの処理]で利用
+ md->recallmob_count = mobcount;
+ }
+ }
+ break;
+
+ case NPC_RUNAWAY: //後退
+ if(md) {
+ int check;
+ int dist = skilllv;//後退する距離
+ check = md->dir; //自分がどの方向に向いてるかチェック
+ md->attacked_id = 0;
+ md->target_id = 0;
+ md->state.targettype = NONE_ATTACKABLE;
+ md->state.skillstate = MSS_IDLE;
+ switch (check) {
+ case 0: //自分の向いてる方向と逆に移動する
+ mob_walktoxy(md,md->bl.x,md->bl.y-dist,0);//そして、移動する
+ break;
+ case 1:
+ mob_walktoxy(md,md->bl.x-dist,md->bl.y-dist,0);
+ break;
+ case 2:
+ mob_walktoxy(md,md->bl.x+dist,md->bl.y,0);
+ break;
+ case 3:
+ mob_walktoxy(md,md->bl.x+dist,md->bl.y+dist,0);
+ break;
+ case 4:
+ mob_walktoxy(md,md->bl.x,md->bl.y+dist,0);
+ break;
+ case 5:
+ mob_walktoxy(md,md->bl.x-dist,md->bl.y+dist,0);
+ break;
+ case 6:
+ mob_walktoxy(md,md->bl.x-dist,md->bl.y,0);
+ break;
+ case 7:
+ mob_walktoxy(md,md->bl.x-dist,md->bl.y-dist,0);
+ break;
+ }
+ }
+ break;
+
case NPC_TRANSFORMATION:
case NPC_METAMORPHOSIS:
if(md)
@@ -4218,25 +4270,25 @@ int skill_castend_nodamage_id( struct block_list *src, struct block_list *bl,int
// Equipment breaking monster skills [Celest]
case NPC_BREAKWEAPON:
clif_skill_nodamage(src,bl,skillid,skilllv,1);
- if(bl->type == BL_PC && battle_config.equipment_breaking)
+ if(dstsd && battle_config.equipment_breaking)
pc_breakweapon(dstsd);
break;
case NPC_BREAKARMOR:
clif_skill_nodamage(src,bl,skillid,skilllv,1);
- if(bl->type == BL_PC && battle_config.equipment_breaking)
+ if(dstsd && battle_config.equipment_breaking)
pc_breakarmor(dstsd);
break;
case NPC_BREAKHELM:
clif_skill_nodamage(src,bl,skillid,skilllv,1);
- if(bl->type == BL_PC && battle_config.equipment_breaking)
+ if(dstsd && battle_config.equipment_breaking)
pc_breakhelm(dstsd);
break;
case NPC_BREAKSHIELD:
clif_skill_nodamage(src,bl,skillid,skilllv,1);
- if(bl->type == BL_PC && battle_config.equipment_breaking)
+ if(dstsd && battle_config.equipment_breaking)
pc_breakshield(dstsd);
break;
@@ -4384,7 +4436,7 @@ int skill_castend_nodamage_id( struct block_list *src, struct block_list *bl,int
struct status_change *sc_data = status_get_sc_data(bl);
/* MVPmobと不死には?かない */
- if((bl->type==BL_MOB && status_get_mode(bl)&0x20) || battle_check_undead(status_get_race(bl),status_get_elem_type(bl))) //不死には?かない
+ if((dstmd && status_get_mode(bl)&0x20) || battle_check_undead(status_get_race(bl),status_get_elem_type(bl))) //不死には?かない
{
map_freeblock_unlock();
return 1;
@@ -4408,12 +4460,8 @@ int skill_castend_nodamage_id( struct block_list *src, struct block_list *bl,int
status_change_end(bl,SC_SLEEP,-1);
}
- if(bl->type==BL_MOB) {
- int range = skill_get_range(skillid,skilllv);
- if(range < 0)
- range = status_get_range(src) - (range + 1);
- mob_target((struct mob_data *)bl,src,range);
- }
+ if(dstmd)
+ mob_target(dstmd,src,skill_get_range(skillid,skilllv));
}
break;
@@ -4814,13 +4862,20 @@ int skill_castend_pos2( struct block_list *src, int x,int y,int skillid,int skil
break;
case BS_HAMMERFALL: /* ハンマ?フォ?ル */
- skill_area_temp[1]=src->id;
- skill_area_temp[2]=x;
- skill_area_temp[3]=y;
- map_foreachinarea(skill_area_sub,
- src->m,x-2,y-2,x+2,y+2,0,
- src,skillid,skilllv,tick, flag|BCT_ENEMY|2,
- skill_castend_nodamage_id);
+ {
+ int r = 2;
+ if (skilllv > 5) {
+ r = 14;
+ skilllv = 5; // スタン率上がりすぎるため計算はLv5で固定
+ }
+ skill_area_temp[1] = src->id;
+ skill_area_temp[2] = x;
+ skill_area_temp[3] = y;
+ map_foreachinarea (skill_area_sub,
+ src->m, x-r, y-r, x+r, y+r, 0,
+ src, skillid, skilllv, tick, flag|BCT_ENEMY|2,
+ skill_castend_nodamage_id);
+ }
break;
case HT_DETECTING: /* ディテクティング */
@@ -4933,49 +4988,39 @@ int skill_castend_pos2( struct block_list *src, int x,int y,int skillid,int skil
pc_blockskill_start (sd, MO_EXTREMITYFIST, 2000);
break;
case AM_CANNIBALIZE: // バイオプラント
- if(sd){
- int mx,my,amount=6-skilllv,id=0;
+ if(sd) {
+ int id;
int summons[5] = { 1020, 1068, 1118, 1500, 1368 };
-
struct mob_data *md;
- for (i=0; i<amount; i++) { //Amount: 1 lev = 1 mob, 2=2, 3, 4, 5 [Lupus]
- mx = x;
- my = y;
- while (i && mx == x ) {
- mx += (rand()%(1+amount) - (1+amount)/2);
- }
- while (i && my == y) {
- my += (rand()%(1+amount) - (1+amount)/2);
- }
- id=mob_once_spawn(sd,"this",mx,my,"--ja--", summons[skilllv-1] ,1,"");
+ // Correct info, don't change any of this! [celest]
+ id = mob_once_spawn (sd, "this", x, y, "--ja--", summons[skilllv-1] ,1,"");
- if( (md=(struct mob_data *)map_id2bl(id)) !=NULL ){
- md->master_id=sd->bl.id;
- //md->hp=2210+skilllv*200; commented out, we use REAL hp of the mobs [Lupus]
- md->state.special_mob_ai=1;
- md->deletetimer=add_timer(gettick()+skill_get_time(skillid,skilllv),mob_timer_delete,id,0);
- }
- }
- //block skill
- //i can't check if the summoned mobs are dead.. to be able summon next... so i just disable skill [Lupus]
- pc_blockskill_start (sd, AM_CANNIBALIZE, skill_get_time(skillid,skilllv));
+ if( (md=(struct mob_data *)map_id2bl(id)) !=NULL ){
+ md->master_id = sd->bl.id;
+ // different levels of HP according to skill level
+ md->hp = 1500 + skilllv * 200 + sd->status.base_level * 10;
+ md->state.special_mob_ai = 1;
+ //非移動でアクティブで反撃する[0x0:非移動 0x1:移動 0x4:ACT 0x8:非ACT 0x40:反撃無 0x80:反撃有]
+ md->mode = 0x0 + 0x4 + 0x80;
+ md->deletetimer = add_timer (gettick() + skill_get_time(skillid,skilllv), mob_timer_delete, id, 0);
+ }
+ // To-do: 召還されるモンスターには召還したプレーヤーの名前が付きます
+ // (attach name of player?)
clif_skill_poseffect(src,skillid,skilllv,x,y,tick);
}
break;
case AM_SPHEREMINE: // スフィア?マイン
if(sd){
- int mx,my,id=0;
+ int id;
struct mob_data *md;
- mx = x;// + (rand()%10 - 5);
- my = y;// + (rand()%10 - 5);
- id=mob_once_spawn(sd,"this",mx,my,"--ja--",1142,1,"");
+ id = mob_once_spawn(sd, "this", x, y, "--ja--", 1142, 1, "");
if( (md=(struct mob_data *)map_id2bl(id)) !=NULL ){
- md->master_id=sd->bl.id;
- md->hp=2000+skilllv*400;
- md->state.special_mob_ai=2;
- md->deletetimer=add_timer(gettick()+skill_get_time(skillid,skilllv),mob_timer_delete,id,0);
+ md->master_id = sd->bl.id;
+ md->hp = 2000 + skilllv * 400;
+ md->state.special_mob_ai = 2;
+ md->deletetimer = add_timer (gettick() + skill_get_time(skillid,skilllv), mob_timer_delete, id, 0);
}
clif_skill_poseffect(src,skillid,skilllv,x,y,tick);
}
@@ -5172,6 +5217,14 @@ struct skill_unit_group *skill_unitsetting( struct block_list *src, int skillid,
if(skilllv >= 6)
range=2;
break;
+ case WZ_METEOR:
+ if (skilllv > 10) //広範囲メテオ
+ range = 10;
+ break;
+ case WZ_VERMILION:
+ if (skilllv > 10) //広範囲LOV
+ range = 25;
+ break;
case HT_SANDMAN: /* サンドマン */
case HT_CLAYMORETRAP: /* クレイモア?トラップ */
@@ -5783,7 +5836,13 @@ int skill_unit_onout(struct skill_unit *src,struct block_list *bl,unsigned int t
case 0xac: /* ハミング */
case 0xae: /* 幸運のキス */
case 0xaf: /* サ?ビスフォ?ユ? */
- status_change_start(bl,SkillStatusChangeTable[sg->skill_id],sg->skill_lv,0,0,0,20000,0 );
+ if (sg->src_id==bl->id) {
+ status_change_end(bl,type,-1);
+ break;
+ }
+ if (sc_data[type].timer!=-1 && sc_data[type].val4==(int)src) {
+ sc_data[type].timer = add_timer(20000+tick, status_change_timer, bl->id, type);
+ }
break;
case 0xb4: // Basilica
@@ -5833,6 +5892,7 @@ int skill_unit_effect(struct block_list *bl,va_list ap)
struct skill_unit_group *group;
int flag;
unsigned int tick;
+ static int called = 0;
nullpo_retr(0, bl);
nullpo_retr(0, ap);
@@ -5853,8 +5913,11 @@ int skill_unit_effect(struct block_list *bl,va_list ap)
else {
skill_unit_onout(unit,bl,tick);
unit = map_find_skill_unit_oncell(bl,bl->x,bl->y,group->skill_id,unit);
- if (unit)
+ if (unit && called == 0) {
+ called = 1;
skill_unit_onplace(unit,bl,tick);
+ called = 0;
+ }
}
return 0;
@@ -9059,6 +9122,23 @@ void skill_init_unit_layout()
memcpy(skill_unit_layout[pos].dy,dy,sizeof(dy));
break;
}
+ case PA_GOSPEL:
+ {
+ static const int dx[] = {
+ -1, 0, 1,-1, 0, 1,-3,-2,-1, 0,
+ 1, 2, 3,-3,-2,-1, 0, 1, 2, 3,
+ -3,-2,-1, 0, 1, 2, 3,-1, 0, 1,
+ -1, 0, 1};
+ static const int dy[] = {
+ -3,-3,-3,-2,-2,-2,-1,-1,-1,-1,
+ -1,-1,-1, 0, 0, 0, 0, 0, 0, 0,
+ 1, 1, 1, 1, 1, 1, 1, 2, 2, 2,
+ 3, 3, 3};
+ skill_unit_layout[pos].count = 33;
+ memcpy(skill_unit_layout[pos].dx,dx,sizeof(dx));
+ memcpy(skill_unit_layout[pos].dy,dy,sizeof(dy));
+ break;
+ }
default:
printf("unknown unit layout at skill %d\n",i);
break;
diff --git a/src/map/skill.h b/src/map/skill.h
index 4c0d0a8f7..91fe376b4 100644
--- a/src/map/skill.h
+++ b/src/map/skill.h
@@ -573,9 +573,13 @@ enum {
NPC_BREAKHELM,
NPC_BREAKSHIELD,
NPC_UNDEADATTACK,
- NPC_EXPLOSIONSPIRITS = 349,
+
+ NPC_RUNAWAY = 348,
+ NPC_EXPLOSIONSPIRITS,
NPC_INCAGI,
+ NPC_RECALL = 354,
+
LK_AURABLADE = 355,
LK_PARRYING,
LK_CONCENTRATION,
diff --git a/src/map/status.c b/src/map/status.c
index bc059e442..65f9e0cd4 100644
--- a/src/map/status.c
+++ b/src/map/status.c
@@ -3189,18 +3189,18 @@ int status_change_start(struct block_list *bl,int type,int val1,int val2,int val
return 0;
if(bl->type == BL_PC)
if(pc_checkskill(sd,BS_HILTBINDING)>0)
- tick *= 1.1;
+ tick += tick / 10;
calc_flag = 1;
break;
case SC_WEAPONPERFECTION: /* ウェポンパ?フェクション */
if(bl->type == BL_PC)
if(pc_checkskill(sd,BS_HILTBINDING)>0)
- tick *= 1.1;
+ tick += tick / 10;
break;
case SC_OVERTHRUST: /* オ?バ?スラスト */
if(bl->type == BL_PC)
if(pc_checkskill(sd,BS_HILTBINDING)>0)
- tick *= 1.1;
+ tick += tick / 10;
*opt3 |= 2;
break;
case SC_MAXIMIZEPOWER: /* マキシマイズパワ?(SPが1減る時間,val2にも) */
@@ -3563,6 +3563,11 @@ int status_change_start(struct block_list *bl,int type,int val1,int val2,int val
tick = 1000;
break;
case SC_SILENCE: /* 沈?(レックスデビ?ナ) */
+ if (sc_data && sc_data[SC_GOSPEL].timer!=-1) {
+ skill_delunitgroup((struct skill_unit_group *)sc_data[SC_GOSPEL].val3);
+ status_change_end(bl,SC_GOSPEL,-1);
+ break;
+ }
if(!(flag&2)) {
int sc_def = 100 - status_get_vit(bl);
tick = tick * sc_def / 100;
diff --git a/src/map/status.h b/src/map/status.h
index a23394d6a..6c026081e 100644
--- a/src/map/status.h
+++ b/src/map/status.h
@@ -259,6 +259,7 @@ int status_getrefinebonus(int lv,int type);
int status_percentrefinery(struct map_session_data *sd,struct item *item);
extern int percentrefinery[5][10];
+int status_readdb(void);
int do_init_status(void);
#endif