diff options
author | panikon <panikon@zoho.com> | 2014-04-18 23:02:19 -0300 |
---|---|---|
committer | panikon <panikon@zoho.com> | 2014-04-18 23:02:19 -0300 |
commit | 69ca0aaecc5823dfe273810077c185dff7f20611 (patch) | |
tree | 21bb0cd4f5ce4e4ada42738cdf43f3d5991bd001 /src/map/clif.c | |
parent | c9bc22834a472d4b766586135d4c954c49f736cc (diff) | |
download | hercules-69ca0aaecc5823dfe273810077c185dff7f20611.tar.gz hercules-69ca0aaecc5823dfe273810077c185dff7f20611.tar.bz2 hercules-69ca0aaecc5823dfe273810077c185dff7f20611.tar.xz hercules-69ca0aaecc5823dfe273810077c185dff7f20611.zip |
# Several minor changes in atcommands
1. Reallocated and added checks in @jumpto, @jump, @mapmove in order to increase performance
* Checks are now made to avoid unnecessary lookups and unnecessary warps
2. Corrected return failure values of @zeny
3. Added messages to
* ATclearcart
> Warns that it's not possible to clean a cart while vending
* ATshowmobs
> Asks user to enter a mob name/id and warns if the mob name is invalid
* ATgstorage
> Warns when another guild member is using the gstorage
# Fixed issue where while using storage/gstorage and then refreshing would close the storage
but only for the client, the server wouldn't now and this would cause the guild storage to
remain locked and the character without ability to do anything.
Diffstat (limited to 'src/map/clif.c')
-rw-r--r-- | src/map/clif.c | 20 |
1 files changed, 20 insertions, 0 deletions
diff --git a/src/map/clif.c b/src/map/clif.c index 7715e6c6a..d0fb08486 100644 --- a/src/map/clif.c +++ b/src/map/clif.c @@ -8480,6 +8480,26 @@ void clif_refresh(struct map_session_data *sd) pc->disguise(sd, disguise); } + // 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; + if( (gstor = gstorage->id2storage2(sd->status.guild_id)) == NULL) { + // 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); + } + } + } |