View Issue Details [ Jump to Notes ] | [ Issue History ] [ Print ] | ||||||||
ID | Project | Category | View Status | Date Submitted | Last Update | ||||
---|---|---|---|---|---|---|---|---|---|
0004113 | Spring engine | General | public | 2013-11-03 21:58 | 2013-11-04 14:00 | ||||
Reporter | silentwings | ||||||||
Assigned To | Kloot | ||||||||
Priority | normal | Severity | major | Reproducibility | always | ||||
Status | closed | Resolution | unable to reproduce | ||||||
Product Version | 94.1.1+git | ||||||||
Target Version | Fixed in Version | ||||||||
Summary | 0004113: when hosting an AI team, GetMyPlayerID and GetMyTeamID return the pID,tID of the AI | ||||||||
Description | heres what I was doing: i hosted a battle, 2 allyteams, first allyteam contained just me, second allyteam contained one human player and a NullAI hosted by me. once ingame, when i called Spring.GetMy***ID(), it returned the information relating to the AI i was hosting and not my own info. | ||||||||
Additional Information | it might have mattered that the AI had a numerically lower pID and tID than me? | ||||||||
Tags | No tags attached. | ||||||||
Checked infolog.txt for Errors | |||||||||
Attached Files |
|
![]() |
|
silentwings (reporter) 2013-11-03 21:59 Last edited: 2013-11-03 22:03 |
this was with Spring 94.1.1-1452 and latest SL dev build |
silentwings (reporter) 2013-11-03 22:17 Last edited: 2013-11-03 22:18 |
correction: GetMyPlayerID seems to return correctly, GetMyTeamID returned the AIs teamID |
Kloot (developer) 2013-11-03 22:32 |
Sounds like myTeam is set twice, once for you and once for the AI hosted by you. Look in infolog if there is more than one "User number %i (team %i, allyteam %i)" message to confirm this. |
silentwings (reporter) 2013-11-03 22:35 Last edited: 2013-11-03 22:47 |
There's only one such message in the infolog but the teamID it gives corresponds to the AIs team. I tried: local myPlayerID = Spring.GetMyPlayerID() local _,_,_,myTeamID = Spring.GetPlayerInfo(myPlayerID) but this gives the same incorrect teamID as Spring.GetMyTeamID() |
silentwings (reporter) 2013-11-03 22:42 |
script.txt is http://pastebin.com/eEqKfQip I spotted that two teams that have different allyTeams are given the same teamleader - that strikes me as a bit odd? |
Kloot (developer) 2013-11-03 23:09 |
Somewhat, the leader is the player "in charge" of a team (not allyteam). For AI teams (friend or foe) hosted on the same machine that gets weird but it shouldn't affect one's team number, AI's cannot displace humans. According to the script three teams should have spawned, I assume that still happened normally? player 1 in team 1 in allyteam 1 player 2 in team 2 in allyteam 0 "player" 3 (AI 0) in team 0 in allyteam 1 |
silentwings (reporter) 2013-11-03 23:29 |
yes the alliances were correct & all three spawned it seems non-reproducable after closing and re-opening my battle, no matter how many AIs i add :/ if i can make it happen again i'll re-post |
abma (administrator) 2013-11-03 23:43 |
https://github.com/spring/spring/commit/28987712f5fd0432929e74d24dd8bff2f3313617 |
![]() |
|||
Date Modified | Username | Field | Change |
---|---|---|---|
2013-11-03 21:58 | silentwings | New Issue | |
2013-11-03 21:59 | silentwings | Note Added: 0011951 | |
2013-11-03 22:03 | silentwings | Note Edited: 0011951 | View Revisions |
2013-11-03 22:17 | silentwings | Note Added: 0011954 | |
2013-11-03 22:18 | silentwings | Note Edited: 0011954 | View Revisions |
2013-11-03 22:32 | Kloot | Note Added: 0011955 | |
2013-11-03 22:35 | silentwings | Note Added: 0011956 | |
2013-11-03 22:35 | silentwings | Note Edited: 0011956 | View Revisions |
2013-11-03 22:37 | silentwings | Note Edited: 0011956 | View Revisions |
2013-11-03 22:42 | silentwings | Note Added: 0011957 | |
2013-11-03 22:47 | silentwings | Note Edited: 0011956 | View Revisions |
2013-11-03 23:09 | Kloot | Note Added: 0011960 | |
2013-11-03 23:29 | silentwings | Note Added: 0011961 | |
2013-11-03 23:43 | abma | Note Added: 0011962 | |
2013-11-04 14:00 | Kloot | Status | new => closed |
2013-11-04 14:00 | Kloot | Assigned To | => Kloot |
2013-11-04 14:00 | Kloot | Resolution | open => unable to reproduce |