'arm' and 'core' ... Spring.GetTeamInfo

'arm' and 'core' ... Spring.GetTeamInfo

Discuss Lua based Spring scripts (LuaUI widgets, mission scripts, gaia scripts, mod-rules scripts, scripted keybindings, etc...)

Moderator: Moderators

Post Reply
User avatar
Argh
Posts: 10920
Joined: 21 Feb 2005, 03:38

'arm' and 'core' ... Spring.GetTeamInfo

Post by Argh »

Um... Spring.GetTeamInfo reports the name of my "side" as 'arm'. I.E.:

Code: Select all

		for TeamNum = 0,32,1 do
   			_, _, _, _, TeamSide, _ = Spring.GetTeamInfo(TeamNum)
   			if TeamSide ~= nil then
   				Spring.Echo(TeamNum,TeamSide)
			end
		end
...returned

0, arm
1, arm
2, arm...

Moreover, it seems to report both Resistance and Overmind as "arm"... is this a bug in Spring, or am I just doin' it wrong?
User avatar
Peet
Malcontent
Posts: 4384
Joined: 27 Feb 2006, 22:04

Re: 'arm' and 'core' ... Spring.GetTeamInfo

Post by Peet »

Were you running spring from the commanders script in spring.exe perchance?
User avatar
LordMatt
Posts: 3393
Joined: 15 May 2005, 04:26

Re: 'arm' and 'core' ... Spring.GetTeamInfo

Post by LordMatt »

ARM RULZ ALL!!!
User avatar
Argh
Posts: 10920
Joined: 21 Feb 2005, 03:38

Re: 'arm' and 'core' ... Spring.GetTeamInfo

Post by Argh »

Were you running spring from the commanders script in spring.exe perchance?
Yeah, I was... so that's what's up?

<tests running from script.txt>

Ok... so Gaia always gets reported as "arm", and otherwise it works. K, I can just tell my script that if the value of side ~= "Resistance" or "Overmind" then to use the default for Resistance... should work. Thanks!
User avatar
Tribulexrenamed
Posts: 775
Joined: 22 Apr 2008, 19:06

Re: 'arm' and 'core' ... Spring.GetTeamInfo

Post by Tribulexrenamed »

LordMatt wrote:ARM RULZ ALL!!!
My recent tests (at least with my play style) seemed to prove this right. However, levelers are the ultimate kbot killers. Sorry for the off topic.

Is there not a tdf tag for this? I was looking at documentation and I think I saw that somewhere.
Gnomre
Imperial Winter Developer
Posts: 1754
Joined: 06 Feb 2005, 13:42

Re: 'arm' and 'core' ... Spring.GetTeamInfo

Post by Gnomre »

There is, but it's only read when a script.txt is generated (in multiplayer or using springsp I think for example). The start scripts in the spring.exe menu don't read the tdf faction name tags for some dumb reason.
User avatar
Argh
Posts: 10920
Joined: 21 Feb 2005, 03:38

Re: 'arm' and 'core' ... Spring.GetTeamInfo

Post by Argh »

Yeah, I just wrote some simple code that sorts stuff out. I was just puzzled when it returned "arm", when I don't have any "arm" anywhere in my Sidedata.tdf, etc.
Post Reply

Return to “Lua Scripts”