fix(player_command): execution failure (#2503)
This commit is contained in:
parent
461ce57ac6
commit
e6c4a6a1d6
@ -17,7 +17,7 @@ namespace big
|
|||||||
|
|
||||||
virtual void execute(player_ptr player, const command_arguments& _args, const std::shared_ptr<command_context> ctx) override
|
virtual void execute(player_ptr player, const command_arguments& _args, const std::shared_ptr<command_context> ctx) override
|
||||||
{
|
{
|
||||||
g_pickup_service->give_player_health(player->id());
|
g_pickup_service->give_player_ammo(player->id());
|
||||||
}
|
}
|
||||||
};
|
};
|
||||||
|
|
||||||
|
@ -17,7 +17,7 @@ namespace big
|
|||||||
|
|
||||||
virtual void execute(player_ptr player, const command_arguments& _args, const std::shared_ptr<command_context> ctx) override
|
virtual void execute(player_ptr player, const command_arguments& _args, const std::shared_ptr<command_context> ctx) override
|
||||||
{
|
{
|
||||||
g_pickup_service->give_armour(player->id());
|
g_pickup_service->give_player_armour(player->id());
|
||||||
}
|
}
|
||||||
};
|
};
|
||||||
|
|
||||||
|
@ -36,7 +36,7 @@ namespace big
|
|||||||
g_fiber_pool->queue_job([this, args, ctx] {
|
g_fiber_pool->queue_job([this, args, ctx] {
|
||||||
command_arguments new_args(m_num_args.value(), args);
|
command_arguments new_args(m_num_args.value(), args);
|
||||||
|
|
||||||
if (g_player_service->get_self()->id() == args.get<int>(0))
|
if (g_player_service->get_self()->id() == args.get<uint8_t>(0))
|
||||||
{
|
{
|
||||||
execute(g_player_service->get_self(), new_args, ctx);
|
execute(g_player_service->get_self(), new_args, ctx);
|
||||||
return;
|
return;
|
||||||
|
Reference in New Issue
Block a user