summaryrefslogtreecommitdiff
path: root/src/map/pc.c
diff options
context:
space:
mode:
authorFlavioJS <FlavioJS@54d463be-8e91-2dee-dedb-b68131a5f0ec>2007-09-27 15:24:06 +0000
committerFlavioJS <FlavioJS@54d463be-8e91-2dee-dedb-b68131a5f0ec>2007-09-27 15:24:06 +0000
commit61aacc083393bead3227a049b57fb9e76186c7c5 (patch)
tree5872c3c351086969f539a105906568c1f39183b9 /src/map/pc.c
parenta46c1fbcb1b7df32c678af8f0bbfda801d6142dc (diff)
downloadhercules-61aacc083393bead3227a049b57fb9e76186c7c5.tar.gz
hercules-61aacc083393bead3227a049b57fb9e76186c7c5.tar.bz2
hercules-61aacc083393bead3227a049b57fb9e76186c7c5.tar.xz
hercules-61aacc083393bead3227a049b57fb9e76186c7c5.zip
* Loot code using charid's instead of id's in pick priority.
* configure script using svn:eol-style LF and require mysql/pcre when --with-mysql/pcre is used. Added a forgotten file from r11311. (script_commands.txt) Note: charid's are globally unique, id's are equal for characters in the same account. git-svn-id: https://rathena.svn.sourceforge.net/svnroot/rathena/trunk@11312 54d463be-8e91-2dee-dedb-b68131a5f0ec
Diffstat (limited to 'src/map/pc.c')
-rw-r--r--src/map/pc.c14
1 files changed, 7 insertions, 7 deletions
diff --git a/src/map/pc.c b/src/map/pc.c
index 185641915..aafc2260b 100644
--- a/src/map/pc.c
+++ b/src/map/pc.c
@@ -2919,9 +2919,9 @@ int pc_takeitem(struct map_session_data *sd,struct flooritem_data *fitem)
if (sd->status.party_id)
p = party_search(sd->status.party_id);
- if(fitem->first_get_id > 0 && fitem->first_get_id != sd->bl.id)
+ if(fitem->first_get_charid > 0 && fitem->first_get_charid != sd->status.char_id)
{
- first_sd = map_id2sd(fitem->first_get_id);
+ first_sd = map_charid2sd(fitem->first_get_charid);
if(DIFF_TICK(tick,fitem->first_get_tick) < 0) {
if (!(p && p->party.item&1 &&
first_sd && first_sd->status.party_id == sd->status.party_id
@@ -2929,9 +2929,9 @@ int pc_takeitem(struct map_session_data *sd,struct flooritem_data *fitem)
return 0;
}
else
- if(fitem->second_get_id > 0 && fitem->second_get_id != sd->bl.id)
+ if(fitem->second_get_charid > 0 && fitem->second_get_charid != sd->status.char_id)
{
- second_sd = map_id2sd(fitem->second_get_id);
+ second_sd = map_charid2sd(fitem->second_get_charid);
if(DIFF_TICK(tick, fitem->second_get_tick) < 0) {
if(!(p && p->party.item&1 &&
((first_sd && first_sd->status.party_id == sd->status.party_id) ||
@@ -2940,9 +2940,9 @@ int pc_takeitem(struct map_session_data *sd,struct flooritem_data *fitem)
return 0;
}
else
- if(fitem->third_get_id > 0 && fitem->third_get_id != sd->bl.id)
+ if(fitem->third_get_charid > 0 && fitem->third_get_charid != sd->status.char_id)
{
- third_sd = map_id2sd(fitem->third_get_id);
+ third_sd = map_charid2sd(fitem->third_get_charid);
if(DIFF_TICK(tick,fitem->third_get_tick) < 0) {
if(!(p && p->party.item&1 &&
((first_sd && first_sd->status.party_id == sd->status.party_id) ||
@@ -2956,7 +2956,7 @@ int pc_takeitem(struct map_session_data *sd,struct flooritem_data *fitem)
}
//This function takes care of giving the item to whoever should have it, considering party-share options.
- if ((flag = party_share_loot(p,sd,&fitem->item_data, fitem->first_get_id))) {
+ if ((flag = party_share_loot(p,sd,&fitem->item_data, fitem->first_get_charid))) {
clif_additem(sd,0,0,flag);
return 1;
}