summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--Changelog-Trunk.txt2
-rw-r--r--src/map/clif.c26
-rw-r--r--src/map/clif.h1
-rw-r--r--src/map/skill.c82
4 files changed, 74 insertions, 37 deletions
diff --git a/Changelog-Trunk.txt b/Changelog-Trunk.txt
index 90eeeb945..966fdd794 100644
--- a/Changelog-Trunk.txt
+++ b/Changelog-Trunk.txt
@@ -4,6 +4,8 @@ AS OF SVN REV. 5091, WE ARE NOW USING TRUNK. ALL UNTESTED BUGFIXES/FEATURES GO
IF YOU HAVE A WORKING AND TESTED BUGFIX PUT IT INTO STABLE AS WELL AS TRUNK.
2006/11/08
+ * Added clif_gospel_info which displays info about the buffs you are
+ receiving. Thanks to Rayce for the packet information. [Skotlex]
* Fixed Spider Web not ending when hit by a fireelemental attack. [Skotlex]
* Cast-time reductions from status changes will not be executed until right
before casting, to prevent status changes from ending when attempting to
diff --git a/src/map/clif.c b/src/map/clif.c
index 31cdf4889..e85c40aa0 100644
--- a/src/map/clif.c
+++ b/src/map/clif.c
@@ -104,7 +104,7 @@ static const int packet_len_table[MAX_PACKET_DB] = {
-1, -1, 20, 10, 32, 9, 34, 14, 2, 6, 48, 56, -1, 4, 5, 10,
//#0x200
26, -1, 26, 10, 18, 26, 11, 34, 14, 36, 10, 0, 0, -1, 32, 10, // 0x20c change to 0 (was 19)
- 22, 0, 26, 26, 42, -1, -1, 2, 2,282,282,10, 10, -1, -1, 66,
+ 22, 0, 26, 26, 42, 6, 6, 2, 2,282,282,10, 10, -1, -1, 66,
10, -1, -1, 8, 10, 2,282, 18, 18, 15, 58, 57, 64, 5, 71, 5,
12, 26, 9, 11, -1, -1, 10, 2, 282, 11, 4, 36, -1,-1, 4, 2,
-1, -1, -1, -1, -1, 3, 4, 8, -1, 3, 70, 4, 8,12, 4, 10,
@@ -8018,6 +8018,30 @@ int clif_party_xy_remove(struct map_session_data *sd)
return 0;
}
+//Displays gospel-buff information (thanks to Rayce):
+//Type determines message based on this table:
+/*
+ 0x15 End all negative status
+ 0x16 Immunity to all status
+ 0x17 MaxHP +100%
+ 0x18 MaxSP +100%
+ 0x19 All stats +20
+ 0x1c Enchant weapon with Holy element
+ 0x1d Enchant armor with Holy element
+ 0x1e DEF +25%
+ 0x1f ATK +100%
+ 0x20 HIT/Flee +50
+ 0x28 Full strip failed because of coating (unrelated to gospel, maybe for ST_FULLSTRIP)
+*/
+void clif_gospel_info(struct map_session_data *sd, int type)
+{
+ int fd=sd->fd;
+ WFIFOHEAD(fd,packet_len_table[0x215]);
+ WFIFOW(fd,0)=0x215;
+ WFIFOL(fd,2)=type;
+ WFIFOSET(fd, packet_len_table[0x215]);
+
+}
/*==========================================
* Info about Star Glaldiator save map [Komurka]
* type: 1: Information, 0: Map registered
diff --git a/src/map/clif.h b/src/map/clif.h
index 01e9445b3..51a2f5a5b 100644
--- a/src/map/clif.h
+++ b/src/map/clif.h
@@ -345,6 +345,7 @@ int do_init_clif(void);
void clif_get_weapon_view(TBL_PC* sd, unsigned short *rhand, unsigned short *lhand);
int clif_party_xy_remove(struct map_session_data *sd); //Fix for minimap [Kevin]
+void clif_gospel_info(struct map_session_data *sd, int type);
void clif_parse_ReqFeel(int fd, struct map_session_data *sd, int skilllv);
void clif_feel_info(struct map_session_data *sd, unsigned char feel_level, unsigned char type);
void clif_hate_info(struct map_session_data *sd, unsigned char hate_level,int class_, unsigned char type);
diff --git a/src/map/skill.c b/src/map/skill.c
index 291c2c863..4925922c8 100644
--- a/src/map/skill.c
+++ b/src/map/skill.c
@@ -7249,84 +7249,94 @@ int skill_unit_onplace_timer (struct skill_unit *src, struct block_list *bl, uns
break;
if (ss != bl && battle_check_target(ss,bl,BCT_PARTY)>0) { // Support Effect only on party, not guild
int i = rand()%13; // Positive buff count
+ type = skill_get_time2(sg->skill_id, sg->skill_lv); //Duration
switch (i)
{
case 0: // Heal 1~9999 HP
- {
- int heal = rand() %9999+1;
- clif_skill_nodamage(ss,bl,AL_HEAL,heal,1);
- status_heal(bl,heal,0,0);
- }
+ type = rand() %9999+1;
+ clif_skill_nodamage(ss,bl,AL_HEAL,type,1);
+ status_heal(bl,type,0,0);
break;
case 1: // End all negative status
status_change_clear_buffs(bl,2);
+ if (sd) clif_gospel_info(sd, 0x15);
break;
- case 2: // Level 10 Blessing
- sc_start(bl,SC_BLESSING,100,10,skill_get_time2(sg->skill_id, sg->skill_lv));
+ case 2: // 100% resist to status changes.
+ sc_start(bl,SC_SCRESIST,100,100,type);
+ if (sd) clif_gospel_info(sd, 0x16);
break;
- case 3: // Level 10 Increase AGI
- sc_start(bl,SC_INCREASEAGI,100,10,skill_get_time2(sg->skill_id, sg->skill_lv));
+ case 3: // MaxHP +100%
+ sc_start(bl,SC_INCMHPRATE,100,100,type);
+ if (sd) clif_gospel_info(sd, 0x17);
break;
- case 4: // Enchant weapon with Holy element
- sc_start(bl,SC_ASPERSIO,100,1,skill_get_time2(sg->skill_id, sg->skill_lv));
+ case 4: // MaxSP +100%
+ sc_start(bl,SC_INCMSPRATE,100,100,type);
+ if (sd) clif_gospel_info(sd, 0x18);
break;
- case 5: // Enchant armor with Holy element
- sc_start(bl,SC_BENEDICTIO,100,1,skill_get_time2(sg->skill_id, sg->skill_lv));
+ case 5: // All stats +20
+ sc_start(bl,SC_INCALLSTATUS,100,20,type);
+ if (sd) clif_gospel_info(sd, 0x19);
break;
- case 6: // MaxHP +100%
- sc_start(bl,SC_INCMHPRATE,100,100,skill_get_time2(sg->skill_id, sg->skill_lv));
+ case 6: // Level 10 Blessing
+ sc_start(bl,SC_BLESSING,100,10,type);
break;
- case 7: // MaxSP +100%
- sc_start(bl,SC_INCMSPRATE,100,100,skill_get_time2(sg->skill_id, sg->skill_lv));
+ case 7: // Level 10 Increase AGI
+ sc_start(bl,SC_INCREASEAGI,100,10,type);
break;
- case 8: // All stats +20
- sc_start(bl,SC_INCALLSTATUS,100,20,skill_get_time2(sg->skill_id, sg->skill_lv));
+ case 8: // Enchant weapon with Holy element
+ sc_start(bl,SC_ASPERSIO,100,1,type);
+ if (sd) clif_gospel_info(sd, 0x1c);
break;
- case 9: // DEF +25%
- sc_start(bl,SC_INCDEFRATE,100,25,skill_get_time2(sg->skill_id, sg->skill_lv));
+ case 9: // Enchant armor with Holy element
+ sc_start(bl,SC_BENEDICTIO,100,1,type);
+ if (sd) clif_gospel_info(sd, 0x1d);
break;
- case 10: // ATK +100%
- sc_start(bl,SC_INCATKRATE,100,100,skill_get_time2(sg->skill_id, sg->skill_lv));
+ case 10: // DEF +25%
+ sc_start(bl,SC_INCDEFRATE,100,25,type);
+ if (sd) clif_gospel_info(sd, 0x1e);
break;
- case 11: // HIT/Flee +50
- sc_start(bl,SC_INCHIT,100,50,skill_get_time2(sg->skill_id, sg->skill_lv));
- sc_start(bl,SC_INCFLEE,100,50,skill_get_time2(sg->skill_id, sg->skill_lv));
+ case 11: // ATK +100%
+ sc_start(bl,SC_INCATKRATE,100,100,type);
+ if (sd) clif_gospel_info(sd, 0x1f);
break;
- case 12: // Immunity to all status
- sc_start(bl,SC_SCRESIST,100,100,skill_get_time2(sg->skill_id, sg->skill_lv));
+ case 12: // HIT/Flee +50
+ sc_start(bl,SC_INCHIT,100,50,type);
+ sc_start(bl,SC_INCFLEE,100,50,type);
+ if (sd) clif_gospel_info(sd, 0x20);
break;
}
}
else if (battle_check_target(&src->bl,bl,BCT_ENEMY)>0) { // Offensive Effect
int i = rand()%9; // Negative buff count
+ type = skill_get_time2(sg->skill_id, sg->skill_lv);
switch (i)
{
case 0: // Deal 1~9999 damage
skill_attack(BF_MISC,ss,&src->bl,bl,sg->skill_id,sg->skill_lv,tick,0);
break;
case 1: // Curse
- sc_start(bl,SC_CURSE,100,1,skill_get_time2(sg->skill_id, sg->skill_lv));
+ sc_start(bl,SC_CURSE,100,1,type);
break;
case 2: // Blind
- sc_start(bl,SC_BLIND,100,1,skill_get_time2(sg->skill_id, sg->skill_lv));
+ sc_start(bl,SC_BLIND,100,1,type);
break;
case 3: // Poison
- sc_start(bl,SC_POISON,100,1,skill_get_time2(sg->skill_id, sg->skill_lv));
+ sc_start(bl,SC_POISON,100,1,type);
break;
case 4: // Level 10 Provoke
- sc_start(bl,SC_PROVOKE,100,10,skill_get_time2(sg->skill_id, sg->skill_lv));
+ sc_start(bl,SC_PROVOKE,100,10,type);
break;
case 5: // DEF -100%
- sc_start(bl,SC_INCDEFRATE,100,-100,skill_get_time2(sg->skill_id, sg->skill_lv));
+ sc_start(bl,SC_INCDEFRATE,100,-100,type);
break;
case 6: // ATK -100%
- sc_start(bl,SC_INCATKRATE,100,-100,skill_get_time2(sg->skill_id, sg->skill_lv));
+ sc_start(bl,SC_INCATKRATE,100,-100,type);
break;
case 7: // Flee -100%
- sc_start(bl,SC_INCFLEERATE,100,-100,skill_get_time2(sg->skill_id, sg->skill_lv));
+ sc_start(bl,SC_INCFLEERATE,100,-100,type);
break;
case 8: // Speed/ASPD -25%
- sc_start4(bl,SC_GOSPEL,100,1,0,0,BCT_ENEMY,skill_get_time2(sg->skill_id, sg->skill_lv));
+ sc_start4(bl,SC_GOSPEL,100,1,0,0,BCT_ENEMY,type);
break;
}
}