summaryrefslogtreecommitdiff
path: root/src/map/party.c
diff options
context:
space:
mode:
authorai4rei <ai4rei@54d463be-8e91-2dee-dedb-b68131a5f0ec>2010-11-28 12:41:26 +0000
committerai4rei <ai4rei@54d463be-8e91-2dee-dedb-b68131a5f0ec>2010-11-28 12:41:26 +0000
commitea5bac422d3d0b257c2f6f877b9780ec20a782ed (patch)
treee0c859e040668371936cebcd228185e4bf849f04 /src/map/party.c
parentf01431ef279c665df0f974e1975baf1f2422398a (diff)
downloadhercules-ea5bac422d3d0b257c2f6f877b9780ec20a782ed.tar.gz
hercules-ea5bac422d3d0b257c2f6f877b9780ec20a782ed.tar.bz2
hercules-ea5bac422d3d0b257c2f6f877b9780ec20a782ed.tar.xz
hercules-ea5bac422d3d0b257c2f6f877b9780ec20a782ed.zip
* Replaced literal constants related to the party booking system with defines.
git-svn-id: https://rathena.svn.sourceforge.net/svnroot/rathena/trunk@14513 54d463be-8e91-2dee-dedb-b68131a5f0ec
Diffstat (limited to 'src/map/party.c')
-rw-r--r--src/map/party.c10
1 files changed, 5 insertions, 5 deletions
diff --git a/src/map/party.c b/src/map/party.c
index f7aca94dd..9e2ee5c7b 100644
--- a/src/map/party.c
+++ b/src/map/party.c
@@ -1123,7 +1123,7 @@ void party_booking_register(struct map_session_data *sd, short level, short mapi
pb_ad->p_detail.level = level;
pb_ad->p_detail.mapid = mapid;
- for(i=0;i<6;i++)
+ for(i=0;i<PARTY_BOOKING_JOBS;i++)
if(job[i] != 0xFF)
pb_ad->p_detail.job[i] = job[i];
else pb_ad->p_detail.job[i] = -1;
@@ -1151,7 +1151,7 @@ void party_booking_update(struct map_session_data *sd, short* job)
pb_ad->starttime = (int)time(NULL);// Update time.
- for(i=0;i<6;i++)
+ for(i=0;i<PARTY_BOOKING_JOBS;i++)
if(job[i] != 0xFF)
pb_ad->p_detail.job[i] = job[i];
else pb_ad->p_detail.job[i] = -1;
@@ -1164,7 +1164,7 @@ void party_booking_search(struct map_session_data *sd, short level, short mapid,
{
struct party_booking_ad_info *pb_ad;
int i, count=0;
- unsigned long index_list[10];
+ unsigned long index_list[PARTY_BOOKING_RESULTS];
bool more_result = false;
DBIterator* iter = party_booking_db->iterator(party_booking_db);
@@ -1174,14 +1174,14 @@ void party_booking_search(struct map_session_data *sd, short level, short mapid,
{
if (pb_ad->index < lastindex || (level && (pb_ad->p_detail.level < level-15 || pb_ad->p_detail.level > level)))
continue;
- if (count >= 10){
+ if (count >= PARTY_BOOKING_RESULTS){
more_result = true;
break;
}
if (mapid == 0 && job == -1)
index_list[count] = pb_ad->index;
else if (mapid == 0) {
- for(i=0; i<6; i++)
+ for(i=0; i<PARTY_BOOKING_JOBS; i++)
if (pb_ad->p_detail.job[i] == job && job != -1)
index_list[count] = pb_ad->index;
} else if (job == -1){