public static void serverCmddismountVehicle(GameConnection client) { Player player = client["player"]; Vehicle car = player.getControlObject(); Player passenger = car.getMountNodeObject(0); ((PlayerData)passenger.getDataBlock()).doDismount(passenger); client.setControlObject(player); }
public static void serverCmdflipCar(GameConnection client) { Player player = client["player"]; Vehicle car = player.getControlObject(); if (car.getClassName() != "WheeledVehicle") { return; } TransformF carpos = car.getTransform(); carpos += new TransformF(0, 0, 3); car.setTransform(carpos); }