1.17.0: Difference between revisions

From Vintage Story Wiki
324 bytes removed ,  10 months ago
 
(One intermediate revision by the same user not shown)
Line 255: Line 255:
*Tweak: Disabled span ruins, they need better spawning behaviors
*Tweak: Disabled span ruins, they need better spawning behaviors
*Tweak: Torches and other blocks which attach to the side of other blocks, now cannot be attached to lake ice (even if they could before)
*Tweak: Torches and other blocks which attach to the side of other blocks, now cannot be attached to lake ice (even if they could before)
*Fixed: Multiple issues with snow coverage on chiseled blocks


==Fixed==
==Fixed==


    Fixed: Dark shadows caused from SSAO, might break other things
*Fixed: Multiple issues with snow coverage on chiseled blocks
    Fixed: Pristine forlorn body armor can now be properly crafted.
*Fixed: Dark shadows caused from SSAO, might break other things
    Fixed: Wooden path block texture issues
*Fixed: Pristine forlorn body armor can now be properly crafted.
    Fixed: Cinematic camera crash when adding 2 points at the same coords
*Fixed: Wooden path block texture issues
    Fixed: Multiple issues with the immersive first person mode (clip into blocks upon death, not adjusted for running sideways swivel, etc.)
*Fixed: Cinematic camera crash when adding 2 points at the same coords
    Fixed: Heavy z-fighting on distant ice
*Fixed: Multiple issues with the immersive first person mode (clip into blocks upon death, not adjusted for running sideways swivel, etc.)
    Fixed: Falling containers now drop their contents if they cannot be placed on impact
*Fixed: Heavy z-fighting on distant ice
    Fixed: handbook entry for labeled chests, and links to it in chalk and charcoal descriptions
*Fixed: Falling containers now drop their contents if they cannot be placed on impact
    Fixed: (long-standing!) leaves blocks incorrectly had a 0 degrees rotated alternate as well as 10 degrees
*Fixed: handbook entry for labeled chests, and links to it in chalk and charcoal descriptions
    Fixed: (since 1.16) blocks with general wind motion flag were incorrectly given a glow value (e.g. glow == 3)
*Fixed: (long-standing!) leaves blocks incorrectly had a 0 degrees rotated alternate as well as 10 degrees
    Fixed: (since 1.14) leaves ground-offset windshear being disabled for leaves against solid blocks was not working correctly on north side
*Fixed: (since 1.16) blocks with general wind motion flag were incorrectly given a glow value (e.g. glow == 3)
    Fixed: Unknown texture when putting solder ingots on forges
*Fixed: (since 1.14) leaves ground-offset windshear being disabled for leaves against solid blocks was not working correctly on north side
    Fixed: Wrong glow vfx for items held in third person mode
*Fixed: Unknown texture when putting solder ingots on forges
    Fixed: In single-player, occasional flash of X-ray vision when breaking blocks underground at any chunk edge
*Fixed: Wrong glow vfx for items held in third person mode
    Fixed: Should fix stability issues when using the game updater, due to leftover files that should no longer be there
*Fixed: In single-player, occasional flash of X-ray vision when breaking blocks underground at any chunk edge
    Fixed: TempstormDurationMul world config not working
*Fixed: Should fix stability issues when using the game updater, due to leftover files that should no longer be there
    Fixed: Some roofing faces too dark; trough fluffy hay faces too dark.
*Fixed: TempstormDurationMul world config not working
    Fixed: Particle collision box issues with the boiler
*Fixed: Some roofing faces too dark; trough fluffy hay faces too dark.
    Fixed: Water in condenser hardly visible
*Fixed: Particle collision box issues with the boiler
    Fixed: Placing fruit trees with worldedit did not respect the size values
*Fixed: Water in condenser hardly visible
    Fixed: Tool molds rotations during clayforming not matching finished product in some cases
*Fixed: Placing fruit trees with worldedit did not respect the size values
    Fixed: Sealed barrels displayed block interaction help
*Fixed: Tool molds rotations during clayforming not matching finished product in some cases
    Fixed: Drifter killing drifter showed "eaten by" in the info text
*Fixed: Sealed barrels displayed block interaction help
    Fixed: Wrong SSAO on knapping surface
*Fixed: Drifter killing drifter showed "eaten by" in the info text
    Fixed: Pullets changing plumage when they mature to adults
*Fixed: Wrong SSAO on knapping surface
    Fixed: Wrong texture resolution on some bamboo leaves
*Fixed: Pullets changing plumage when they mature to adults
    Fixed: .clientconfigcreate not printing error on invalid datatype
*Fixed: Wrong texture resolution on some bamboo leaves
    Fixed: Some lighting chunk border issues when rooms are closed or opened to sunlight
*Fixed: .clientconfigcreate not printing error on invalid datatype
    Fixed: Various minor sunlighting bugs (eg. wrong values below water which spreads)
*Fixed: Some lighting chunk border issues when rooms are closed or opened to sunlight
    Tweak: for Linux users, starting the game using Mono versions prior to Mono 5 should now fail (Mono 4.x and below is not supported)
*Fixed: Various minor sunlighting bugs (eg. wrong values below water which spreads)
    Translation:
*Tweak: for Linux users, starting the game using Mono versions prior to Mono 5 should now fail (Mono 4.x and below is not supported)
        Fixed: lang strings for some item info such as clothing and armor properties
*Translation:
        Added lang strings for some colors
**Fixed: lang strings for some item info such as clothing and armor properties
**Added lang strings for some colors
   
   
==API Changes==
==API Changes==


    Tweak: All code obfuscation now been completely dropped from the game engine
*Tweak: All code obfuscation now been completely dropped from the game engine
    Feature: Greatly improved frame profiler and slow tick logging.
*Feature: Greatly improved frame profiler and slow tick logging.
        Instead of a flat list, frame costs are now displayed hierarchically and also show the call count. Allows for a much more fine grained analysis of costly operations / laggy sections of code.
**Instead of a flat list, frame costs are now displayed hierarchically and also show the call count. Allows for a much more fine grained analysis of costly operations / laggy sections of code.
        Added new FrameProfiler.Enter() and .Leave() methods for hierarchical tick logging
**Added new FrameProfiler.Enter() and .Leave() methods for hierarchical tick logging
    Feature: New "OnAnimationEnd" Mode EaseOut. Greatly helps with jerky animation endings
*Feature: New "OnAnimationEnd" Mode EaseOut. Greatly helps with jerky animation endings
    Feature: Shape.TryGet(api, fileLocation) method simplifies code for loading shapes and adds consistent error checking
*Feature: Shape.TryGet(api, fileLocation) method simplifies code for loading shapes and adds consistent error checking
    Feature: still and flowing water blocks, and lake ice blocks, are now accessed separately from regular blocks, as there can be both water and a regular (non-solid) block in the same BlockPos position
*Feature: still and flowing water blocks, and lake ice blocks, are now accessed separately from regular blocks, as there can be both water and a regular (non-solid) block in the same BlockPos position
        Use IBlockAccessor.GetLiquidBlock(), IBlockAccessor.SetLiquidBlock(), IBlockAccessor.SearchLiquidBlocks() for reading and writing water and lake ice
**Use IBlockAccessor.GetLiquidBlock(), IBlockAccessor.SetLiquidBlock(), IBlockAccessor.SearchLiquidBlocks() for reading and writing water and lake ice
        There are also IWorldChunk.GetLiquid() and .SetLiquid() methods, but mods should generally use the IBlockAccessor methods
**There are also IWorldChunk.GetLiquid() and .SetLiquid() methods, but mods should generally use the IBlockAccessor methods
        IBlockAccessor.GetSolidBlock() will return the regular block at the position UNLESS there is lake ice present in which case it will return the lake ice (used e.g. for motion physics and collision detection)
**IBlockAccessor.GetSolidBlock() will return the regular block at the position UNLESS there is lake ice present in which case it will return the lake ice (used e.g. for motion physics and collision detection)
        IBlockAccessor.IsSideSolid() behaves similarly: tests the regular block at the position for solidity, or will return true if lake ice is present
**IBlockAccessor.IsSideSolid() behaves similarly: tests the regular block at the position for solidity, or will return true if lake ice is present
        to generalise, mods can add their own blocks (liquids, gasses or perhaps ice) to the new system allowing regular blocks to be submerged/enclosed/embedded in such blocks: this is done simply by overriding property Block.ForLiquidsLayer in the code for the liquid/gas/ice block
**to generalise, mods can add their own blocks (liquids, gasses or perhaps ice) to the new system allowing regular blocks to be submerged/enclosed/embedded in such blocks: this is done simply by overriding property Block.ForLiquidsLayer in the code for the liquid/gas/ice block
        For existing 1.16 blocks which are found in water or in ice (e.g. in vanilla, Coopers Reeds or Papyrus, which have -water- and -ice- variants, or Seaweed) you can update to the new system as follows: (a) remove the rendering of water and ice and any special water and ice properties from your block, the in-water variant should now be the same as the on-land variant; (b) for the in-water or in-ice variants only, for successful updating from 1.16 to 1.17, override property Block.RemapToLiquidsLayer to provide the water/ice code matching your block, e.g. Reeds in water set that property to "water-still-7"
**For existing 1.16 blocks which are found in water or in ice (e.g. in vanilla, Coopers Reeds or Papyrus, which have -water- and -ice- variants, or Seaweed) you can update to the new system as follows: (a) remove the rendering of water and ice and any special water and ice properties from your block, the in-water variant should now be the same as the on-land variant; (b) for the in-water or in-ice variants only, for successful updating from 1.16 to 1.17, override property Block.RemapToLiquidsLayer to provide the water/ice code matching your block, e.g. Reeds in water set that property to "water-still-7"
        BlockUpdate and Schematic now have water data in them in addition to block data
**BlockUpdate and Schematic now have water data in them in addition to block data
        Mods needing to test for the presence of water or lake ice should change their code to use the IBlockAccessor.GetLiquidBlock() call
**Mods needing to test for the presence of water or lake ice should change their code to use the IBlockAccessor.GetLiquidBlock() call
        Mods needing to test whether a neighbour side is solid should use IBlockAccessor.IsSideSolid() to detect all cases accurately, including e.g. stones embedded in lake ice
**Mods needing to test whether a neighbour side is solid should use IBlockAccessor.IsSideSolid() to detect all cases accurately, including e.g. stones embedded in lake ice
        To minimise the breaking of existing 1.16 mods, IBlockAccessor.GetBlock() will still return the water/lakeice block at a position if there is no block submerged/embedded in it - but if there is a block submerged in water (or embedded in lakeice) then .GetBlock() will return the submerged block, so that mods which do not update their code to use a .GetLiquidBlock() call will not see that there is water in the position, if a block happens to be submerged there
**To minimise the breaking of existing 1.16 mods, IBlockAccessor.GetBlock() will still return the water/lakeice block at a position if there is no block submerged/embedded in it - but if there is a block submerged in water (or embedded in lakeice) then .GetBlock() will return the submerged block, so that mods which do not update their code to use a .GetLiquidBlock() call will not see that there is water in the position, if a block happens to be submerged there
        To minimise the breaking of existing 1.16 mods, IBlockAccessor.SetBlock() used with a water/lakeice block (or any block for which Block.ForLiquidsLayer is true) will automatically write that block to the liquids layer, and will delete any existing regular block at the position (i.e. the same behavior as in 1.16 code).  To add water/lakeice to a block position without deleting the regular block (i.e. allowing the existing block at the position to become submerged in water or embedded in ice) use IBlockAccessor.SetLiquidBlock()
**To minimise the breaking of existing 1.16 mods, IBlockAccessor.SetBlock() used with a water/lakeice block (or any block for which Block.ForLiquidsLayer is true) will automatically write that block to the liquids layer, and will delete any existing regular block at the position (i.e. the same behavior as in 1.16 code).  To add water/lakeice to a block position without deleting the regular block (i.e. allowing the existing block at the position to become submerged in water or embedded in ice) use IBlockAccessor.SetLiquidBlock()
        Placing a fully solid block in any position will remove the water/lakeice at that position
**Placing a fully solid block in any position will remove the water/lakeice at that position
    Feature: Missing lang file keys are logged in client-debug.txt (and sometimes in server-debug.txt but that is rare)
*Feature: Missing lang file keys are logged in client-debug.txt (and sometimes in server-debug.txt but that is rare)
    Feature: Added <hk> or <hotkey> VTML tag. In handbook entries, can use e.g. <hk>sprint</hk> to display the actual current mapping of the sprint key
*Feature: Added <hk> or <hotkey> VTML tag. In handbook entries, can use e.g. <hk>sprint</hk> to display the actual current mapping of the sprint key
    Feature: for any keyboard controls (hotkeys) your mod adds, use new EnumHotkeyTypes: HelpAndOverlays, MouseModifiers, MovementControls and InventoryHotkeys for better grouping in the keyboard controls settings dialog
*Feature: for any keyboard controls (hotkeys) your mod adds, use new EnumHotkeyTypes: HelpAndOverlays, MouseModifiers, MovementControls and InventoryHotkeys for better grouping in the keyboard controls settings dialog
    Feature: Configurable inventory slot count for entity harvesting
*Feature: Configurable inventory slot count for entity harvesting
    Feature: IServerWorldAccessor.IsFullyLoadedChunk(), true if all neighbor chunks are also loaded.  BlockEntities or entities can use this during tick updates for better performance, e.g. to make sure that searching neighbor chunks for blocks will not cause lag-spikes due to loading unloaded chunks.  See BEBerryBush and BEFarmland for example
*Feature: IServerWorldAccessor.IsFullyLoadedChunk(), true if all neighbor chunks are also loaded.  BlockEntities or entities can use this during tick updates for better performance, e.g. to make sure that searching neighbor chunks for blocks will not cause lag-spikes due to loading unloaded chunks.  See BEBerryBush and BEFarmland for example
    Feature: Added api.XXXAtlas.GetOrInsertTexture() to replace InsertTextureCached() which is now obsolete, as it is very inefficient
*Feature: Added api.XXXAtlas.GetOrInsertTexture() to replace InsertTextureCached() which is now obsolete, as it is very inefficient
    Refactor: Collectible.GetDurability() is now renamed to Collectible.GetMaxDurability(). Added Collectible.GetRemainingDurability()
*Refactor: Collectible.GetDurability() is now renamed to Collectible.GetMaxDurability(). Added Collectible.GetRemainingDurability()
    Refactor: QueueOfInt and FastSetOfLongs moved to Vintagestory.API.Datastructures  
*Refactor: QueueOfInt and FastSetOfLongs moved to Vintagestory.API.Datastructures  
    Tweak: ModMaker should place patches into a separate mod domain (will now also prompt for the mod domain)
*Tweak: ModMaker should place patches into a separate mod domain (will now also prompt for the mod domain)
    Tweak: PlayerControl.CtrlKey and PlayerControl.ShiftKey, use these for block and entity interactions which depend on Ctrl+mouseclick or Shift+mouseclick, in place of checking for Sprint and Sneak keys  (though by default Sprint is bound to Ctrl, and Sneak is bound to Shift, a player might change that)
*Tweak: PlayerControl.CtrlKey and PlayerControl.ShiftKey, use these for block and entity interactions which depend on Ctrl+mouseclick or Shift+mouseclick, in place of checking for Sprint and Sneak keys  (though by default Sprint is bound to Ctrl, and Sneak is bound to Shift, a player might change that)
    Tweak: Significantly re-order and properly ensure order of asset registration etc during server startup, for details of correct use, see updated descriptions in the XML help for ModSystem methods .ExecuteOrder(), .StartPre(), .Start(), .AssetsLoaded(), .StartClientSide() and .StartServerSide()
*Tweak: Significantly re-order and properly ensure order of asset registration etc during server startup, for details of correct use, see updated descriptions in the XML help for ModSystem methods .ExecuteOrder(), .StartPre(), .Start(), .AssetsLoaded(), .StartClientSide() and .StartServerSide()
        ModSystem .Start() method may be called at a different time from previously, specifically it will now be called even before assets (including blocktypes, lang file, etc.) have been loaded; any of your code in Start() which requires assets to be loaded may need to be moved to the AssetsLoaded() method
** ModSystem .Start() method may be called at a different time from previously, specifically it will now be called even before assets (including blocktypes, lang file, etc.) have been loaded; any of your code in Start() which requires assets to be loaded may need to be moved to the AssetsLoaded() method
        Additional optional initialisation call ModSystem.AssetsLoaded() called after the Start() method and after assets are loaded, but before StartClientSide/StartServerSide.  This is called on both server and client, see VSSurvivalMod Core.cs for an example.  Typically used to initialise block or item fields
**Additional optional initialisation call ModSystem.AssetsLoaded() called after the Start() method and after assets are loaded, but before StartClientSide/StartServerSide.  This is called on both server and client, see VSSurvivalMod Core.cs for an example.  Typically used to initialise block or item fields
        New server event AssetsFinalizers, can be used in code to modify/finalize behaviors or properties for any block or item in the game (your mod's assets or another mod's assets) after all loading from JSONs is complete. Use this in 1.17+ instead of making changes to assets in a mod's StartServerSide() method - doing it in the StartServerSide() method will likely be too late.  E.g. in vanilla, the BlockReinforcement system adds a Reinforcement behavior to every appropriate block in this event
**New server event AssetsFinalizers, can be used in code to modify/finalize behaviors or properties for any block or item in the game (your mod's assets or another mod's assets) after all loading from JSONs is complete. Use this in 1.17+ instead of making changes to assets in a mod's StartServerSide() method - doing it in the StartServerSide() method will likely be too late.  E.g. in vanilla, the BlockReinforcement system adds a Reinforcement behavior to every appropriate block in this event
    Tweak: Added callback method Collectible.ConsumeCraftingIngredients()
*Tweak: Added callback method Collectible.ConsumeCraftingIngredients()
    Tweak: Added ability to disable entity behaviors and AI tasks by adding a `enabled: false` line (can also do this byType)
*Tweak: Added ability to disable entity behaviors and AI tasks by adding a `enabled: false` line (can also do this byType)
    Tweak: Added "ShowInCreatedBy" property for recipes to hide them from the handbook (such as repair recipes)
*Tweak: Added "ShowInCreatedBy" property for recipes to hide them from the handbook (such as repair recipes)
    Tweak: IBlockAccessor.WalkBlocks() Action now offers int x,y,z coordinates instead of a BlockPos
*Tweak: IBlockAccessor.WalkBlocks() Action now offers int x,y,z coordinates instead of a BlockPos
    Tweak: Cuboidd new method SetAndTranslate() allows both operations to be combined in a single method call
*Tweak: Cuboidd new method SetAndTranslate() allows both operations to be combined in a single method call
    Tweak: Vec3d can now be Set() to an EntityPos
*Tweak: Vec3d can now be Set() to an EntityPos
    Tweak: BlockPos new method SetAndEquals() returns a boolean indicating whether the BlockPos already held the values set
*Tweak: BlockPos new method SetAndEquals() returns a boolean indicating whether the BlockPos already held the values set
    Tweak: Can now define separate player animations to be run in immersive first person mode (by prefixing them with "ifp-").
*Tweak: Can now define separate player animations to be run in immersive first person mode (by prefixing them with "ifp-").
    Tweak: Chisel tool modes are now a bit more moddable
*Tweak: Chisel tool modes are now a bit more moddable
    Tweak: Block.SideSolid is now a custom class, SmallBoolArray
*Tweak: Block.SideSolid is now a custom class, SmallBoolArray
    Tweak: ShapeElement.Faces is now deprecated: use .FacesResolved instead if you need to access a ShapeElementFace
*Tweak: ShapeElement.Faces is now deprecated: use .FacesResolved instead if you need to access a ShapeElementFace
    Tweak: Block.Textures and .TexturesInventory are now IDictionary<> not Dictionary<>  (but in most cases existing code should not need to be changed)
*Tweak: Block.Textures and .TexturesInventory are now IDictionary<> not Dictionary<>  (but in most cases existing code should not need to be changed)
    Tweak: EntityClientProperties.Textures is now IDictionary<> not Dictionary<>  (but in most cases existing code should not need to be changed)
*Tweak: EntityClientProperties.Textures is now IDictionary<> not Dictionary<>  (but in most cases existing code should not need to be changed)
    Tweak: Block.SideSolid is now a SmallBoolArray struct, not a bool[]  (but in most cases existing code should not need to be changed, e.g. Block.SideSolid[0] will still test the North face)
*Tweak: Block.SideSolid is now a SmallBoolArray struct, not a bool[]  (but in most cases existing code should not need to be changed, e.g. Block.SideSolid[0] will still test the North face)
    Tweak: Can now define particle Bounciness as a float value (before it was a boolean)
*Tweak: Can now define particle Bounciness as a float value (before it was a boolean)
    Tweak: "Weak shiny" mode. If the shiny bit is set and any wind data is set, the shinyness effect is reduced
*Tweak: "Weak shiny" mode. If the shiny bit is set and any wind data is set, the shinyness effect is reduced
    Tweak: New basic flower shapes flower-48x48 and flower-32x64, drawn with correct pixel density, see the creative-only Dandelion and Acanthus flowers as examples  (modders can test new flower textures in-game by replacing the dandelion and acanthus textures)
*Tweak: New basic flower shapes flower-48x48 and flower-32x64, drawn with correct pixel density, see the creative-only Dandelion and Acanthus flowers as examples  (modders can test new flower textures in-game by replacing the dandelion and acanthus textures)
    Tweak: two new DrawTypes which appropriate blocks can use for instanced rendering, for higher FPS: InstancedCross (used by tallgrass, flower-horsetail, and flower-edelweiss) and InstancedFlower (used by catmint, cow parsley, poppy, redtop grass, wild daisy and woad).  Where InstancedFlower is used, petal and stem textures should be combined into one double-width .png file, see the texture files for those flowers for examples
*Tweak: two new DrawTypes which appropriate blocks can use for instanced rendering, for higher FPS: InstancedCross (used by tallgrass, flower-horsetail, and flower-edelweiss) and InstancedFlower (used by catmint, cow parsley, poppy, redtop grass, wild daisy and woad).  Where InstancedFlower is used, petal and stem textures should be combined into one double-width .png file, see the texture files for those flowers for examples
    Tweak: The Modmaker will now work on pre-releases of the game
*Tweak: The Modmaker will now work on pre-releases of the game
    Tweak: Rewrite head yaw/pitch handling, now part of EntityPos and synced.
*Tweak: Rewrite head yaw/pitch handling, now part of EntityPos and synced.
    Fixed: Cuboidf.RotatedCopy() not rotating hitboxes correctly
*Fixed: Cuboidf.RotatedCopy() not rotating hitboxes correctly
    Fixed: Positioning issues in VTML/richtext
*Fixed: Positioning issues in VTML/richtext
    Fixed: Compatibility util did not work on first world load
*Fixed: Compatibility util did not work on first world load


== References ==
== References ==


# [https://www.vintagestory.at/blog.html/news/de-jank-and-game-juice-update-1170-pre1-r322/|"De-Jank and Game Juice Update (1.17.0-pre.1)"
# [https://www.vintagestory.at/blog.html/news/de-jank-and-game-juice-update-1170-pre1-r322/|"De-Jank and Game Juice Update (1.17.0-pre.1)"
Confirmedusers, editor
37,784

edits