GameID() --> "gameID" - is it really working?

GameID() --> "gameID" - is it really working?

Discuss your problems with the latest release of the engine here. Problems with games, maps or other utilities belong in their respective forums.

Moderator: Moderators

Post Reply
User avatar
PepeAmpere
Posts: 591
Joined: 03 Jun 2010, 01:28

GameID() --> "gameID" - is it really working?

Post by PepeAmpere »

I would expect something in log file when using this:

Code: Select all

function widget:GameID(id)
    Spring.Echo("This is game ID: " .. id)
end
Am I doing something wrong or this is still not supported? (engine log says it is working since spring 89.0, but changelogs are strange fellows ;) )
User avatar
Licho
Zero-K Developer
Posts: 3803
Joined: 19 May 2006, 19:13

Re: GameID() --> "gameID" - is it really working?

Post by Licho »

game id is not set at the start you must wait a bit until frame 1 or so.
abma
Spring Developer
Posts: 3798
Joined: 01 Jun 2009, 00:08

Re: GameID() --> "gameID" - is it really working?

Post by abma »

https://github.com/spring/spring/blob/d ... g.txt#L220

->
https://github.com/spring/spring/commit ... c0d17d874e

seems to be a synced callin? afaik you need to add the callin to the gadgethandler, too.
User avatar
PepeAmpere
Posts: 591
Joined: 03 Jun 2010, 01:28

Re: GameID() --> "gameID" - is it really working?

Post by PepeAmpere »

Licho wrote:game id is not set at the start you must wait a bit until frame 1 or so.
Its calling now (game action), not like before with old Game.gameID where (yes) it was needed to wait till first frames of game.
Post Reply

Return to “Help & Bugs”