- Corrected Musical Strike having a different damage equation from Throw Arrow.
- Some minor cleanup of Soul Change - Added state rewarp to players. It gets set when a pc_setpos call is triggered while the player is changing maps so that when the player finish loading the map, it is inmediately rewarped to where it has been rewarped/recalled to. git-svn-id: https://svn.code.sf.net/p/rathena/svn/trunk@7370 54d463be-8e91-2dee-dedb-b68131a5f0ec
This commit is contained in:
parent
0bd2225826
commit
6775ca1476
@ -3,6 +3,13 @@ Date Added
|
||||
AS OF SVN REV. 5091, WE ARE NOW USING TRUNK. ALL UNTESTED BUGFIXES/FEATURES GO INTO TRUNK.
|
||||
IF YOU HAVE A WORKING AND TESTED BUGFIX PUT IT INTO STABLE AS WELL AS TRUNK.
|
||||
|
||||
2006/05/28
|
||||
* Corrected Musical Strike having a different damage equation from Throw
|
||||
Arrow. [Skotlex]
|
||||
* Added state rewarp to players. It gets set when a pc_setpos call is
|
||||
triggered while the player is changing maps so that when the player finish
|
||||
loading the map, it is inmediately rewarped to where it has been
|
||||
rewarped/recalled to. [Skotlex]
|
||||
2006/05/27
|
||||
* Map server will now resent the whole list of online characters to
|
||||
char-server on reconnect when the kick_on_disconnect setting is active.
|
||||
|
@ -1367,8 +1367,6 @@ static struct Damage battle_calc_weapon_attack(
|
||||
skillratio += 140+60*skill_lv;
|
||||
break;
|
||||
case BA_MUSICALSTRIKE:
|
||||
skillratio += 40*skill_lv-40;
|
||||
break;
|
||||
case DC_THROWARROW:
|
||||
skillratio += 50*skill_lv;
|
||||
break;
|
||||
|
@ -1754,9 +1754,6 @@ int clif_changemap(struct map_session_data *sd, short map, int x, int y) {
|
||||
WFIFOW(fd,20) = y;
|
||||
WFIFOSET(fd, packet_len_table[0x91]);
|
||||
|
||||
if(pc_isdead(sd)) // If player is dead, and is spawned (such as @refresh) send death packet. [Valaris]
|
||||
clif_clearchar_area(&sd->bl,1);
|
||||
|
||||
return 0;
|
||||
}
|
||||
|
||||
@ -8062,6 +8059,13 @@ void clif_parse_LoadEndAck(int fd,struct map_session_data *sd)
|
||||
if(sd->bl.prev != NULL)
|
||||
return;
|
||||
|
||||
if (sd->state.rewarp)
|
||||
{ //Rewarp player.
|
||||
sd->state.rewarp = 0;
|
||||
clif_changemap(sd,sd->mapindex,sd->bl.x,sd->bl.y);
|
||||
return;
|
||||
}
|
||||
|
||||
if(sd->npc_id) npc_event_dequeue(sd);
|
||||
|
||||
if(sd->state.connect_new) {
|
||||
@ -8240,8 +8244,9 @@ void clif_parse_LoadEndAck(int fd,struct map_session_data *sd)
|
||||
else
|
||||
sd->areanpc_id = 0;
|
||||
|
||||
if (pc_isdead(sd)) //In case you warped dead.
|
||||
clif_clearchar_area(&sd->bl, 1);
|
||||
// If player is dead, and is spawned (such as @refresh) send death packet. [Valaris]
|
||||
if(pc_isdead(sd))
|
||||
clif_clearchar_area(&sd->bl,1);
|
||||
}
|
||||
|
||||
/*==========================================
|
||||
|
@ -285,7 +285,6 @@ static int itemdb_ispetequip(struct item_data *data)
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
/*==========================================
|
||||
* Trade Restriction functions [Skotlex]
|
||||
*------------------------------------------
|
||||
@ -1184,12 +1183,18 @@ void itemdb_reload(void)
|
||||
void do_final_itemdb(void)
|
||||
{
|
||||
item_db->destroy(item_db, itemdb_final_sub, 1);
|
||||
if (dummy_item.script)
|
||||
if (dummy_item.script) {
|
||||
script_free_code(dummy_item.script);
|
||||
if (dummy_item.equip_script)
|
||||
dummy_item.script = NULL;
|
||||
}
|
||||
if (dummy_item.equip_script) {
|
||||
script_free_code(dummy_item.equip_script);
|
||||
if (dummy_item.unequip_script)
|
||||
dummy_item.equip_script = NULL;
|
||||
}
|
||||
if (dummy_item.unequip_script) {
|
||||
script_free_code(dummy_item.unequip_script);
|
||||
dummy_item.unequip_script = NULL;
|
||||
}
|
||||
}
|
||||
|
||||
int do_init_itemdb(void)
|
||||
|
@ -493,6 +493,7 @@ struct map_session_data {
|
||||
unsigned finalsave :1; //Signals whether the final save for the char was done or not yet. Meant to prevent exploits and the like. [Skotlex]
|
||||
unsigned blockedmove :1;
|
||||
unsigned using_fake_npc :1;
|
||||
unsigned rewarp :1; //Signals that a player should warp as soon as he is done loading a map. [Skotlex]
|
||||
unsigned short autoloot;
|
||||
struct guild *gmaster_flag;
|
||||
} state;
|
||||
|
11
src/map/pc.c
11
src/map/pc.c
@ -3167,13 +3167,6 @@ int pc_setpos(struct map_session_data *sd,unsigned short mapindex,int x,int y,in
|
||||
ShowDebug("pc_setpos: Passed mapindex(%d) is invalid!\n", mapindex);
|
||||
return 1;
|
||||
}
|
||||
if(sd->state.auth && sd->bl.prev == NULL)
|
||||
{ //Should NOT move a character while it is not in a map (changing between maps, for example)
|
||||
//state.auth helps identifies if this is the initial setpos rather than a normal map-change set pos.
|
||||
if (battle_config.etc_log)
|
||||
ShowInfo("pc_setpos failed: Attempted to relocate player %s (%d:%d) while it is still between maps.\n", sd->status.name, sd->status.account_id, sd->status.char_id);
|
||||
return 3;
|
||||
}
|
||||
|
||||
m=map_mapindex2mapid(mapindex);
|
||||
|
||||
@ -3246,7 +3239,9 @@ int pc_setpos(struct map_session_data *sd,unsigned short mapindex,int x,int y,in
|
||||
if(sd->status.pet_id > 0 && sd->pd)
|
||||
unit_remove_map(&sd->pd->bl, clrtype);
|
||||
clif_changemap(sd,map[m].index,x,y); // [MouseJstr]
|
||||
}
|
||||
} else if(sd->state.auth)
|
||||
//Tag player for rewarping after map-loading is done. [Skotlex]
|
||||
sd->state.rewarp = 1;
|
||||
|
||||
sd->mapindex = mapindex;
|
||||
sd->bl.m = m;
|
||||
|
@ -5085,10 +5085,9 @@ int skill_castend_nodamage_id (struct block_list *src, struct block_list *bl, in
|
||||
}
|
||||
sp1 = sstatus->sp;
|
||||
sp2 = tstatus->sp;
|
||||
status_zap(src, 0, sp1);
|
||||
status_zap(bl, 0, sp2);
|
||||
status_heal(src, 0, sp2, 3);
|
||||
status_heal(bl, 0, sp1, 3);
|
||||
//TODO: Will this work correctly once sp1/sp2 go above INT_MAX?
|
||||
status_heal(src, 0, (signed int)(sp2-sp1), 3);
|
||||
status_heal(bl, 0, (signed int)(sp1-sp2), 3);
|
||||
clif_skill_nodamage(src,bl,skillid,skilllv,1);
|
||||
}
|
||||
break;
|
||||
|
Loading…
x
Reference in New Issue
Block a user