diff options
author | Haru <haru@dotalux.com> | 2014-11-16 06:35:51 +0100 |
---|---|---|
committer | Haru <haru@dotalux.com> | 2014-11-16 07:16:23 +0100 |
commit | 02fcaed6bd32b0ffbc4f03b8f9de6f0720e6253f (patch) | |
tree | 3161fd5786bb563c32059068eb3b4876d2ae11ca /src/char/int_party.c | |
parent | 31bff051ee3c353fb7ee5e544d68feeaefd4941f (diff) | |
download | hercules-02fcaed6bd32b0ffbc4f03b8f9de6f0720e6253f.tar.gz hercules-02fcaed6bd32b0ffbc4f03b8f9de6f0720e6253f.tar.bz2 hercules-02fcaed6bd32b0ffbc4f03b8f9de6f0720e6253f.tar.xz hercules-02fcaed6bd32b0ffbc4f03b8f9de6f0720e6253f.zip |
Whitespace cleanup (no code changes)
This includes, and is not limited to: mixed or wrong indentation, excess
whitespace (horizontal and vertical), misalignment, trailing spaces.
Signed-off-by: Haru <haru@dotalux.com>
Diffstat (limited to 'src/char/int_party.c')
-rw-r--r-- | src/char/int_party.c | 23 |
1 files changed, 10 insertions, 13 deletions
diff --git a/src/char/int_party.c b/src/char/int_party.c index 49873feff..b16f106be 100644 --- a/src/char/int_party.c +++ b/src/char/int_party.c @@ -156,7 +156,7 @@ int inter_party_tosql(struct party *p, int flag, int index) party_db, p->member[index].account_id, p->member[index].char_id, party_id) ) Sql_ShowDebug(inter->sql_handle); } - + if( flag & PS_ADDMEMBER ) {// Add one party member. if( SQL_ERROR == SQL->Query(inter->sql_handle, "UPDATE `%s` SET `party_id`='%d' WHERE `account_id`='%d' AND `char_id`='%d'", @@ -192,7 +192,7 @@ struct party_data *inter_party_fromsql(int party_id) #endif if( party_id <= 0 ) return NULL; - + //Load from memory p = (struct party_data*)idb_get(inter_party->db, party_id); if( p != NULL ) @@ -483,7 +483,7 @@ int mapif_parse_CreateParty(int fd, char *name, int item, int item2, struct part } p = (struct party_data*)aCalloc(1, sizeof(struct party_data)); - + memcpy(p->party.name,name,NAME_LENGTH); p->party.exp=0; p->party.item=(item?1:0)|(item2?2:0); @@ -624,7 +624,7 @@ int mapif_parse_PartyLeave(int fd, int party_id, int account_id, int char_id) inter_party->check_lv(p); } } - + if (inter_party->check_empty(p) == 0) mapif->party_info(-1, &p->party, 0); return 0; @@ -716,13 +716,10 @@ int mapif_parse_PartyLeaderChange(int fd, int party_id, int account_id, int char if(!p) return 0; - for (i = 0; i < MAX_PARTY; i++) - { + for (i = 0; i < MAX_PARTY; i++) { if(p->party.member[i].leader) p->party.member[i].leader = 0; - if(p->party.member[i].account_id == account_id && - p->party.member[i].char_id == char_id) - { + if(p->party.member[i].account_id == account_id && p->party.member[i].char_id == char_id) { p->party.member[i].leader = 1; inter_party->tosql(&p->party,PS_LEADER, i); } @@ -736,8 +733,8 @@ int mapif_parse_PartyLeaderChange(int fd, int party_id, int account_id, int char // Data packet length is set to inter.c that you // Do NOT go and check the packet length, RFIFOSKIP is done by the caller // Return : -// 0 : error -// 1 : ok +// 0 : error +// 1 : ok int inter_party_parse_frommap(int fd) { RFIFOHEAD(fd); @@ -787,7 +784,7 @@ int inter_party_CharOnline(int char_id, int party_id) } if (party_id == 0) return 0; //No party... - + p = inter_party->fromsql(party_id); if(!p) { ShowError("Character %d's party %d not found!\n", char_id, party_id); @@ -833,7 +830,7 @@ int inter_party_CharOffline(int char_id, int party_id) { } if (party_id == 0) return 0; //No party... - + //Character has a party, set character offline and check if they were the only member online if ((p = inter_party->fromsql(party_id)) == NULL) return 0; |