|
@@ -8632,6 +8632,34 @@ void clif_messagecolor(struct block_list* bl, unsigned long color, const char* m
|
|
clif_send(buf, WBUFW(buf,2), bl, AREA_CHAT_WOC);
|
|
clif_send(buf, WBUFW(buf,2), bl, AREA_CHAT_WOC);
|
|
}
|
|
}
|
|
|
|
|
|
|
|
+/**
|
|
|
|
+ * Notifies the client that the storage window is still open
|
|
|
|
+ *
|
|
|
|
+ * Should only be used in cases where the client closed the
|
|
|
|
+ * storage window without server's consent
|
|
|
|
+ */
|
|
|
|
+void clif_refresh_storagewindow(struct map_session_data *sd) {
|
|
|
|
+ // Notify the client that the storage is open
|
|
|
|
+ if( sd->state.storage_flag == 1 ) {
|
|
|
|
+ storage_sortitem(sd->status.storage.items, ARRAYLENGTH(sd->status.storage.items));
|
|
|
|
+ clif_storagelist(sd, sd->status.storage.items, ARRAYLENGTH(sd->status.storage.items));
|
|
|
|
+ clif_updatestorageamount(sd, sd->status.storage.storage_amount, MAX_STORAGE);
|
|
|
|
+ }
|
|
|
|
+ // Notify the client that the gstorage is open otherwise it will
|
|
|
|
+ // remain locked forever and nobody will be able to access it
|
|
|
|
+ if( sd->state.storage_flag == 2 ) {
|
|
|
|
+ struct guild_storage *gstor = guild2storage2(sd->status.guild_id);
|
|
|
|
+
|
|
|
|
+ if( !gstor ) // Shouldn't happen. The information should already be at the map-server
|
|
|
|
+ intif_request_guild_storage(sd->status.account_id, sd->status.guild_id);
|
|
|
|
+ else {
|
|
|
|
+ storage_sortitem(gstor->items, ARRAYLENGTH(gstor->items));
|
|
|
|
+ clif_storagelist(sd, gstor->items, ARRAYLENGTH(gstor->items));
|
|
|
|
+ clif_updatestorageamount(sd, gstor->storage_amount, MAX_GUILD_STORAGE);
|
|
|
|
+ }
|
|
|
|
+ }
|
|
|
|
+}
|
|
|
|
+
|
|
// refresh the client's screen, getting rid of any effects
|
|
// refresh the client's screen, getting rid of any effects
|
|
void clif_refresh(struct map_session_data *sd)
|
|
void clif_refresh(struct map_session_data *sd)
|
|
{
|
|
{
|
|
@@ -8692,6 +8720,7 @@ void clif_refresh(struct map_session_data *sd)
|
|
pc_disguise(sd, 0);
|
|
pc_disguise(sd, 0);
|
|
pc_disguise(sd, disguise);
|
|
pc_disguise(sd, disguise);
|
|
}
|
|
}
|
|
|
|
+ clif_refresh_storagewindow(sd);
|
|
}
|
|
}
|
|
|
|
|
|
|
|
|
|
@@ -11301,10 +11330,6 @@ void clif_parse_UseSkillToId(int fd, struct map_session_data *sd)
|
|
sd->state.storage_flag && !(tmp&INF_SELF_SKILL) ) //SELF skills can be used with the storage open, issue: 8027
|
|
sd->state.storage_flag && !(tmp&INF_SELF_SKILL) ) //SELF skills can be used with the storage open, issue: 8027
|
|
return;
|
|
return;
|
|
|
|
|
|
- //Some self skills need to close the storage to work properly
|
|
|
|
- if( skill_id == AL_TELEPORT && sd->state.storage_flag )
|
|
|
|
- storage_storageclose(sd);
|
|
|
|
-
|
|
|
|
if( pc_issit(sd) )
|
|
if( pc_issit(sd) )
|
|
return;
|
|
return;
|
|
|
|
|
|
@@ -11498,7 +11523,8 @@ void clif_parse_UseSkillMap(int fd, struct map_session_data* sd)
|
|
if(skill_id != sd->menuskill_id)
|
|
if(skill_id != sd->menuskill_id)
|
|
return;
|
|
return;
|
|
|
|
|
|
- if( pc_cant_act(sd) ) {
|
|
|
|
|
|
+ //It is possible to use teleport with the storage window open bugreport:8027
|
|
|
|
+ if (pc_cant_act(sd) && !sd->state.storage_flag && skill_id != AL_TELEPORT) {
|
|
clif_menuskill_clear(sd);
|
|
clif_menuskill_clear(sd);
|
|
return;
|
|
return;
|
|
}
|
|
}
|