[Legacy C++ API] How can i set share m/e level?
Moderators: hoijui, Moderators
[Legacy C++ API] How can i set share m/e level?
How can i set share m/e level? I see no functions. I would use SendResources() if i could read m/e values of allied players.
Re: [Legacy C++ API] How can i set share m/e level?
had a look, and it would need a new network message (eg NETMSG_AISETSHARE), for the same reason we already have a NETMSGAISHARE. the normal SETSHARE uses myPlayerNum, and so only works for players, not AIs. of course this is some ugly internal sturcture.. we should have AI and player share a common parent class in lots of places...
in short: not very easy :/
in short: not very easy :/
Re: [Legacy C++ API] How can i set share m/e level?
Ok, if its hard can you implement reading m/e storage and actual values of allied players/AIs? Or is it hard too?
Re: [Legacy C++ API] How can i set share m/e level?
done, please test it with this build:
http://springrts.com/dl/buildbot/defaul ... -g1f664b6/
commit:
http://github.com/spring/spring/commit/ ... 852a#L2R63
http://springrts.com/dl/buildbot/defaul ... -g1f664b6/
commit:
http://github.com/spring/spring/commit/ ... 852a#L2R63
Re: [Legacy C++ API] How can i set share m/e level?
Thanks. Is there no mistake: spring_0.82.3-252-g1f664b6.exe ? It's 0.82.3 in the name, not 0.82.5.
PS. Also i do not see a function which can enumerate all teams in the game. Am i right that it is normal that i should get all units at game start then use GetUnitTeam() for each one? It is suitable for beginning of the game, not mid-game join.
PS. Also i do not see a function which can enumerate all teams in the game. Am i right that it is normal that i should get all units at game start then use GetUnitTeam() for each one? It is suitable for beginning of the game, not mid-game join.
Re: [Legacy C++ API] How can i set share m/e level?
the name should be spring_0.82.0 still (in master), but due to some mergeing, it is now 0.82.3. that is all there is wrong, the number.
fetching teams:
http://springrts.com/mantis/view.php?id=2101
fetching teams:
http://springrts.com/mantis/view.php?id=2101
Re: [Legacy C++ API] How can i set share m/e level?
has at least one bug in the above version, will fix...