summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorcelest <celest@54d463be-8e91-2dee-dedb-b68131a5f0ec>2004-12-15 19:37:40 +0000
committercelest <celest@54d463be-8e91-2dee-dedb-b68131a5f0ec>2004-12-15 19:37:40 +0000
commit51ca6fafbdf5e9840aab1859d99be5738cfd7571 (patch)
tree5ab199ac5fce61d8c086fc15c345065363f0d493
parent4e003aea5ffaa764bf0e40a63ea314c56903fda0 (diff)
downloadhercules-51ca6fafbdf5e9840aab1859d99be5738cfd7571.tar.gz
hercules-51ca6fafbdf5e9840aab1859d99be5738cfd7571.tar.bz2
hercules-51ca6fafbdf5e9840aab1859d99be5738cfd7571.tar.xz
hercules-51ca6fafbdf5e9840aab1859d99be5738cfd7571.zip
* Updated Forging and Potion making formulas
* Modified guild skills * Initialise 'canregen' when logging into map - Updated Steel Body, Thunderstorm, Investigate and Magic Crasher - Removed elunium and oridecon from produce_db git-svn-id: https://rathena.svn.sourceforge.net/svnroot/rathena/branches/stable@575 54d463be-8e91-2dee-dedb-b68131a5f0ec
-rw-r--r--Changelog.txt10
-rw-r--r--db/Changelog.txt4
-rw-r--r--db/produce_db.txt2
-rw-r--r--db/skill_cast_db.txt2
-rw-r--r--db/skill_db.txt4
-rw-r--r--db/skill_require_db.txt2
-rw-r--r--db/skill_tree.txt2
-rw-r--r--src/map/map.h4
-rw-r--r--src/map/pc.c64
-rw-r--r--src/map/skill.c159
-rw-r--r--src/map/skill.h4
11 files changed, 153 insertions, 104 deletions
diff --git a/Changelog.txt b/Changelog.txt
index 9a048ad7e..dd81c3ec0 100644
--- a/Changelog.txt
+++ b/Changelog.txt
@@ -1,4 +1,14 @@
Date Added
+12/16
+ * Updated Forging and Potion making formulas by DracoRPG [celest]
+ * Changes to the guild skills
+ - Dropped using sc_data and use flag values instead
+ - Changed moving guild skill units to once every 'move request' only instead
+ of every movement - should reduce server load abit
+ - Corrected crash when checking its skill requirements
+ * Initialise 'canregen' when logging into map - forgot to add this earlier,
+ sorry ^^; [celest]
+
12/15
* Fixed more compile errors gcc 2.95 [MouseJstr]
* Removed log files from svn... they will be created when
diff --git a/db/Changelog.txt b/db/Changelog.txt
index 2c8794a48..f7547db3a 100644
--- a/db/Changelog.txt
+++ b/db/Changelog.txt
@@ -5,6 +5,10 @@
Ayathoya items == Added but no effect ( all are "ect" itens)
Skill databases == celest working on them i believe.
+12/15 * Updated Steel Body, Thunderstorm, Investigate and Magic Crasher, thanks
+ to midas
+ * Removed elunium and oridecon from produce_db, thanks to Draco
+
12/14 * Changed 'Parasite' to non-moving [celest]
12/12 * Removed unuseable skills from skill_tree.txt [celest]
diff --git a/db/produce_db.txt b/db/produce_db.txt
index 9eb918afe..82c708dda 100644
--- a/db/produce_db.txt
+++ b/db/produce_db.txt
@@ -9,8 +9,6 @@
995,16,96,991,10
997,16,96,993,10
996,16,96,992,10
-984,16,97,756,3,1003,1
-985,16,97,757,3,1003,1
// Weapon ItemLV=wLV
1101,1,99,998,2
1104,1,99,998,30
diff --git a/db/skill_cast_db.txt b/db/skill_cast_db.txt
index 777d186f6..bf977a8fb 100644
--- a/db/skill_cast_db.txt
+++ b/db/skill_cast_db.txt
@@ -166,7 +166,7 @@
266,1000,500,0,0 //MO_INVESTIGATE#発勁#
267,1000,500,0,0 //MO_FINGEROFFENSIVE#指弾#
-268,0,0,30000:60000:90000:120000:150000,0 //MO_STEELBODY#金剛#
+268,5000,0,30000:60000:90000:120000:150000,0 //MO_STEELBODY#金剛#
269,0,0,500:700:900:1100:1300,20000:30000:40000:50000:60000 //MO_BLADESTOP#白刃取り#
270,0,0,180000,0 //MO_EXPLOSIONSPIRITS#爆裂波動#
271,4000:3500:3000:2500:2000,3000:2500:2000:1500:1000,0,300000 //MO_EXTREMITYFIST#阿修羅覇凰拳#
diff --git a/db/skill_db.txt b/db/skill_db.txt
index f9e28f3c2..3b99cebaa 100644
--- a/db/skill_db.txt
+++ b/db/skill_db.txt
@@ -20,7 +20,7 @@
18,8,6,2,3,0,10,1,yes,0,0,3,magic,2 //MG_FIREWALL#フ?イア?ウォ?ル#
19,8,8,1,3,0,10,1:2:3:4:5:6:7:8:9:10,yes,0,0,0,magic,0 //MG_FIREBOLT#フ?イア??ルト#
20,8,8,1,4,0,10,1:2:3:4:5:6:7:8:9:10,yes,0,0,0,magic,0 //MG_LIGHTNINGBOLT#ライトニング?ルト#
-21,5,8,2,4,0,10,1:2:3:4:5:6:7:8:9:10,yes,0,0,0,magic,0 //MG_THUNDERSTORM#サン??スト??#
+21,8,8,2,4,0,10,1:2:3:4:5:6:7:8:9:10,yes,0,0,0,magic,0 //MG_THUNDERSTORM#サン??スト??#
22,0,0,0,0,0,10,0,no,0,0,0,weapon,0 //AL_DP#ディバインプロテクション#
23,0,0,0,0,0,10,0,no,0,0,0,weapon,0 //AL_DEMONBANE#デ?モンベイン#
24,8,6,4,0,1,1,1,yes,0,0,0,magic,0 //AL_RUWACH#ルアフ#
@@ -316,7 +316,7 @@
263,0,8,0,0,0,10,3,no,0,0,0,weapon,0 //MO_TRIPLEATTACK#三段掌#
264,50,6,2,0,1,1,1,no,0,0,0,none,0 //MO_BODYRELOCATION#残影#
265,0,0,0,0,0,10,0,no,0,0,0,weapon,0 //MO_DODGE#見切り#
-266,-1,6,1,0,0,5,1,no,0,0,0,weapon,0 //MO_INVESTIGATE#発勁#
+266,8,6,1,0,0,5,1,no,0,0,0,weapon,0 //MO_INVESTIGATE#発勁#
267,10,8,1,0,0,5,1:2:3:4:5,no,0,0,0,weapon,0 //MO_FINGEROFFENSIVE#指弾#
268,0,6,4,0,1,5,1,no,0,0,0,weapon,0 //MO_STEELBODY#金剛#
269,0,6,4,0,1,5,1,no,0,0,0,weapon,0 //MO_BLADESTOP#白刃取り#
diff --git a/db/skill_require_db.txt b/db/skill_require_db.txt
index 5cd9d73b4..a53a29791 100644
--- a/db/skill_require_db.txt
+++ b/db/skill_require_db.txt
@@ -250,7 +250,7 @@
361,0,0,25:30:35:40:45,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 //HP_ASSUMPTIO#アスムプティオ#
362,0,0,80:90:100:110:120,0,0,0,99,none,0,715,1,716,1,717,1,523,1,0,0,0,0,0,0,0,0,0,0,0,0 //HP_BASILICA#バジリカ#
-365,0,0,12,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 //HW_MAGICCRASHER#マジッククラッシャ?#
+365,0,0,8,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 //HW_MAGICCRASHER#マジッククラッシャ?#
366,0,0,14:18:22:26:30:34:38:42:46:50,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 //HW_MAGICPOWER#魔法力?幅#
367,0,0,30:35:40:45:50,0,20:25:30:35:40,0,99,none,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0 //PA_PRESSURE#プレッシャ?#
368,0,9,100,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 //PA_SACRIFICE#サクリファイス#
diff --git a/db/skill_tree.txt b/db/skill_tree.txt
index 8028e0d4c..ce51ec729 100644
--- a/db/skill_tree.txt
+++ b/db/skill_tree.txt
@@ -795,7 +795,7 @@
4010,92,5,14,1,91,1,0,0,0,0,0,0//WZ_QUAGMIRE #クァグマイア#
4010,93,1,0,0,0,0,0,0,0,0,0,0//WZ_ESTIMATION #モンスター情報#
4010,364,10,9,5,13,7,0,0,0,0,0,0//HW_SOULDRAIN #基本スキル#
-4010,365,10,9,1,0,0,0,0,0,0,0,0//HW_MAGICCRASHER #基本スキル#
+4010,365,1,9,1,0,0,0,0,0,0,0,0//HW_MAGICCRASHER #基本スキル#
4010,366,10,0,0,0,0,0,0,0,0,0,0//HW_MAGICPOWER #基本スキル#
4010,400,5,11,5,0,0,0,0,0,0,0,0//HW_NAPALMVULCAN
//Whitesmith
diff --git a/src/map/map.h b/src/map/map.h
index 060bfb451..6d525c117 100644
--- a/src/map/map.h
+++ b/src/map/map.h
@@ -138,6 +138,10 @@ struct map_session_data {
unsigned potionpitcher_flag : 1;
unsigned storage_flag : 1;
unsigned snovice_flag : 4;
+ int leadership_flag;
+ int glorywounds_flag;
+ int soulcold_flag;
+ int hawkeyes_flag;
} state;
struct {
unsigned killer : 1;
diff --git a/src/map/pc.c b/src/map/pc.c
index 9c6e777ca..8e7f607ce 100644
--- a/src/map/pc.c
+++ b/src/map/pc.c
@@ -709,6 +709,7 @@ int pc_authok(int id, int login_id2, time_t connect_until_time, struct mmo_chars
sd->inchealspiritsptick = 0;
sd->canact_tick = tick;
sd->canmove_tick = tick;
+ sd->canregen_tick = tick;
sd->attackabletime = tick;
sd->doridori_counter = 0;
@@ -1477,37 +1478,33 @@ int pc_calcstatus(struct map_session_data* sd,int first)
if (sd->status.guild_id > 0) {
struct guild *g;
if ((g = guild_search(sd->status.guild_id)) && strcmp(sd->status.name,g->master)==0) {
- if (!sd->sc_data[SC_LEADERSHIP].val4 && guild_checkskill(g, GD_LEADERSHIP)>0) {
- //skill_status_change_start(&sd->bl,SC_LEADERSHIP,1,0,0,0,0,0 );
+ if (!sd->state.leadership_flag && guild_checkskill(g, GD_LEADERSHIP)>0) {
skill_unitsetting(&sd->bl,GD_LEADERSHIP,1,sd->bl.x,sd->bl.y,0);
}
- if (!sd->sc_data[SC_GLORYWOUNDS].val4 && guild_checkskill(g, GD_GLORYWOUNDS)>0) {
- //skill_status_change_start(&sd->bl,SC_GLORYWOUNDS,1,0,0,0,0,0 );
+ if (!sd->state.glorywounds_flag && guild_checkskill(g, GD_GLORYWOUNDS)>0) {
skill_unitsetting(&sd->bl,GD_GLORYWOUNDS,1,sd->bl.x,sd->bl.y,0);
}
- if (!sd->sc_data[SC_SOULCOLD].val4 && guild_checkskill(g, GD_SOULCOLD)>0) {
- //skill_status_change_start(&sd->bl,SC_SOULCOLD,1,0,0,0,0,0 );
+ if (!sd->state.soulcold_flag && guild_checkskill(g, GD_SOULCOLD)>0) {
skill_unitsetting(&sd->bl,GD_SOULCOLD,1,sd->bl.x,sd->bl.y,0);
}
- if (!sd->sc_data[SC_HAWKEYES].val4 && guild_checkskill(g, GD_HAWKEYES)>0) {
- //skill_status_change_start(&sd->bl,SC_HAWKEYES,1,0,0,0,0,0 );
+ if (!sd->state.hawkeyes_flag && guild_checkskill(g, GD_HAWKEYES)>0) {
skill_unitsetting(&sd->bl,GD_HAWKEYES,1,sd->bl.x,sd->bl.y,0);
}
}
- else if (sd->sc_count) {
- if (sd->sc_data[SC_LEADERSHIP].timer != -1)
- sd->paramb[0] += 2;
- if (sd->sc_data[SC_GLORYWOUNDS].timer != -1)
- sd->paramb[2] += 2;
- if (sd->sc_data[SC_SOULCOLD].timer != -1)
- sd->paramb[1] += 2;
- if (sd->sc_data[SC_HAWKEYES].timer != -1)
- sd->paramb[4] += 2;
- if (sd->sc_data[SC_BATTLEORDERS].timer != -1) {
+ else if (g) {
+ if (sd->sc_count && sd->sc_data[SC_BATTLEORDERS].timer != -1) {
sd->paramb[0]+= 5;
sd->paramb[3]+= 5;
sd->paramb[4]+= 5;
}
+ if (sd->state.leadership_flag)
+ sd->paramb[0] += 2;
+ if (sd->state.glorywounds_flag)
+ sd->paramb[2] += 2;
+ if (sd->state.soulcold_flag)
+ sd->paramb[1] += 2;
+ if (sd->state.hawkeyes_flag)
+ sd->paramb[4] += 2;
}
}
@@ -4207,17 +4204,26 @@ int pc_walktoxy(struct map_session_data *sd,int x,int y)
if (sd->sc_data && sd->status.guild_id > 0) {
struct skill_unit *su;
- if (sd->sc_data[SC_LEADERSHIP].val4 && (su=(struct skill_unit *)sd->sc_data[SC_LEADERSHIP].val4)) {
- skill_unit_move_unit_group(su->group,sd->bl.m,(x - sd->bl.x),(y - sd->bl.y));
- }
- if (sd->sc_data[SC_GLORYWOUNDS].val4 && (su=(struct skill_unit *)sd->sc_data[SC_GLORYWOUNDS].val4)) {
- skill_unit_move_unit_group(su->group,sd->bl.m,(x - sd->bl.x),(y - sd->bl.y));
- }
- if (sd->sc_data[SC_SOULCOLD].val4 && (su=(struct skill_unit *)sd->sc_data[SC_SOULCOLD].val4)) {
- skill_unit_move_unit_group(su->group,sd->bl.m,(x - sd->bl.x),(y - sd->bl.y));
- }
- if (sd->sc_data[SC_HAWKEYES].val4 && (su=(struct skill_unit *)sd->sc_data[SC_HAWKEYES].val4)) {
- skill_unit_move_unit_group(su->group,sd->bl.m,(x - sd->bl.x),(y - sd->bl.y));
+ struct skill_unit_group *sg;
+ //if (sd->sc_data[SC_LEADERSHIP].val4 && (su=(struct skill_unit *)sd->sc_data[SC_LEADERSHIP].val4)) {
+ if (sd->state.leadership_flag && (su=(struct skill_unit *)sd->state.leadership_flag) &&
+ (sg=su->group) && sg->src_id == sd->bl.id) {
+ skill_unit_move_unit_group(sg,sd->bl.m,(x - sd->bl.x),(y - sd->bl.y));
+ }
+ //if (sd->sc_data[SC_GLORYWOUNDS].val4 && (su=(struct skill_unit *)sd->sc_data[SC_GLORYWOUNDS].val4)) {
+ if (sd->state.glorywounds_flag && (su=(struct skill_unit *)sd->state.glorywounds_flag) &&
+ (sg=su->group) && sg->src_id == sd->bl.id) {
+ skill_unit_move_unit_group(sg,sd->bl.m,(x - sd->bl.x),(y - sd->bl.y));
+ }
+ //if (sd->sc_data[SC_SOULCOLD].val4 && (su=(struct skill_unit *)sd->sc_data[SC_SOULCOLD].val4)) {
+ if (sd->state.soulcold_flag && (su=(struct skill_unit *)sd->state.soulcold_flag) &&
+ (sg=su->group) && sg->src_id == sd->bl.id) {
+ skill_unit_move_unit_group(sg,sd->bl.m,(x - sd->bl.x),(y - sd->bl.y));
+ }
+ //if (sd->sc_data[SC_HAWKEYES].val4 && (su=(struct skill_unit *)sd->sc_data[SC_HAWKEYES].val4)) {
+ if (sd->state.hawkeyes_flag && (su=(struct skill_unit *)sd->state.hawkeyes_flag) &&
+ (sg=su->group) && sg->src_id == sd->bl.id) {
+ skill_unit_move_unit_group(sg,sd->bl.m,(x - sd->bl.x),(y - sd->bl.y));
}
}
diff --git a/src/map/skill.c b/src/map/skill.c
index cb4b37fad..740caf777 100644
--- a/src/map/skill.c
+++ b/src/map/skill.c
@@ -5573,7 +5573,7 @@ struct skill_unit_group *skill_unitsetting( struct block_list *src, int skillid,
case GD_HAWKEYES:
range=2;
target=BCT_ALL;
- limit=60000;
+ limit=300000;
break;
default:
@@ -5828,16 +5828,32 @@ struct skill_unit_group *skill_unitsetting( struct block_list *src, int skillid,
sc_data[SC_BASILICA].val4 = (int)unit;
break;
case GD_LEADERSHIP:
- sc_data[SC_LEADERSHIP].val4 = (int)unit;
+ {
+ struct map_session_data *sd = (struct map_session_data *)src;
+ if (sd)
+ sd->state.leadership_flag = (int)unit;
+ }
break;
case GD_GLORYWOUNDS:
- sc_data[SC_GLORYWOUNDS].val4 = (int)unit;
+ {
+ struct map_session_data *sd = (struct map_session_data *)src;
+ if (sd)
+ sd->state.glorywounds_flag = (int)unit;
+ }
break;
case GD_SOULCOLD:
- sc_data[SC_SOULCOLD].val4 = (int)unit;
+ {
+ struct map_session_data *sd = (struct map_session_data *)src;
+ if (sd)
+ sd->state.soulcold_flag = (int)unit;
+ }
break;
case GD_HAWKEYES:
- sc_data[SC_HAWKEYES].val4 = (int)unit;
+ {
+ struct map_session_data *sd = (struct map_session_data *)src;
+ if (sd)
+ sd->state.hawkeyes_flag = (int)unit;
+ }
break;
}
}
@@ -6234,8 +6250,10 @@ int skill_unit_onplace(struct skill_unit *src,struct block_list *bl,unsigned int
struct map_session_data *sd;
if (srcsd && bl->type == BL_PC && (sd=(struct map_session_data *)bl) &&
sd->status.guild_id == srcsd->status.guild_id &&
- sd->sc_data[SC_LEADERSHIP].timer == -1 && !sd->sc_data[SC_LEADERSHIP].val4)
- skill_status_change_start(bl,SC_LEADERSHIP,1,0,0,0,0,0 );
+ sd != srcsd) {
+ sd->state.leadership_flag = (int)src;
+ pc_calcstatus (sd, 0);
+ }
}
break;
case 0xc2: // GD_GLORYWOUNDS
@@ -6243,8 +6261,10 @@ int skill_unit_onplace(struct skill_unit *src,struct block_list *bl,unsigned int
struct map_session_data *sd;
if (srcsd && bl->type == BL_PC && (sd=(struct map_session_data *)bl) &&
sd->status.guild_id == srcsd->status.guild_id &&
- sd->sc_data[SC_GLORYWOUNDS].timer == -1 && !sd->sc_data[SC_GLORYWOUNDS].val4)
- skill_status_change_start(bl,SC_GLORYWOUNDS,1,0,0,0,0,0 );
+ sd != srcsd) {
+ sd->state.glorywounds_flag = (int)src;
+ pc_calcstatus (sd, 0);
+ }
}
break;
case 0xc3: // GD_SOULCOLD
@@ -6252,8 +6272,10 @@ int skill_unit_onplace(struct skill_unit *src,struct block_list *bl,unsigned int
struct map_session_data *sd;
if (srcsd && bl->type == BL_PC && (sd=(struct map_session_data *)bl) &&
sd->status.guild_id == srcsd->status.guild_id &&
- sd->sc_data[SC_SOULCOLD].timer == -1 && !sd->sc_data[SC_SOULCOLD].val4)
- skill_status_change_start(bl,SC_SOULCOLD,1,0,0,0,0,0 );
+ sd != srcsd) {
+ sd->state.soulcold_flag = (int)src;
+ pc_calcstatus (sd, 0);
+ }
}
break;
case 0xc4: // GD_HAWKEYES
@@ -6261,8 +6283,10 @@ int skill_unit_onplace(struct skill_unit *src,struct block_list *bl,unsigned int
struct map_session_data *sd;
if (srcsd && bl->type == BL_PC && (sd=(struct map_session_data *)bl) &&
sd->status.guild_id == srcsd->status.guild_id &&
- sd->sc_data[SC_HAWKEYES].timer == -1 && !sd->sc_data[SC_HAWKEYES].val4)
- skill_status_change_start(bl,SC_HAWKEYES,1,0,0,0,0,0 );
+ sd != srcsd) {
+ sd->state.hawkeyes_flag = (int)src;
+ pc_calcstatus (sd, 0);
+ }
}
break;
@@ -6404,30 +6428,30 @@ int skill_unit_onout(struct skill_unit *src,struct block_list *bl,unsigned int t
// New guild skills [Celest]
case 0xc1: // GD_LEADERSHIP
{
- struct status_change *sc_data=battle_get_sc_data(bl);
- if (sc_data && sc_data[SC_LEADERSHIP].timer != -1)
- skill_status_change_end(bl,SC_LEADERSHIP,-1);
+ struct map_session_data *sd;
+ if (bl->type == BL_PC && (sd=(struct map_session_data *)bl) && sd->state.leadership_flag > 0)
+ sd->state.leadership_flag = 0;
}
break;
case 0xc2: // GD_GLORYWOUNDS
{
- struct status_change *sc_data=battle_get_sc_data(bl);
- if (sc_data && sc_data[SC_GLORYWOUNDS].timer != -1)
- skill_status_change_end(bl,SC_GLORYWOUNDS,-1);
+ struct map_session_data *sd;
+ if (bl->type == BL_PC && (sd=(struct map_session_data *)bl) && sd->state.glorywounds_flag > 0)
+ sd->state.glorywounds_flag = 0;
}
break;
case 0xc3: // GD_SOULCOLD
{
- struct status_change *sc_data=battle_get_sc_data(bl);
- if (sc_data && sc_data[SC_SOULCOLD].timer != -1)
- skill_status_change_end(bl,SC_SOULCOLD,-1);
+ struct map_session_data *sd;
+ if (bl->type == BL_PC && (sd=(struct map_session_data *)bl) && sd->state.soulcold_flag > 0)
+ sd->state.soulcold_flag = 0;
}
break;
case 0xc4: // GD_HAWKEYES
{
- struct status_change *sc_data=battle_get_sc_data(bl);
- if (sc_data && sc_data[SC_HAWKEYES].timer != -1)
- skill_status_change_end(bl,SC_HAWKEYES,-1);
+ struct map_session_data *sd;
+ if (bl->type == BL_PC && (sd=(struct map_session_data *)bl) && sd->state.hawkeyes_flag > 0)
+ sd->state.hawkeyes_flag = 0;
}
break;
@@ -6546,15 +6570,15 @@ int skill_unit_onlimit(struct skill_unit *src,unsigned int tick)
{
struct map_session_data *sd;
if ((sd = (struct map_session_data *)(map_id2bl(sg->src_id)))!= NULL) {
- sd->sc_data[SC_LEADERSHIP].val4 = 0;
- }
+ sd->state.leadership_flag = 0;
+ }
}
break;
case 0xc2: // GD_GLORYWOUNDS
{
struct map_session_data *sd;
if ((sd = (struct map_session_data *)(map_id2bl(sg->src_id)))!= NULL) {
- sd->sc_data[SC_GLORYWOUNDS].val4 = 0;
+ sd->state.glorywounds_flag = 0;
}
}
break;
@@ -6562,7 +6586,7 @@ int skill_unit_onlimit(struct skill_unit *src,unsigned int tick)
{
struct map_session_data *sd;
if ((sd = (struct map_session_data *)(map_id2bl(sg->src_id)))!= NULL) {
- sd->sc_data[SC_SOULCOLD].val4 = 0;
+ sd->state.soulcold_flag = 0;
}
}
break;
@@ -6570,7 +6594,7 @@ int skill_unit_onlimit(struct skill_unit *src,unsigned int tick)
{
struct map_session_data *sd;
if ((sd = (struct map_session_data *)(map_id2bl(sg->src_id)))!= NULL) {
- sd->sc_data[SC_HAWKEYES].val4 = 0;
+ sd->state.hawkeyes_flag = 0;
}
}
break;
@@ -6975,6 +6999,8 @@ int skill_check_condition(struct map_session_data *sd,int type)
skill = sd->skillid;
lv = sd->skilllv;
if(lv <= 0) return 0;
+ // for the guild skills [celest]
+ if (skill >= 10000 && skill < 10015) skill-= 9500;
hp=skill_get_hp(skill, lv); /* 消費HP */
sp=skill_get_sp(skill, lv); /* 消費SP */
if((sd->skillid_old == BD_ENCORE) && skill==sd->skillid_dance)
@@ -8655,10 +8681,10 @@ int skill_status_change_end(struct block_list* bl, int type, int tid)
case SC_MARIONETTE:
case SC_MARIONETTE2:
case SC_SLOWDOWN:
- case SC_LEADERSHIP:
+/* case SC_LEADERSHIP:
case SC_GLORYWOUNDS:
case SC_SOULCOLD:
- case SC_HAWKEYES:
+ case SC_HAWKEYES:*/
case SC_BATTLEORDERS:
case SC_REGENERATION:
calc_flag = 1;
@@ -9306,7 +9332,7 @@ int skill_status_change_timer(int tid, unsigned int tick, int id, int data)
}
break;
- case SC_LEADERSHIP:
+/* case SC_LEADERSHIP:
case SC_GLORYWOUNDS:
case SC_SOULCOLD:
case SC_HAWKEYES:
@@ -9315,7 +9341,7 @@ int skill_status_change_timer(int tid, unsigned int tick, int id, int data)
1000+tick, skill_status_change_timer,
bl->id, data);
}
- break;
+ break;*/
// Celest
case SC_CONFUSION:
@@ -10124,14 +10150,14 @@ int skill_status_change_start(struct block_list *bl, int type, int val1, int val
calc_flag = 1;
break;
- case SC_LEADERSHIP:
+/* case SC_LEADERSHIP:
case SC_GLORYWOUNDS:
case SC_SOULCOLD:
case SC_HAWKEYES:
tick = 1000;
calc_flag = 1;
//val4 = 1;
- break;
+ break;*/
case SC_REGENERATION:
val1 = 2;
@@ -11285,21 +11311,26 @@ int skill_produce_mix( struct map_session_data *sd,
/* 確率判定 */
equip = itemdb_isequip(nameid);
if(!equip) {
+// Corrected rates [DracoRPG] --------------------------//
if(skill_produce_db[idx].req_skill==AM_PHARMACY) {
- if((nameid >= 501 && nameid <= 506) || (nameid >= 545 && nameid <= 547) || nameid == 525)
- make_per = 2000 + sd->status.base_level*30 + sd->paramc[3]*20 + sd->paramc[4]*15 + pc_checkskill(sd,AM_LEARNINGPOTION)*100 + pc_checkskill(sd,AM_PHARMACY)*300 + pc_checkskill(sd,AM_POTIONPITCHER)*100;
- else if(nameid == 970)
- make_per = 1500 + sd->status.base_level*30 + sd->paramc[3]*20 + sd->paramc[4]*15 + pc_checkskill(sd,AM_LEARNINGPOTION)*100 + pc_checkskill(sd,AM_PHARMACY)*300;
- else if(nameid == 7135)
- make_per = 1000 + sd->status.base_level*30 + sd->paramc[3]*20 + sd->paramc[4]*15 + pc_checkskill(sd,AM_LEARNINGPOTION)*100 + pc_checkskill(sd,AM_PHARMACY)*300 + pc_checkskill(sd,AM_DEMONSTRATION)*100;
- else if(nameid == 7136)
- make_per = 1000 + sd->status.base_level*30 + sd->paramc[3]*20 + sd->paramc[4]*15 + pc_checkskill(sd,AM_LEARNINGPOTION)*100 + pc_checkskill(sd,AM_PHARMACY)*300 + pc_checkskill(sd,AM_ACIDTERROR)*100;
- else if(nameid == 7137)
- make_per = 1000 + sd->status.base_level*30 + sd->paramc[3]*20 + sd->paramc[4]*15 + pc_checkskill(sd,AM_LEARNINGPOTION)*100 + pc_checkskill(sd,AM_PHARMACY)*300 + pc_checkskill(sd,AM_CANNIBALIZE)*100;
- else if(nameid == 7138)
- make_per = 1000 + sd->status.base_level*30 + sd->paramc[3]*20 + sd->paramc[4]*15 + pc_checkskill(sd,AM_LEARNINGPOTION)*100 + pc_checkskill(sd,AM_PHARMACY)*300 + pc_checkskill(sd,AM_SPHEREMINE)*100;
- else if(nameid == 7139)
- make_per = 1000 + sd->status.base_level*30 + sd->paramc[3]*20 + sd->paramc[4]*15 + pc_checkskill(sd,AM_LEARNINGPOTION)*100 + pc_checkskill(sd,AM_PHARMACY)*300 + pc_checkskill(sd,AM_CP_WEAPON)*100 +
+ if(nameid >= 501 && nameid <= 505) // Normal potions
+ make_per = 2000 + sd->status.job_level*20 + sd->paramc[4]*10 + sd->paramc[5]*10 + pc_checkskill(sd,AM_LEARNINGPOTION)*100 + pc_checkskill(sd,AM_PHARMACY)*300 + pc_checkskill(sd,AM_POTIONPITCHER)*100;
+ if(nameid >= 605 && nameid <= 606) // Anodyne & Aloevera (not sure of the formula, I put the same base value as normal pots but without the Aid Potion bonus since they are not throwable pots ^^)
+ make_per = 2000 + sd->status.job_level*20 + sd->paramc[4]*10 + sd->paramc[5]*10 + pc_checkskill(sd,AM_LEARNINGPOTION)*100 + pc_checkskill(sd,AM_PHARMACY)*300;
+ else if(nameid >= 545 && nameid <= 547) // Concentrated potions
+ make_per = sd->status.job_level*20 + sd->paramc[4]*10 + sd->paramc[5]*10 + pc_checkskill(sd,AM_LEARNINGPOTION)*100 + pc_checkskill(sd,AM_PHARMACY)*300;
+ else if(nameid == 970) // Alcohol
+ make_per = 1000 + sd->status.job_level*20 + sd->paramc[4]*10 + sd->paramc[5]*10 + pc_checkskill(sd,AM_LEARNINGPOTION)*100 + pc_checkskill(sd,AM_PHARMACY)*300;
+ else if(nameid == 7135) // Bottle Grenade
+ make_per = 500 + sd->status.job_level*20 + sd->paramc[4]*10 + sd->paramc[5]*10 + pc_checkskill(sd,AM_LEARNINGPOTION)*100 + pc_checkskill(sd,AM_PHARMACY)*300 + pc_checkskill(sd,AM_DEMONSTRATION)*100;
+ else if(nameid == 7136) // Acid Bottle
+ make_per = 500 + sd->status.job_level*20 + sd->paramc[4]*10 + sd->paramc[5]*10 + pc_checkskill(sd,AM_LEARNINGPOTION)*100 + pc_checkskill(sd,AM_PHARMACY)*300 + pc_checkskill(sd,AM_ACIDTERROR)*100;
+ else if(nameid == 7137) // Plant Bottle
+ make_per = 500 + sd->status.job_level*20 + sd->paramc[4]*10 + sd->paramc[5]*10 + pc_checkskill(sd,AM_LEARNINGPOTION)*100 + pc_checkskill(sd,AM_PHARMACY)*300 + pc_checkskill(sd,AM_CANNIBALIZE)*100;
+ else if(nameid == 7138) // Marine Sphere Bottle
+ make_per = 500 + sd->status.job_level*20 + sd->paramc[4]*10 + sd->paramc[5]*10 + pc_checkskill(sd,AM_LEARNINGPOTION)*100 + pc_checkskill(sd,AM_PHARMACY)*300 + pc_checkskill(sd,AM_SPHEREMINE)*100;
+ else if(nameid == 7139) // Glistening Coat
+ make_per = 500 + sd->status.job_level*20 + sd->paramc[4]*10 + sd->paramc[5]*10 + pc_checkskill(sd,AM_LEARNINGPOTION)*100 + pc_checkskill(sd,AM_PHARMACY)*300 + pc_checkskill(sd,AM_CP_WEAPON)*100 +
pc_checkskill(sd,AM_CP_SHIELD)*100 + pc_checkskill(sd,AM_CP_ARMOR)*100 + pc_checkskill(sd,AM_CP_HELM)*100;
else
make_per = 1000 + sd->status.base_level*30 + sd->paramc[3]*20 + sd->paramc[4]*15 + pc_checkskill(sd,AM_LEARNINGPOTION)*100 + pc_checkskill(sd,AM_PHARMACY)*300;
@@ -11308,26 +11339,22 @@ int skill_produce_mix( struct map_session_data *sd,
//make_per = 20 + (20*sd->paramc[4])/50 + (20*sd->paramc[5])/100;
} else {
if(nameid == 998)
- make_per = 2000 + sd->status.base_level*30 + sd->paramc[4]*20 + sd->paramc[5]*10 + pc_checkskill(sd,skill_produce_db[idx].req_skill)*600;
- else if(nameid == 985)
- make_per = 1000 + sd->status.base_level*30 + sd->paramc[4]*20 + sd->paramc[5]*10 + (pc_checkskill(sd,skill_produce_db[idx].req_skill)-1)*500;
+ make_per = 1500 + sd->status.job_level*35 + sd->paramc[4]*10 + sd->paramc[5]*10 + pc_checkskill(sd,skill_produce_db[idx].req_skill)*600;
else
- make_per = 1000 + sd->status.base_level*30 + sd->paramc[4]*20 + sd->paramc[5]*10 + pc_checkskill(sd,skill_produce_db[idx].req_skill)*500;
+ make_per = 1000 + sd->status.job_level*35 + sd->paramc[4]*10 + sd->paramc[5]*10 + pc_checkskill(sd,skill_produce_db[idx].req_skill)*500;
}
}
- else {
- int add_per;
- if(pc_search_inventory(sd,989) >= 0) add_per = 750;
- else if(pc_search_inventory(sd,988) >= 0) add_per = 500;
- else if(pc_search_inventory(sd,987) >= 0) add_per = 250;
- else if(pc_search_inventory(sd,986) >= 0) add_per = 0;
- else add_per = -500;
- if(ele) add_per -= 500;
- add_per -= sc*500;
- wlv = itemdb_wlv(nameid);
- make_per = ((250 + sd->status.base_level*15 + sd->paramc[4]*10 + sd->paramc[5]*5 + pc_checkskill(sd,skill_produce_db[idx].req_skill)*500 +
- add_per) * (100 - (wlv - 1)*20))/100 + pc_checkskill(sd,BS_WEAPONRESEARCH)*100 + ((wlv >= 3)? pc_checkskill(sd,BS_ORIDEOCON)*100 : 0);
+ else { // Corrected rates [DracoRPG]
+ int add_per=0;
+ if(pc_search_inventory(sd,989) >= 0) add_per = 400;
+ else if(pc_search_inventory(sd,988) >= 0) add_per = 300;
+ else if(pc_search_inventory(sd,987) >= 0) add_per = 200;
+ else if(pc_search_inventory(sd,986) >= 0) add_per = 100;
+ wlv = itemdb_wlv(nameid);
+ make_per = 1500 + sd->status.job_level*35 + sd->paramc[4]*10 + sd->paramc[5]*10 + pc_checkskill(sd,skill_produce_db[idx].req_skill)*1000 + pc_checkskill(sd,BS_WEAPONRESEARCH)*100 +
+ ((wlv >= 3)? pc_checkskill(sd,BS_ORIDEOCON)*100 : 0) + add_per - (ele? 2500:0) - sc*((4-wlv)*500) - wlv*1000;
}
+// -----------------------------------------------------//
if(make_per < 1) make_per = 1;
diff --git a/src/map/skill.h b/src/map/skill.h
index 948b9b399..09f47403e 100644
--- a/src/map/skill.h
+++ b/src/map/skill.h
@@ -344,10 +344,10 @@ enum { // struct map_session_data の status_changeの番?テ?ブル
SC_SPELLBREAKER =192,
SC_DPOISON =193, /* 猛毒 */
SC_BLOCKSKILL =194, // for disallowing the use of a skill for a time period
- SC_LEADERSHIP =196,
+/* SC_LEADERSHIP =196, // temporarily disabled - they're too buggy =/
SC_GLORYWOUNDS =197,
SC_SOULCOLD =198,
- SC_HAWKEYES =199,
+ SC_HAWKEYES =199,*/
SC_BATTLEORDERS =200,
SC_REGENERATION =201,
SC_PRESERVE =202,