添加sex字段

This commit is contained in:
aozhiwei 2020-12-07 15:49:34 +08:00
parent 2f04f8e796
commit 0dab2c3071
4 changed files with 15 additions and 0 deletions

View File

@ -231,6 +231,9 @@ void Human::FillMFObjectFull(Room* room, Human* hum, cs::MFObjectFull* full_data
if (head != 0) {
p->set_head(head);
}
if (sex != 0) {
p->set_sex(sex);
}
p->set_vip(vip);
p->set_sdmg(sdmg);
p->set_kill_count(stats.kills);
@ -336,6 +339,9 @@ void Human::FillMFPlayerStats(cs::MFPlayerStats* stats_pb)
if (head != 0) {
stats_pb->set_head(head);
}
if (sex != 0) {
stats_pb->set_sex(sex);
}
}
void Human::GetAabbBox(AabbCollider& aabb_box)
@ -407,6 +413,9 @@ void Human::FillMFTeamData(cs::MFTeamData* team_data, bool is_game_over)
if (head != 0) {
team_data->set_head(head);
}
if (sex != 0) {
team_data->set_sex(sex);
}
}
}

View File

@ -65,6 +65,7 @@ class Human : public MoveableEntity
long long guild_id = 0;
int vip_lv = 0;
int head = 0;
int sex = 0;
long long last_cmmove_frameno = 0;
bool downed = false;
bool disconnected = false;

View File

@ -75,6 +75,7 @@ Player* PlayerMgr::CreatePlayerByCMJoin(Player* hum,
hum->guild_id = msg.guild_id();
hum->vip_lv = msg.vip_lv();
hum->head = msg.head();
hum->sex = msg.sex();
#if 0
if (hum->atk_add > 0.9999f) {
hum->atk_add = hum->atk_add / 100.0f;

View File

@ -221,6 +221,7 @@ message MFPlayerFull
optional int32 vip_lv = 35 [default = 0]; //vip等级
optional int32 head = 36 [default = 0]; //
optional int32 sex = 37 [default = 0]; //
//
optional int32 charid = 44; //id
@ -534,6 +535,7 @@ message MFTeamData
optional int64 guild_id = 34; //id
optional int32 vip_lv = 35 [default = 0]; //
optional int32 head = 36 [default = 0]; //
optional int32 sex = 37 [default = 0]; //
}
//
@ -624,6 +626,7 @@ message MFPlayerStats
optional int32 vip_lv = 35 [default = 0]; //
optional int32 head = 36 [default = 0]; //
optional int32 sex = 37 [default = 0]; //
}
//
@ -747,6 +750,7 @@ message CMJoin
optional int64 guild_id = 34; //id
optional int32 vip_lv = 35 [default = 0]; //
optional int32 head = 36 [default = 0]; //
optional int32 sex = 37 [default = 0]; //
optional bool force_entry_newbie_room = 50; //
repeated MFTeamMember team_members = 51; //
optional int32 room_mode = 52; //0: 1: