Breaking Changes - 95.0+

Breaking Changes - 95.0+

Discuss game development here, from a distinct game project to an accessible third-party mutator, down to the interaction and design of individual units if you like.

Moderator: Moderators

User avatar
knorke
Posts: 7971
Joined: 22 Feb 2006, 01:02

Breaking Changes - 95.0+

Post by knorke »

http://springrts.com/wiki/EngineChangelogForContentDevs

When adding something important to that page, just write "bump" in the thread as notification.
User avatar
Forboding Angel
Evolution RTS Developer
Posts: 14673
Joined: 17 Nov 2005, 02:43

Re: Make your game ready for next Spring release!

Post by Forboding Angel »

Might want to mention that someone broke some shit with:

! remove the following Lua consts: wdef[id].areaOfEffect, wdef[id].maxVelocity & wdef[id].onlyTargetCategories
User avatar
zwzsg
Kernel Panic Co-Developer
Posts: 7049
Joined: 16 Nov 2004, 13:08

Re: Make your game ready for next Spring release!

Post by zwzsg »

also wdef[id]:pairs
abma
Spring Developer
Posts: 3798
Joined: 01 Jun 2009, 00:08

Re: Make your game ready for next Spring release!

Post by abma »

*bump*

added removal of "mods" folder & new folder structure.
User avatar
Silentwings
Posts: 3720
Joined: 25 Oct 2008, 00:23

Re: Make your game ready for next Spring release!

Post by Silentwings »

Am I right in thinking that a .sdz/.sd7/.sdd file is read/used in exactly the same way by spring regardless of which content folder it is placed in?
abma
Spring Developer
Posts: 3798
Joined: 01 Jun 2009, 00:08

Re: Make your game ready for next Spring release!

Post by abma »

Silentwings wrote:Am I right in thinking that a .sdz/.sd7/.sdd file is read/used in exactly the same way by spring regardless of which content folder it is placed in?
yep. also should be possible to place a map in the games folder... but please don't do that :)
User avatar
smoth
Posts: 22309
Joined: 13 Jan 2005, 00:46

Re: Make your game ready for next Spring release!

Post by smoth »

Silentwings wrote:Am I right in thinking that a .sdz/.sd7/.sdd file is read/used in exactly the same way by spring regardless of which content folder it is placed in?
maps are mod(ule)s, they just have the maps dir to help organize content
Google_Frog
Moderator
Posts: 2464
Joined: 12 Oct 2007, 09:24

Re: Make your game ready for next Spring release!

Post by Google_Frog »

The weapon indexing change is to be kept http://springrts.com/mantis/view.php?id=3702.

Usernames with underscores in them haven't been able to log in to the wiki since forever.
User avatar
knorke
Posts: 7971
Joined: 22 Feb 2006, 01:02

Re: Make your game ready for next Spring release!

Post by knorke »

^- added.
for wiki login just make new account without the underscore like text in redbox proposes..
User avatar
FLOZi
MC: Legacy & Spring 1944 Developer
Posts: 6240
Joined: 29 Apr 2005, 01:14

Re: Make your game ready for next Spring release!

Post by FLOZi »

knorke wrote:^- added.
for wiki login just make new account without the underscore like text in redbox proposes..
Pretty sure your interpretation is wrong. Scripts won't have to be changed and the 'not-firing' was unintentional and now fixed. Gadgets that use the weapon related functions will need to be altered --> will give obvious luarules crashes.
User avatar
knorke
Posts: 7971
Joined: 22 Feb 2006, 01:02

Re: Make your game ready for next Spring release!

Post by knorke »

yes maybe, didnt really read the mantis report but it seems to have enought info.
Scripts won't have to be changed
only if unit_script.lua basecontent gets changed like this
https://code.google.com/p/zero-k/source ... script.lua ?
in mantis that was suggested (by kingraptor) but idk if it will be done?
User avatar
FLOZi
MC: Legacy & Spring 1944 Developer
Posts: 6240
Joined: 29 Apr 2005, 01:14

Re: Make your game ready for next Spring release!

Post by FLOZi »

User avatar
FLOZi
MC: Legacy & Spring 1944 Developer
Posts: 6240
Joined: 29 Apr 2005, 01:14

Re: Make your game ready for next Spring release!

Post by FLOZi »

Major breaking change - Easy fix

https://github.com/spring/spring/commit ... 22d0a9e9f8

If you use armor.txt -> no change required

If you use armourdefs.lua -> remove the 'conversion snippet' i.e. the following:

Code: Select all

for categoryName, categoryTable in pairs(armorDefs) do
  local t = {}
  for _, unitName in pairs(categoryTable) do
    t[unitName] = 1
  end
  armorDefs[categoryName] = t
end
User avatar
knorke
Posts: 7971
Joined: 22 Feb 2006, 01:02

Re: Make your game ready for next Spring release!

Post by knorke »

(95.0)
added some more:
http://springrts.com/wiki/EngineChangel ... pring_95.0

I added changes from 25 Aug backwards to Aug 09, 2013
The changelog was not updated for a while so it is not complete yet.
Please help looking through the commits, which ones are of interesst for gamedevs wrt breaking things.
User avatar
FLOZi
MC: Legacy & Spring 1944 Developer
Posts: 6240
Joined: 29 Apr 2005, 01:14

Re: Make your game ready for next Spring release!

Post by FLOZi »

Changes to lua API functions controlling Projectiles:

https://github.com/spring/spring/commit ... e51b14dfae

Spring.GetProjectileSpin* functions are deprecated, instead use:

Code: Select all

Spring.GetPieceProjectileParams(number projectileID) -->
    number explosionFlags, number spinAngle, number spinSpeed,
    number spinVector.x, number spinVector.y, number spinVector.z
https://github.com/spring/spring/commit ... 0834eee0ac

GetProjectileTarget now returns a number instead of a string to indicate target-type
GetProjectileTarget now always returns two arguments (if given projectileID is valid)
SetProjectileTarget now takes a number instead of a string to indicate target-type
User avatar
knorke
Posts: 7971
Joined: 22 Feb 2006, 01:02

Re: Breaking Changes - 95.0+

Post by knorke »

User avatar
FLOZi
MC: Legacy & Spring 1944 Developer
Posts: 6240
Joined: 29 Apr 2005, 01:14

Re: Breaking Changes - 95.0+

Post by FLOZi »

Another biggy

https://github.com/spring/spring/commit ... 3246739b0c

After 95.0 the following keys will be nil when accessed from lua (unitdef tags themselves are unchanged):

Code: Select all

    .builder
    .floater
    .canDGun
    .canCrash
    .isCommander
    .moveData
    .type
    .maxSlope


Some are replaced by more is* functions for all unit-types known to Spring; the complete list as of 95.0 is:

Code: Select all

	isTransport
	isImmobile
	isBuilding
	isBuilder
	isMobileBuilder
	isStaticBuilder
	isFactory
	isExtractor
	isGroundUnit
	isAirUnit
	isStrafingAirUnit
	isHoveringAirUnit
	isFighterAirUnit
	isBomberAirUnit
.moveData is replaced with .moveDef which already exists in 94.1
User avatar
Silentwings
Posts: 3720
Joined: 25 Oct 2008, 00:23

Re: Breaking Changes - 95.0+

Post by Silentwings »

I caught a fish: https://github.com/spring/spring/commit ... f4ca63a198 changes aircraft breakrate by a factor of 10. (I think this change was intended only to apply to aircraft but actually a slightly change was applied to all so wait and see what results!)
User avatar
Silentwings
Posts: 3720
Joined: 25 Oct 2008, 00:23

Re: Breaking Changes - 95.0+

Post by Silentwings »

another one: UnitDamaged has projectileID added to its argument list (so it now matches UnitPreDamaged). I updated the callins page on wiki.
Kloot
Spring Developer
Posts: 1867
Joined: 08 Oct 2006, 16:58

Re: Breaking Changes - 95.0+

Post by Kloot »

The following applies only to games that use a custom gadget handler.

For 95.0, you should:

1) remove your copy of callins.lua if not already done (it's deadweight unless your gadgets.lua for some reason does not include the base-content version)

2) in your copy of gadgets.lua, either add local CallInsList = CALLIN_LIST; local CallInsMap = CALLIN_MAP after the Include(... 'callins.lua' ...) line OR replace all references to CallInsList and CallInsMap by CALLIN_LIST and CALLIN_MAP

3) remove the local callInLists = {...} table in your copy of gadgets.lua and replace all references to callInLists by CALLIN_LIST (or by CallInsList depending on your choice in step 2)
Post Reply

Return to “Game Development”