1. tModLoader
  2. News

tModLoader News

September 2023 Stable Update

We hope everyone has been having a fun time with 1.4.4 tModLoader! We are happy to see that a large majority of popular mods have already been updated to work with the latest tModLoader. In fact, over 85% of all mods by subscriber count have made it to 1.4.4 tModLoader already.

Over the last month the tModLoader team and our amazing contributor community have been hard at work fixing bugs and other issues. This months update focuses on bug fixes. We also managed to greatly improve the in-game workshop performance, please check it out.

Modders: Next month tModLoader will add many new exciting features, such as Builders Toggles, Emote Bubbles, World Headers, Rubblemaker support, and a reworked NPC buff immunity system, so modders should take the opportunity this month to experiment with these features on the preview beta branch, preview-v2023.08, prior to their release. You'll need to switch to this new beta branch even if you were previously in preview-v2023.07. In addition, there are other changes that might break your mods, so be sure to test your mods and publish an update on preview before October if needed.

As always, if you encounter any issues, please reach out in our Discord.

New Changes' Highlights


[h3]Re-design Mod Browser & Back-end by Solxan, DarioDaF, and Chicken-Bones[/h3]
• Revamps the Mod Browser UI to be significantly faster & streamlined


Bug Fixes

[h2]Gameplay Fixes[/h2]
Destructor_Ben - Fix some walls dropping the incorrect item ThomasThePencil - Fix a few armor stat bonuses Destructor_Ben - Fix Search in the duplication menu JavidPack - Fix Terrarian not getting Legendary prefix JavidPack - Fix Grand Design not dropping wire directly into player inventory JavidPack - ModHair is not showing for other other players in multiplayer JavidPack - Fix some shop items not having material tooltip line

[h2]QOL and Other Fixes[/h2]
Chicken-Bones - Fix game to launch on MUSL/Alpine Linux Destructor_Ben - Config Elements state if they required a reload Destructor_Ben - Fix Mod Icon inconsistencies Solxan - Auto Enable Dependency Mods on Reload Solxan - More fixes for mod organization Solxan - Fix more issues with workshop icons Solxan - Fix a GOG workshop issue JavidPack - Clarify UI messages for outdated mods JavidPack - Fix issue preventing tModLoader from running in Snap sandbox

[h2]API Fixes[/h2]
JavidPack - Fix tModPorter meleeCrit typo JavidPack - Fix ExampleHerb to work with Acorn Axe BasicallyIAmFox - Fix MonoModHooks.DumpILHooks always throwing Destructor_Ben - Prevent modders from accidentally publishing dev-built mods on stable Destructor_Ben - Tile Documentation NeonCube - More Documentation

Localization


We recently started localizing the store page and workshop tags. We are also lacking a great deal of in-game translations for several languages still. If you are interested in translating these, please get in contact with us on Discord to ask how to contribute translations or visit the tModLoader wiki for instructions.

1.4.4 Hot Fixes Summary

tModLoader 1.4.4 Version has been updated with the following bug fixes as of Hot Fix Version 2023.06.25.30:
  1. Fixed issues with Gore/Leaf spawning - Mirsario
  2. Fixed Issues with OneDrive Save Data Migration - Javidpack
  3. Fixed issues with UnloadedModItem being lost in accessory slots - Solxanich
  4. Increased reliability of saving & loading world, player files - Solxanich


Thank you for your patience. We are continuing to look at save data challenges with 1.4.4 and 1.4.3-Legacy, and appreciate your understanding.

As always, if you encounter any issues, please reach out in our Discord.

The 1.4.4 Update is Now Live

The 1.4.4 Update Is Now Live on Steam.
Thank you for your patience.

As a reminder, if mods you were using on 1.4.3 haven't updated yet, you can switch back to 1.4.3 in the meantime by using the beta branches feature to switch to the 1.4.3-legacy branch.

New Changes' Highlights


The following is a list of the most noteworthy pull requests and commits that have been pushed since 2022th October, and are now available on the default/stable branch.

[h3]Major Localization Changes by jopojelly[/h3]
• Translations are now fully in localization files (.hjson files). DisplayName and Tooltip, for example, can no longer be assigned in code.
• Localization files are automatically updated with entries for new content and managed by tModLoader. More organization options available.
• All ModTranslation usages are now replaced with LocalizedText
• All translation keys now follow a more predictable pattern: Mods.ModName.Category.ContentName.DataName
• Contributing translations, directly or through translation mods, streamlined.

Porting Notes: #preview-update-log in Discord
[h3]Change HookGen Namespace Style by Chicken Bones[/h3]
• Hookgen namespaces (IL. and On.) have been removed in favor of On_ and IL_ prepended to the type name.
• No longer will you get 3 different namespace suggestions when you use VS to import a Terraria type name.
• Want On Item hooks? Just use On_Item it's in the same namespace as Item!

Porting Notes: #preview-update-log in Discord
[h3]Declarative Shops by BasicallyIAmFox[/h3]
• NPC shops are now declarative, meaning they get registered, and items can be added to them with conditions, similarly to NPC drops (loot) and recipes
• Adding items to shops, or hiding items from shops is now as easy as adding or disabling recipes
• Info mods can traverse the NPCShopDatabase to show how to obtain an item. All the conditions for items appearing in shops have been localized.
• Registering multiple shops per NPC is perfectly fine, and selecting the shop to be opened when chatting can now be done via the ref string shop parameter in OnChatButtonClicked

Porting Notes: #preview-update-log in Discord
[h3]Max Health and Mana Manipulation API by absoluteAquarian[/h3]
• Adds ModPlayer.ModifyMaxStats with StatModifier arguments for permanent adjustments to max health/mana.
• Adds Player.ConsumedLifeCrystals, ConsumedLifeFruit and ConsumedManaCrystals properties.
• Add helper methods Player.UseHealthMaxIncreasingItem and Player.UseManaMaxIncreasingItem for the visual effects.
• Adds ModResourceDisplaySet allowing for custom life/mana draw styles (similar to boss bar styles) that can be selected in settings.
• Adds ModResourceOverlay to allow for drawing custom hearts/mana/effects over the vanilla (or modded) life/mana UI elements.

Porting Notes: #preview-update-log in Discord
[h3]ModHair API by steviegt6[/h3]
• Adds the ability to add new hairstyles, with unlock conditions.
[h3]Update MonoMod to new Re-organized implementation by Chicken-Bones[/h3]
• Updates to MonoMod involve the removal of old APIs, and better performance and stability moving forward.
NativeDetour and Detour are gone, there was little need for modders to use these anyway.

Porting Notes: #preview-update-log in Discord
[h3]Player/NPC damage hooks rework. Hit/HurtModifiers and Hit/HurtInfo by Chicken Bones[/h3]
Player and NPC hit hooks (OnHit, ModifyHit, OnHitBy, etc) have been simplified with common architecture, and had many new features added.

Porting Notes: #preview-update-log in Discord
[h3]OnStack Hook by andro951[/h3]
• Adds ModItem/GlobalItem.OnStack and SplitStack to enable modded data such as experience counters, durability, etc to work with stackable items.
• Crafting now creates the recipe item(s) first, and then combines them using OnStack. This means that in OnCreate,
RecipeCreationContext.DestinationStack has been added so you can make sure that the crafted result is stackable with the mouse item (if any)

Porting Notes: #preview-update-log in Discord
[h3]Mod config auto localization by jopojelly[/h3]
ModConfig can now be localized by default.
• Localization for ModConfig entries are now done fully in .hjson files.
• .hjson files are automatically populated with entries.
• New LabelArgs and TooltipArgs attributes allow for cleaner code and better code/localization reuse.
• [Label] and [Tooltip] obsolete, [Header] changed. See porting notes.

Porting Notes: #preview-update-log in Discord
[h3]Make IEntitySource easier to use. Improve docs. Fix some projectile crit and armor pen bugs by Chicken-Bones[/h3]
• All entity sources have been reviewed. Most are unchanged, but some have been removed, some added, or split.
• Many sources now extend EntitySource_Parent which is the most useful source. If in doubt, use GetSource_FromThis() when spawning a projectile.
CritChance and ArmorPenetration now transfer from parent to child projectiles, and from players to player spawned projectiles.
Projectile.ContinuouslyUpdateDamage is now ContinuouslyUpdateDamageStats and also updates CritChance and ArmorPenetration (no, minions still cannot crit, even though they have CritChance)

Porting Notes: #preview-update-log in Discord
[h3]Allow keybind text to use translated text by Cyrillya[/h3]
• Modded keybinds are now localizable
• The name passed into KeybindLoader.RegisterKeybind is used in the key: "Mods.{ModName}.Keybind.{KeybindName}"

Porting Notes: #preview-update-log in Discord
[h3]Item.NewItem overloads that takes Item by jopojelly[/h3]
• Added new Item.NewItem overloads that take an Item instance and clones it, allowing spawning a clone of an item.
• Fixes several cases where modded data was lost or broken (mediumcore death, items dropping from Tile Entities)
Player.QuickSpawnItem (and similar) overloads with the Item parameter now use the item cloning by default. Player.QuickSpawnClonedItem is now marked as obsolete.

Porting Notes: #preview-update-log in Discord
[h3]Fix Quick Heal and Quick Mana consuming non-consummables by Cyrillya[/h3]
• Adds item.Consummable as a check in Quick Heal and Quick Mana
• Is a simpler solution then overriding ConsumeItem(

Porting Notes: #preview-update-log in Discord
[h3]Add ModSystem.ClearWorld by Chicken-Bones[/h3]
• Adds ModSystem.ClearWorld which runs on world clear. The new best place to clear/initialize world related data structures.

Porting Notes: #preview-update-log in Discord
[h3]IL Editing QoL Stuff and IL Editing GenPasses by Destructor-Ben[/h3]
• Adds some helper methods and an exception for easier IL editing and error handling.
• Adds WorldGen.ModifyPass and WorldGen.DetourPass to allow easily IL hooking legacy world gen passes
• It is recommended for modders to wrap their IL hooks in a try-catch, and call either MonoModHooks.DumpIL or throw new ILPatchFailureException so that a user can provide the IL log file for diagnosis when hooks fail.

Porting Notes: #preview-update-log in Discord
[h3]Unify Localized Conditions by Chicken Bones[/h3]
Terraria.Recipe.Condition has been moved to Terraria.Condition and can now be applied to more things. Recipes, item variants, drops and soon shops
• Added SimpleItemDropRuleCondition class to help make drop conditions more easily.

Porting Notes: #preview-update-log in Discord
[h3]GetItemDrops hook and redesigns to support Block Swap feature by jopojelly[/h3]
• Tiles and walls now automatically drop the items that place it. This process supports tiles with multiple styles.
• Block Swap feature now supports modded torches, chests, and drawers.
• Other miscellaneous fixes.

Porting Notes: #preview-update-log in Discord
[h3]Default Research Unlock Value changed to 1 by jopojelly[/h3]
• All items will now default to needing 1 item to research.
• The previous value of 0 left items unresearchable since many modders don't bother to implement journey mode features
• Modders can clean up their code. ModItems with Item.ResearchUnlockCount = 1; lines can be deleted.

Porting Notes: #preview-update-log in Discord
[h3]Mod/GlobalNPC.CanBeHitByNPC hooks by Ishigh1[/h3]
• New hooks, mirroring CanHitNPC but called on the victim's ModNPC and GlobalNPC
[h3]BuyItem and PreReforge split into more granular methods, etc by jopojelly and Jadams505[/h3]
Player.BuyItem split into BuyItem, CanAfford, and PayCurrency methods
Player.CanBuyItem removed
CustomCurrencyManager.BuyItem split in the same manner.
Mod/GlobalItem.PreReforge is now split into PreReforge and CanReforge. PreReforge no longer returns bool, CanReforge handles that purpose.

Porting Notes: #preview-update-log in Discord
[h3]AmmoID.Sets.IsRocket changed to IsSpecialist, Player.rocketDamage changed to Player.specialistDamage by jopojelly[/h3]
• Renames Player.rocketDamage to Player.specialistDamage, in line with 1.4.4 changes to Shroomite Helmet that changed "bonus rocket damage" to "bonus specialist ranged damage".
• Renames AmmoID.Sets.IsRocket to AmmoID.Sets.IsSpecialist and adds ammo entries matching Terraria for the same reason.
• Adds ItemID.Sets.IsRangedSpecialistWeapon to cover specialist weapons that don't use ammo.

Porting Notes: #preview-update-log in Discord
[h3]ModPrefix.GetTooltipLines by jopojelly[/h3]
ModPrefix.GetTooltipLines added to allow adding tooltips directly from ModPrefix class. Better code cohesion.

Porting Notes: #preview-update-log in Discord
[h3]ModTile.RegisterItemDrop to add fallback and manual type+style item drops by jopojelly[/h3]
• Reworks automatic tile drops introduced in https://github.com/tModLoader/tModLoader/pull/3210
ModBlockType.ItemDrop removed.
TileLoader.GetItemDropFromTypeAndStyle no longer falls back to tile style 0. A special fallback will be used if the style is not found.
ModTile.RegisterItemDrop added. Allows manually registering an item drop for a tile style, or as a fallback item. Used to provide drops for styles that don't have a corresponding item that places it.
ModWall.RegisterItemDrop added. Allows manual registration of wall drop, useful for unsafe walls that drop safe walls.

Porting Notes: #preview-update-log in Discord
[h3]Remove ILoadable from IModType by Chicken-Bones[/h3]
IModType is no longer ILoadable, ModType is unchanged
• As a reminder, IModType exists only to support classes that can't extend from ModType. In tML the only instance of this is ModTileEntity which much extend from TileEntity, there is little reason for modders to extend from it instead of ModType.

Porting Notes: #preview-update-log in Discord
[h3]Automatically register TownNPCMood localizations by jopojelly[/h3]
• TownNPCMood localization entries will automatically populate .hjson for town npc. Only used keys will be populated.
• TownNPCDialogueName localization entries will automatically populate .hjson for biomes.
NPCID.Sets.NoTownNPCHappiness added for town npc that don't use happiness.

Porting Notes: #preview-update-log in Discord
[h3]Various NPC Gravity Changes by Kogsey[/h3]
• Allows modders to affect NPC gravity and maxFallSpeed without interfering with other mods by multiplying NPC.GravityMultiplier and NPC.MaxFallSpeedMultiplier
• Adds GravityIgnoresType, GravityIgnoresLiquid and GravityIgnoresSpace properties to NPC to disable the respective vanilla gravity calculations.

Porting Notes: #preview-update-log in Discord


Performance Improvements


[h3]Improve Player.clientClone performance by Chicken Bones & Mirsario[/h3]
Item.Clone can become very performance expensive with many mods. Only type, stack and prefix are required to tell if an item has changed in the inventory and needs to be re-synced.

This PR replaces usages of Item.Clone in Player.clientClone with Item.CopyNetStateTo
Additionally, a single Player (and ModPlayer) instance is reused for all clientClone/CopyClientStateTo calls, acting as a 'storage copy' rather than making a new one each frame.

Please note that tModPorter is not smart enough to identify Item.Clone usages in ModPlayer.CopyClientStateTo calls automatically. You will need to replace these yourself or an exception will be thrown at runtime.

Porting Notes: #preview-update-log in Discord
[h3]Significantly Improve GlobalType Performance by Chicken Bones[/h3]
• More performance, more modularity. No need to fear having hundreds of globals per mod. The new system should do better at optimizing performance than a modder can with 'uber globals' because it will skip even iterating past a global which doesn't apply to the target entity type.
AppliesToEntity is not called during the game anymore! Instead, whether a global applies to an Item/Projectile/NPC type is computed and cached at the end of PostSetupContent
• This is a minimally breaking change, but reading the PR description is strongly recommended, especially for advanced modders.

Porting Notes: #preview-update-log in Discord


Localization


Brazilian Portuguese - Updated thanks to Pixelnando.
Chinese - Updated thanks to lyc-Lacewing and sgkoishi.
Russian - Updated thanks to RazzSG, Blueberryy, and Ved-s.

Bug Fixes


[h3]Torch fixes (Smart cursor, Biome torch/campfire) by jopojelly[/h3]
• Biome Torch/Campfire (Torch Gods Favor) support has been added. ModBiome can now dictate the appropriate item to auto swap.
• Various torch issues have been fixed: Smart cursor, underwater placement, duplication menu category
• Block Swap feature now supports modded Campfire tiles.
ExampleWaterTorch added. ExampleCampfire added.

Porting Notes: #preview-update-log in Discord
[h3]UI Fixes by Destructor-Ben[/h3]
UICommon.WithFadedMouseOver now supports border color toggling.

Porting Notes: #preview-update-log in Discord
[h3]Fix ModWaterStyle.SlopeTexture not being used by jopojelly[/h3]
• If you are using ModWaterStyle, make sure you have a _Slope.png file. If you didn't, your mod won't load and will need to be updated.
• The Slope texture was added in 1.4.4 Terraria and helps draw water correctly around sloped tiles. See https://github.com/tModLoader/tModLoader/blob/1.4.4/ExampleMod/Content/Biomes/ExampleWaterStyle_Slope.png for an example. You can also look at the Images/LiquidSlope_# files from vanilla.
Rijam - More Conditions mtkloepf - Updated some documentation PaulHause - [1.4.4] WIP: Reworked Biome Block Counting for Vanilla Biomes stormytuna - Changes ModifyBuffTip hook into ModifyBuffText hook (#3307) noctisatrae - Improving the documentation (Recipe.Create) ScalarVector1 - Change legacy version message ExterminatorX99 - Run HookGen ExterminatorX99 - Mod/GlobalWall.WallFrame hook Ouroel - Wrap many ModPlayer hooks in exception suppressors to prevent cascading failures Exiled1 - Added a currency system accessor DarioDaF - Hotfix enumeration stopped error (Task edit UI) and icon disappearing Setnour6 - Add NearShimmer recipe condition Setnour6 - [1.4.4] Add new secret seed conditions for ItemDropRules Antirhinnum - A Little* Bit of Documentation turtletowerz - dedicated server management rewrite BasicallyIAmFox - UseImageX method overloads BasicallyIAmFox - [1.4.4] Add ItemID.Sets.OreDropsFromSlime MutantWafflez - New 1.4.4 Info Accessory Hooks MutantWafflez - Modded Loadout IO MutantWafflez - Completed Several Tasks From PortingNotes_1.4.4.9.md absoluteAquarian - More Reliable Stack Trace File Path Trimming absoluteAquarian - OnStack API Documentation Improvements Kogsey - Fixes setting npcCatchable true forcing NPC.friendly to falce Kogsey - Shimmer Recipe.Condition support + internalisation/removal of vanilla corruption/crimson versions Cyrillya - ModPlayer.AddMaterialsForCrafting Method Cyrillya - Call ItemLoader.UseItem for food quick buff Destructor-Ben - Better Mod Development Menu Destructor-Ben - More UI Fixes Destructor-Ben - IL Editing GenPasses Destructor-Ben - IL Editing QoL Stuff Jadams505 - Modded chest lock support direwolf420 - add DamageClassLoader.GetDamageClass direwolf420 - Add ItemID.Sets.CoinLuckValue direwolf420 - ModTypeLookup.RegisterLegacyNames method direwolf420 - InfoDisplay text coloring support direwolf420 - GrappleCanLatchOnTo hook direwolf420 - [1.4.4] Add TileID.Sets.AvoidedByMeteorLanding direwolf420 - [1.4.4] Add ItemID.Sets.GeodeDrops Mirsario - Patch improvements Mirsario - Code Style Update (K&R, etc.) Mirsario - Move & rename ModItem.SacrificeTotal Chicken-Bones - Improve FastParallel.For performance in CPU contended scenarios. Solxanich - Fix #881 (tModLoader not enabled for family share accounts on steam) Solxanich - Correct LogStartup order & Int.MaxValue UnloadedItem Exiled1 - Fix #3221 by adding a check to player and world names to prevent reserved keywords from being used. Cyrillya - Fix Player.Serialize bug due to extra buff slots added by mods HydroH - Fix IME compability issue turtletowerz - Fix console commands on Docker servers Destructor-Ben - UIMessageBox Fix Kogsey - Fix gravity being assigned instead of fall speed in maxFallSpeed private set. Kogsey - Fix for multiplayer modded music boxes not working with wiring Antirhinnum - Fix Character Creation Window Hair Draw Ordering Bug fkwilczek - Fixed double damage space fkwilczek - Fixed problem with detecting dotnet on linux Rijam - ItemUseStyleID.RaiseLamp Front Arm Animation Fix Rijam - Fix Town NPC Melee Swinging Source Rectangle Rijam - [1.4.4] Obsidian Armor Set Bonus Whip Speed Fix Jadams505 - [1.4.4] Health bar style options fix Jadams505 - [1.4.4] Quick stack visual fix Jadams505 - [1.4.4] Interface layer drawing fix direwolf420 - Use correct layers for First/LastVanillaLayer direwolf420 - Fix ModTree.Shake hook not working direwolf420 - Fix ProjectileLoader.ReceiveExtraAI not being called (consistently) direwolf420 - [ExampleMod] Fix EM not loading on servers, ExampleRecipeMaterialPlayer fixes direwolf420 - Fix pet drawing in player select screen for invalid items + ExampleMod showcase direwolf420 - Fix items falling through tiles and certain projectiles updating in non-loaded chunks in MP direwolf420 - [1.4.4] Fix DustType + CreateDust interaction direwolf420 - Fix tile framing (causing infinite UnloadedXTile loop and invisible tiles) ilcheese2 - Fix content folder path on Mac with GoG version (#3173)
[h3]ExampleMod[/h3]
Blockaroz - Example Drill Midnight417 - Example for a Custom Swing Sword RayRelax - Porting various example commands RegularPhoenix - Ported Example Javelin RegularPhoenix - Updated Example Resource Rijam - Example Swinging Energy Sword (1.4.4 Excalibur Clone) Rijam - Minor Example Mod Changes Rijam - Updated Shimmered Example NPCs and Added Gore direwolf420 - Tweaks & fixes for example resource direwolf420 - Update existing mod integrations to 1.4.4 direwolf420 - More shimmer transformations direwolf420 - Reimplement ExampleBlock.ChangeWaterfallStyle FalconO5 - ExampleYoyo port

Frequently Asked Questions


[h3]How do I switch to the 1.4.3-legacy or 1.3-legacy branches of TML?[/h3]
To switch to anoter branch in steam, just do the following: 1. Right click on tModLoader in Steam and select 'Properties...', then 'BETAS';
2. Select the branch you want in the drop-down menu on top;
3. Close the window. You don't need to enter any passwords.


Have fun!

1.4.4 Release Announcement

Hello everyone!

We are excited to announce that 1.4.4 tModLoader will be available starting August 1st as tModLoader's default experience!
After a lot of testing and changes, we are ready to release this next big version of tModLoader. We have seen significant uptake within the modding community on our 1.4.4-preview Beta, and are looking forward to a smooth transition to the next big stage.
A lot of hard work went into this, so a big thank you to everyone involved.

Likewise, although 1.4.4 is released from our end, there will still be some mods not yet released on 1.4.4. This may include some popular mods. We anticipate several of these noteworthy mods to release within the few days to follow, and ask for your patience as modders publish their work.

For more information on the Jump to 1.4.4 and all that's happening around it, you can read more in our big announcement from earlier this month: tModLoader 1.4.4 Transition Plan
Please note that 1.4.4 will NOT replace 1.4.3. 1.4.3 will continue to be available in full through Steam Beta options, just as 1.3 is today.​


Once again, we are excited to bring tModLoader to 1.4.4 age! We hope you enjoy this next era of modding, and several improvements we've made during the journey.

Sincerely,
The tModLoader Community

1.4.3-Legacy Transition Period Start

Howdy Terrarians,

In Case You Missed It, July 7th marks the start of our transition to 1.4.4.

You can read more about the transition here:
https://store.steampowered.com/news/app/1281930/view/3694688633575770202

This recent update includes several file storage changes and an in-game recommendation and for tutorial for hopping to one of our two beta options to match your preference.
We recommend doing so ahead of us swapping out the default to 1.4.4 to avoid interruption:
  1. 1.4.3-Legacy
  2. 1.4.4-Preview

Have fun, and stay classy!