From 66ea41fff413837ec15eb47f65474eacf9318e5f Mon Sep 17 00:00:00 2001 From: skotlex Date: Sat, 4 Mar 2006 01:54:56 +0000 Subject: - The rate passed to status_change_start must now be in 0->10000 range. - Added macros sc_start and sc_start4 to simplify invocation of status_change_start. - Cleaned the active guild skills, requirements moved to skill_check_require, should now be usable by non-players as well (pets/mobs). - Updated skill_cast_db time info. Magnum's time2 is skill-block time, St. Recovery/ Cure's time2 is the confuse/blind duration, added NPC_POWERUP/NPC_AGIUP durations, Napalm Vulcan's time2 is curse length, and most of Tarot Card's effects last time2 as well. git-svn-id: https://rathena.svn.sourceforge.net/svnroot/rathena/trunk@5454 54d463be-8e91-2dee-dedb-b68131a5f0ec --- src/map/clif.c | 42 +++++++----------------------------------- 1 file changed, 7 insertions(+), 35 deletions(-) (limited to 'src/map/clif.c') diff --git a/src/map/clif.c b/src/map/clif.c index 5f2a53bf1..8042e5743 100644 --- a/src/map/clif.c +++ b/src/map/clif.c @@ -8823,7 +8823,7 @@ void clif_parse_LoadEndAck(int fd,struct map_session_data *sd) clif_changelook(&sd->bl,LOOK_CLOTHES_COLOR,sd->status.clothes_color); if(battle_config.muting_players && sd->status.manner < 0 && battle_config.manner_system) - status_change_start(&sd->bl,SC_NOCHAT,100,0,0,0,0,0,0); + sc_start(&sd->bl,SC_NOCHAT,100,0,0); // Lance if (script_config.event_script_type == 0) { @@ -8836,34 +8836,6 @@ void clif_parse_LoadEndAck(int fd,struct map_session_data *sd) ShowStatus("%d '"CL_WHITE"%s"CL_RESET"' events executed.\n", npc_event_doall_id(script_config.loadmap_event_name, sd->bl.id), script_config.loadmap_event_name); } -/* These should not be needed anymore. [Skotlex] - * - the option is sent on every player packet, why send it? - * - There should be no need to do a signum check on map change, it is done on equipment change. - * - Trick-dead is finished on pc_setpos - * - Night effect is handled on clif_spawnpc - // option - clif_changeoption(&sd->bl); - if(sd->sc_data[SC_TRICKDEAD].timer != -1) - status_change_end(&sd->bl,SC_TRICKDEAD,-1); - if(sd->sc_data[SC_SIGNUMCRUCIS].timer != -1 && !battle_check_undead(7,sd->def_ele)) - status_change_end(&sd->bl,SC_SIGNUMCRUCIS,-1); - if(sd->special_state.infinite_endure && sd->sc_data[SC_ENDURE].timer == -1) - status_change_start(&sd->bl,SC_ENDURE,100,10,1,0,0,0,0); - - // Required to eliminate glow bugs because it's executed before clif_changeoption [Lance] - //New 'night' effect by dynamix [Skotlex] - if (night_flag && map[sd->bl.m].flag.nightenabled) - { //Display night. - if (sd->state.night) //It must be resent because otherwise players get this annoying aura... - clif_status_load(&sd->bl, SI_NIGHT, 0); - else - sd->state.night = 1; - clif_status_load(&sd->bl, SI_NIGHT, 1); - } else if (sd->state.night) { //Clear night display. - clif_status_load(&sd->bl, SI_NIGHT, 0); - sd->state.night = 0; - } -*/ if (pc_checkskill(sd,SG_KNOWLEDGE) || pc_checkskill(sd,SG_SUN_COMFORT) || pc_checkskill(sd,SG_MOON_COMFORT) || @@ -9161,8 +9133,8 @@ void clif_parse_GlobalMessage(int fd, struct map_session_data *sd) { // S 008c < if (skillnotok(MO_EXPLOSIONSPIRITS,sd)) break; //Do not override the noskill mapflag. [Skotlex] clif_skill_nodamage(&sd->bl,&sd->bl,MO_EXPLOSIONSPIRITS,-1, - status_change_start(&sd->bl,SkillStatusChangeTable[MO_EXPLOSIONSPIRITS],100, - 17,0,0,0,skill_get_time(MO_EXPLOSIONSPIRITS,1),0 )); //Lv17-> +50 critical (noted by Poki) [Skotlex] + sc_start(&sd->bl,SkillStatusChangeTable[MO_EXPLOSIONSPIRITS],100, + 17,skill_get_time(MO_EXPLOSIONSPIRITS,1))); //Lv17-> +50 critical (noted by Poki) [Skotlex] sd->state.snovice_flag = 0; break; } @@ -11103,7 +11075,7 @@ void clif_parse_GMReqNoChat(int fd,struct map_session_data *sd) { dstsd->status.manner -= limit; if(dstsd->status.manner < 0) - status_change_start(bl,SC_NOCHAT,100,0,0,0,0,0,0); + sc_start(bl,SC_NOCHAT,100,0,0); else { dstsd->status.manner = 0; @@ -11300,7 +11272,7 @@ void clif_parse_NoviceDoriDori(int fd, struct map_session_data *sd) { sd->doridori_counter = 1; if ((sd->class_&MAPID_UPPERMASK) == MAPID_TAEKWON && sd->state.rest && (level = pc_checkskill(sd,TK_SPTIME))) - status_change_start(&sd->bl,SkillStatusChangeTable[TK_SPTIME],100,level,0,0,0,skill_get_time(TK_SPTIME, level),0); + sc_start(&sd->bl,SkillStatusChangeTable[TK_SPTIME],100,level,skill_get_time(TK_SPTIME, level)); return; } /*========================================== @@ -11319,8 +11291,8 @@ void clif_parse_NoviceExplosionSpirits(int fd, struct map_session_data *sd) } if((sd->class_&MAPID_UPPERMASK) == MAPID_SUPER_NOVICE && sd->status.base_exp > 0 && nextbaseexp > 0 && (int)((double)1000*sd->status.base_exp/nextbaseexp)%100==0){ clif_skill_nodamage(&sd->bl,&sd->bl,MO_EXPLOSIONSPIRITS,5, - status_change_start(&sd->bl,SkillStatusChangeTable[MO_EXPLOSIONSPIRITS],100, - 5,0,0,0,skill_get_time(MO_EXPLOSIONSPIRITS,5),0)); + sc_start(&sd->bl,SkillStatusChangeTable[MO_EXPLOSIONSPIRITS],100, + 5,skill_get_time(MO_EXPLOSIONSPIRITS,5))); } } return; -- cgit v1.2.3-70-g09d2