diff options
author | gepard1984 <gepard1984@54d463be-8e91-2dee-dedb-b68131a5f0ec> | 2012-01-11 17:35:28 +0000 |
---|---|---|
committer | gepard1984 <gepard1984@54d463be-8e91-2dee-dedb-b68131a5f0ec> | 2012-01-11 17:35:28 +0000 |
commit | e782bd5f2f7cd73634dfd8616a351a1b97c2109c (patch) | |
tree | 319366658d419bed37df23fc67b1c80957a141f4 /src/map/party.c | |
parent | e18603bb1985d5628f1213999e92eaed8d008eb1 (diff) | |
download | hercules-e782bd5f2f7cd73634dfd8616a351a1b97c2109c.tar.gz hercules-e782bd5f2f7cd73634dfd8616a351a1b97c2109c.tar.bz2 hercules-e782bd5f2f7cd73634dfd8616a351a1b97c2109c.tar.xz hercules-e782bd5f2f7cd73634dfd8616a351a1b97c2109c.zip |
Picklog improvements:
- now it is finally possible to log every item players gain or lose
- added 3 log types: `I` for auctioned items, `B` for buying shop transactions and `X` for all other items transactions that don't fall into another category (for detailed explanation on all log types read `conf/log_athena.conf`)
- it also fixes items being logged as picked up/gained by player when in fact they were dropped on the ground due to full inventory
git-svn-id: https://rathena.svn.sourceforge.net/svnroot/rathena/trunk@15420 54d463be-8e91-2dee-dedb-b68131a5f0ec
Diffstat (limited to 'src/map/party.c')
-rw-r--r-- | src/map/party.c | 9 |
1 files changed, 3 insertions, 6 deletions
diff --git a/src/map/party.c b/src/map/party.c index 87adc6c29..0ddf5c9b9 100644 --- a/src/map/party.c +++ b/src/map/party.c @@ -1033,7 +1033,7 @@ int party_share_loot(struct party_data* p, struct map_session_data* sd, struct i if( (psd = p->data[i].sd) == NULL || sd->bl.m != psd->bl.m || pc_isdead(psd) || (battle_config.idle_no_share && pc_isidle(psd)) ) continue; - if (pc_additem(psd,item_data,item_data->amount)) + if (pc_additem(psd,item_data,item_data->amount,LOG_TYPE_PICKDROP_PLAYER)) continue; //Chosen char can't pick up loot. //Successful pick. @@ -1055,7 +1055,7 @@ int party_share_loot(struct party_data* p, struct map_session_data* sd, struct i } while (count > 0) { //Pick a random member. i = rand()%count; - if (pc_additem(psd[i],item_data,item_data->amount)) + if (pc_additem(psd[i],item_data,item_data->amount,LOG_TYPE_PICKDROP_PLAYER)) { //Discard this receiver. psd[i] = psd[count-1]; count--; @@ -1069,13 +1069,10 @@ int party_share_loot(struct party_data* p, struct map_session_data* sd, struct i if (!target) { target = sd; //Give it to the char that picked it up - if ((i=pc_additem(sd,item_data,item_data->amount))) + if ((i=pc_additem(sd,item_data,item_data->amount,LOG_TYPE_PICKDROP_PLAYER))) return i; } - //Logs items, taken by (P)layers [Lupus] - log_pick_pc(target, LOG_TYPE_PICKDROP_PLAYER, item_data->nameid, item_data->amount, item_data); - if( p && battle_config.party_show_share_picker && battle_config.show_picker_item_type&(1<<itemdb_type(item_data->nameid)) ) clif_party_show_picker(target, item_data); |