mirror of
https://github.com/smartcmd/MinecraftConsoles.git
synced 2026-05-21 01:43:52 +00:00
Initial commit
This commit is contained in:
parent
def8cb4153
commit
b691c43c44
19437 changed files with 4363922 additions and 0 deletions
41
Minecraft.World/ExperienceCommand.cpp
Normal file
41
Minecraft.World/ExperienceCommand.cpp
Normal file
|
|
@ -0,0 +1,41 @@
|
|||
#include "stdafx.h"
|
||||
#include "net.minecraft.commands.h"
|
||||
#include "..\Minecraft.Client\MinecraftServer.h"
|
||||
#include "..\Minecraft.Client\PlayerList.h"
|
||||
#include "ExperienceCommand.h"
|
||||
|
||||
EGameCommand ExperienceCommand::getId()
|
||||
{
|
||||
return eGameCommand_Experience;
|
||||
}
|
||||
|
||||
void ExperienceCommand::execute(shared_ptr<CommandSender> source, byteArray commandData)
|
||||
{
|
||||
//if (args.length > 0)
|
||||
//{
|
||||
// Player player;
|
||||
// int amount = convertArgToInt(source, args[0], 0, 5000);
|
||||
|
||||
// if (args.length > 1) {
|
||||
// player = getPlayer(args[1]);
|
||||
// } else {
|
||||
// player = convertSourceToPlayer(source);
|
||||
// }
|
||||
|
||||
// player.increaseXp(amount);
|
||||
// logAdminAction(source, "commands.xp.success", amount, player.getAName());
|
||||
//}
|
||||
}
|
||||
|
||||
shared_ptr<Player> ExperienceCommand::getPlayer(PlayerUID playerId)
|
||||
{
|
||||
return nullptr;
|
||||
//shared_ptr<Player> player = MinecraftServer::getInstance()->getPlayers()->getPlayer(playerId);
|
||||
|
||||
//if (player == null)
|
||||
//{
|
||||
// throw new PlayerNotFoundException();
|
||||
//} else {
|
||||
// return player;
|
||||
//}
|
||||
}
|
||||
Loading…
Add table
Add a link
Reference in a new issue