MantisBT - Soldat Dedicated Server
View Issue Details
0000386Soldat Dedicated ServerScripting Corepublic2013-08-14 18:102013-12-26 00:07
DorkeyDear 
ExHunter 
highminoralways
resolvedfixed 
 
2.7.7 
0000386: SC3 TTeam.ID returns player identifier in TTeam.OnJoin event
In the TTeam.OnJoin event, TTeam.ID returns the player identifier that joined the team. It should be the team number/identifier (0-5).
procedure OnJoinTeam(const Player: TPlayer; const Team: TTeam);
begin
    WriteLn('Player.Team=' + InttoStr(Player.Team));
    WriteLn('Team.Id=' + InttoStr(Team.Id));
    WriteLn('');
end;

var i: byte;
begin
    for i := 0 to 5 do Game.Teams[i].OnJoin := @OnJoinTeam;
end.

-----

Join the empty game on any team. It will say Team.Id=1. Adding bots, and /setteam`ing them shows this applies for bots and other player ids too.
No tags attached.
child of 0000415resolved ExHunter Game.Teams[i].OnJoin is replacing Game.OnJoin and is nto working as intended 
Issue History
2013-08-14 18:10DorkeyDearNew Issue
2013-09-09 15:45FalconStatusnew => acknowledged
2013-12-26 00:06ExHunterRelationship addedchild of 0000415
2013-12-26 00:07ExHunterAssigned To => ExHunter
2013-12-26 00:07ExHunterStatusacknowledged => assigned
2013-12-26 00:07ExHunterNote Added: 0002098
2013-12-26 00:07ExHunterStatusassigned => resolved
2013-12-26 00:07ExHunterFixed in Version => 2.7.7
2013-12-26 00:07ExHunterResolutionopen => fixed

Notes
(0002098)
ExHunter   
2013-12-26 00:07   
Was fixed with bug 0000415 together.