I've created a new mini-game via a script with all these properties but none of these properties apply when executed.
function startGame() {
parent::startGame();
$RPG = new ScriptObject(RPG)
{
class = miniGameSO;
brickDamage = false;
brickRespawnTime = 5000;
colorIdx = -1;
enableBuilding = false;
enablePainting = false;
enableWand = false;
fallingDamage = true;
inviteOnly = false;
points_plantBrick = 0;
points_breakBrick = 0;
points_die = 0;
points_killPlayer = 1;
points_killSelf = -1;
playerDatablock = PlayerNoJet;
respawnTime = 0;
selfDamage = true;
playersUseOwnBricks = false;
useAllPlayersBricks = true;
useSpawnBricks = false;
VehicleDamage = true;
vehicleRespawnTime = 10000;
weaponDamage = true;
numMembers = 0;
// Special:
vehicleRunOverDamage = false;
};
}
function GameConnection::SpawnPlayer(%this) {
parent::SpawnPlayer(%this);
%this.player.clearTools();
%this.player.tool[0] = swordItem.getID();
MessageClient(%this, 'MsgItemPickup', '', 0, swordItem.getID() );
}
function serverCmdLeaveMiniGame() { }
function GameConnection::onClientEnterGame(%this) {
parent::onClientEnterGame(%this);
if(%this.miniGame != $RPG) {
$RPG.addMember(%this);
}
%this.player.clearTools();
%this.player.tool[0] = swordItem.getID();
MessageClient(%this, 'MsgItemPickup', '', 0, swordItem.getID());
}