I just started to interest to the ManiaScript, and I met my first problem, I try to spawn my character.
Code: Select all
#Extends "Modes/ShootMania/ModeBase.Script.txt"
#Const CompatibleMapTypes "SquadArena"
#Const Version "a0.1 (2013-05-27)"
#Const ScriptName "Squad.Script.txt"
#Include "MathLib" as MathLib
#Include "TextLib" as TextLib
#Include "Libs/Nadeo/ShootMania/SM.Script.txt" as SM
***StartServer***
***
log("Squad.Script.txt loaded!");
log("Version: "^Version);
// Set mode options
UseClans = True;
MB_UseSectionRound = True;
***
***StartRound***
***
declare CSmBlockSpawn[Integer] ClanSpawnAnchors = [1=>SM::GetSpawn("SpawnA", 0), 2=>SM::GetSpawn("SpawnB", 0)];
foreach (Player in Players) {
Player.ArmorMax = 3;
//SM::SetPlayerWeapon(Player, 1, True);
SM::SpawnPlayer(Player, Player.RequestedClan, Player.ArmorMax, ClanSpawnAnchors[Player.RequestedClan], Now);
}
***
Void Tmp() {}