移除无用代码
This commit is contained in:
parent
6833e45edd
commit
5f5612e1f1
@ -586,7 +586,9 @@ void Room::CreateHouseObstacle(Building* building, int id, float x, float y)
|
|||||||
|
|
||||||
void Room::CreateObstacle(int id, float x, float y)
|
void Room::CreateObstacle(int id, float x, float y)
|
||||||
{
|
{
|
||||||
|
#if 0
|
||||||
a8::XPrintf("createobstacle %d %f %f\n", {id, x, y});
|
a8::XPrintf("createobstacle %d %f %f\n", {id, x, y});
|
||||||
|
#endif
|
||||||
MetaData::MapThing* thing = MetaMgr::Instance()->GetMapThing(id);
|
MetaData::MapThing* thing = MetaMgr::Instance()->GetMapThing(id);
|
||||||
if (thing) {
|
if (thing) {
|
||||||
Obstacle* entity = new Obstacle();
|
Obstacle* entity = new Obstacle();
|
||||||
@ -997,7 +999,9 @@ void Room::AutoMatchTeam()
|
|||||||
void Room::InitAirDrop()
|
void Room::InitAirDrop()
|
||||||
{
|
{
|
||||||
std::list<MetaData::AirDrop>& air_drops = MetaMgr::Instance()->GetAirDrops();
|
std::list<MetaData::AirDrop>& air_drops = MetaMgr::Instance()->GetAirDrops();
|
||||||
|
#if 0
|
||||||
a8::XPrintf("InitAirdrop %d %d\n", {room_uuid, air_drops.size()});
|
a8::XPrintf("InitAirdrop %d %d\n", {room_uuid, air_drops.size()});
|
||||||
|
#endif
|
||||||
for (auto& air_drop : air_drops) {
|
for (auto& air_drop : air_drops) {
|
||||||
xtimer.AddDeadLineTimerAndAttach(SERVER_FRAME_RATE * air_drop.i->time(),
|
xtimer.AddDeadLineTimerAndAttach(SERVER_FRAME_RATE * air_drop.i->time(),
|
||||||
a8::XParams()
|
a8::XParams()
|
||||||
@ -1009,12 +1013,14 @@ void Room::InitAirDrop()
|
|||||||
{
|
{
|
||||||
Room* room = (Room*)param.sender.GetUserData();
|
Room* room = (Room*)param.sender.GetUserData();
|
||||||
if (!room->game_over) {
|
if (!room->game_over) {
|
||||||
|
#if 0
|
||||||
a8::XPrintf("airdrop %d %d %d\n",
|
a8::XPrintf("airdrop %d %d %d\n",
|
||||||
{
|
{
|
||||||
param.param3,
|
param.param3,
|
||||||
param.param1,
|
param.param1,
|
||||||
param.param2
|
param.param2
|
||||||
});
|
});
|
||||||
|
#endif
|
||||||
room->AirDrop(param.param1, param.param2);
|
room->AirDrop(param.param1, param.param2);
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
@ -1028,11 +1034,13 @@ void Room::AirDrop(int appear_time, int box_id)
|
|||||||
if (thing_meta) {
|
if (thing_meta) {
|
||||||
Vector2D dir = Vector2D::UP;
|
Vector2D dir = Vector2D::UP;
|
||||||
dir.Rotate(a8::RandAngle());
|
dir.Rotate(a8::RandAngle());
|
||||||
|
#if 0
|
||||||
a8::XPrintf("gas_data.pos_new %f %f\n",
|
a8::XPrintf("gas_data.pos_new %f %f\n",
|
||||||
{
|
{
|
||||||
gas_data.pos_new.x,
|
gas_data.pos_new.x,
|
||||||
gas_data.pos_new.y
|
gas_data.pos_new.y
|
||||||
});
|
});
|
||||||
|
#endif
|
||||||
Vector2D box_pos = gas_data.pos_new + dir * (500 + rand() % 300);
|
Vector2D box_pos = gas_data.pos_new + dir * (500 + rand() % 300);
|
||||||
::google::protobuf::RepeatedPtrField<::cs::MFAirDrop>* airdrops = nullptr;
|
::google::protobuf::RepeatedPtrField<::cs::MFAirDrop>* airdrops = nullptr;
|
||||||
{
|
{
|
||||||
|
Loading…
x
Reference in New Issue
Block a user