• For issues you find with the Switch and Console releases, please follow this link and give as much detail as possible. This is the speediest way to get info to Pipeworks and get a hotfix in the works.
  • For issues you find with the Mobile 1.3 update, please follow this link and give as much detail as possible. This is the speediest way to get info to DR Studios to look at your issue. Also, some troubleshooting hints here.

tModLoader Wormholes (and also Scroll of Town Portal)

hamstar

Steampunker


Note: Requires Mod Helpers


Overview

This mod populates the underground with random pairs of wormhole portals. Wormholes allow two-way fast travel between remote locations of the world. Be warned: There's no telling where you might end up!

As an added bonus, I've included a craftable Scroll of Town Portal; a familiar staple for ARPG fans eager to expedite tedious caving sessions.

  1. Scroll of Town Portal
    (5x) - A personal (client-only) one-time-use wormhole to your spawn from where you stand.
    1. Recall/Wormhole Potion (1x)
    2. Book (1x)
    3. Mana Crystal (1x)
  2. Chaos Bomb
    (25x) - Explosives that scatter blocks at random and relocate wormholes (1 in 5 chance). Also destroys town portals.
    1. Recall/Wormhole Potion (1x)
    2. Bouncy Bomb (5x)
    3. Amethyst (1x)
    4. Topaz (1x)
    5. Sapphire (1x)
    6. Emerald (1x)
    7. Ruby (1x)
    8. Diamond (1x)
    9. Amber (1x)


Additional Information

Configuration options found in 'Documents/My Games/Terraria/ModLoader/Mod Configs/Wormholes Config.json'.

Source code available. API now available.

Note for mod authors: Mods can freely adjust config settings via. weak reference, but they are not automatically saved to file.


Installation

Requires tModLoader (+0.11). Copy the above .tmod file to your 'Documents/My Games/Terraria/ModLoader/Mods' folder to play.


v1.10.1
  • Updated for TML11.5
  • Added FloatInputElement for float config settings
  • Added ranges to some config settings
v1.10.0
  • Updated to TML11.4 and MH5b
  • Fixed typo in Chaos Bomb message
v1.8.1.3
  • Fixed issue with wormholes spilling past edge of minimap.
v1.8.1.2
  • Updated for MHv4
v1.8.1.1
  • Minor update for MH PacketProtocol tweak
v1.8.1
  • Updated to Mod Helpers v2.0.2
  • Restructured Mod override
  • Restructured ModPlayer class a bit
  • Updated player code
  • Added MP player load bug failsafe
v1.7.2.1
  • Refactored config file usage conventions
  • Refactored debug mode settings
  • Refactored API form
  • Refactored net code to use PacketProtocol
  • Added config settings to adjust Chaos Bomb recipe input and output
  • Altered Chaos Bomb recipe to use 5 Bouncy Bombs, and produce 25 Chaos Bombs
v1.7.1
  • Rebalanced town portal scroll recipe (now produces 3 scrolls, also craftable with spell tomes)
v1.7.0.2
  • Fixed premature minimap displays of wormholes
v1.7.0.1
  • Added mod icon
  • Added support for Hamstar Helpers v1.2.0 issue report
  • Refactored net protocol
  • Minor refactoring
  • Fixed crash bug
  • Refactored class visibility
  • Added API
v1.6.4.5
  • Fixed natural wormholes relocating improperly via Chaos Bomb hits
v1.6.4.4
  • Fixed portals not zooming properly
v1.6.4.3
  • Fixed wormhole relocation in single player via Chaos Bomb
  • Ensured town portal (not general wormhole) closure via Chaos Bomb (no random chance)
v1.6.4.2
  • Fixed Chaos Bomb issues.
  • Fixed portals not zooming correctly.
v1.6.4
  • Fixed initial placement of wormholes appearing over obstructed terrain (hopefully for good)
  • Restored debug config settings and added a wormholes force-reset setting
v1.6.3
  • Updated for TML 0.10
  • Offloaded utility/helper code to Hamstar's Helpers mod (now a dependency)
  • Numerous fixes and tweaks
v1.6.2
  • Added debug config option
  • Removed old config (Wormholes 1.3.12.json)
  • Prevented wormholes from generating before terrain
  • Improved wormhole colors
v1.6.1
  • Removed misplaced 'Losing Is Fun' code chunk affecting magic mirrors
v1.6.0
  • Added Chaos Bombs; re-randomizes existing wormholes
  • Set town portals to persist with saves
  • Add config option to disable wormholes (only town portals exist)
  • Fixed camera mode failing to render wormholes
  • Set town portals to be craftable from recall potions
  • Add particle effects to wormholes
  • Reduced wormhole light radius + increased sound
  • Moved config file to Mod Config
v1.4.0-2
  • Wormhole Potions and Recall Potions can be crafted into one another with their respective herbs.
  • Town Portal Scroll craftable with a mana crystal instead of purification powder.
v1.3.11
  • Fixed multiplayer bug.
v1.3.10
  • Fixed added config settings not being added with version updates.
v1.3.9
  • Reduced wormhole sound volume and added config setting to adjust it.
v1.3.7-8
  • Fixed entrapment glitch and improved code.
v1.3.6
  • Fixed wormholes drifting on world save.
  • Lowered default wormholes per world.
  • Note: Wormholes are refreshed with this version. A new config file is used.
v1.3.4
  • Town portal expire crash fix.
v1.3.3
  • Fixed portals sometimes failing to generate correctly on a given world.
  • Fixed portal collision box alignment issue.
v1.3.0-2
  • Changed portal to render directly to the screen instead of by way of a Dust particle (should fix glitching and layering).
  • Added town portal opening animation.
  • Town portals now expire after 1 hour.
v1.2.2
  • Exposed classes for DLL reference use. No gameplay changes.
v1.2.1
  • Improved wormhole animation.
  • Added a brief wormhole exit debuff (chaos state + distortion).
  • Assorted fixes and tweaks.
v1.1.2
  • Fixed minimap display problem.
v1.1.1
  • Tweaked portal graphic.
  • Fixed settings not getting conveyed to clients.
  • Prevented portals from spawning in lava or dungeon.
  • Added failsafes against portal glitching.
v1.1.0
  • Fixed multiplayer. Hopefully.



 
Last edited:

Digiel

Terrarian
Very good!!! Friend your mode is disabled in multiplayer could you fix this?
I'm putting together a pack and it always gets disabled, and the server does not open with it.
 

hamstar

Steampunker
I need some special arrangements to test multiplayer functionality. Gimme some time.
 
Last edited:

Omegatani

Terrarian
I don't really get it what does this mods does.. What actually that item does?
At various points on the map there will be large floating portals linking two places. Just hop in one to be teleported to the other.

Hamstar, can the portals be generated inside the temple / etc? Is it completely random, so that the portals could generate in the middle of a lava pit or something?
 

sadisticnerd

Terrarian
Well, I have found a bug but I'm not too sure how hard it is to fix it, but by some reason, when I quit the world, I reloaded it without mods by accident, and quickly realized my mistake. I quit the game, then entered in the world again with mods on....and the wormholes are fully functional, except they're invisible. I used the town portal scroll too, and the player-created wormhole is invisible as well.
 

hamstar

Steampunker
At various points on the map there will be large floating portals linking two places. Just hop in one to be teleported to the other.

Hamstar, can the portals be generated inside the temple / etc? Is it completely random, so that the portals could generate in the middle of a lava pit or something?
I didn't do much to ensure safety with them, except that they specifically cannot spawn inside the temple. I'll probably block lava pits and the dungeon as well.

Well, I have found a bug but I'm not too sure how hard it is to fix it, but by some reason, when I quit the world, I reloaded it without mods by accident, and quickly realized my mistake. I quit the game, then entered in the world again with mods on....and the wormholes are fully functional, except they're invisible. I used the town portal scroll too, and the player-created wormhole is invisible as well.
I have been unable to replicate this. I'll work on a version to add some failsafes against this, but other than that, I can only guess at the problem. Any additional information would help.

Edit: New version:
 

Attachments

Last edited:

Digiel

Terrarian
When do I create portals as I do to disable portals afterwards? I created 2 in the spawn point and another farther but I can not change the place of the spawn point, only I can change the second portal made never the first place.
 

Omegatani

Terrarian
Yeah, blocking the dungeon would be nice. Don't want to make a new world only to dive in and wind up getting a Dungeon Guardian to the face. Can they spawn on floating islands? That would be cool if they did... or high in midair in space -- risk with the wormholes ;)
 

sadisticnerd

Terrarian
alright, thanks for the reply. By some reason, the problem inverted for me now, as now the wormholes are visible on the 'main' screen but not in the minimap.
(Yes, I was too lazy to change the name of the pic made by snipping tool)
 

Attachments

Ninjastarz

Terrarian
Hey I'm really liking the mod so far but I would suggest having a short cooldown (like 2-5 seconds) after you use a wormhole as it can be pretty annoying when you have to jump to avoid lava or something straight away and just end up flicking between the portals
 

Lunatic Lobbyist

The Destroyer
Three ideas I immediately had after trying the mod:


1. Wormholes by definition contain large amounts of high radiation and are generally very dangerous and may have very unpredictable consequences. The idea is to have some sort of penalty for using wormholes. At the very least, some sort of long cool-down that doesn't allow you to use them too often.

More in-depth, I'd love to see actual penalties for using a wormhole within that cool-down, or maybe even a random dice roll of penalties the first time you go in one. A reduction of health would be an easy one. Random negative status debuffs could introduce another layer of complexity and risk to using them -- shadowflame, electrified, obstructed, ichor, blackout, moon bite, or any other effects would make wormholes far more dangerous as well as interesting to experience imo.


2. If these are to be called "wormholes", I believe they shouldn't be so static and reliable. Rather than be static, is it possible to make the random wormholes dynamically appear and disappear at times (whether they be specific increments of time or at random moments)? I'd love to see a version of this where you come across wormholes that may not be around the next time you come back to that location, along with finding new wormholes in places they weren't previously. After all, wormholes tend to suddenly appear and collapse.


3. Allow for the chance for mobs to appear coming out of the wormholes. I don't know that it's even possible to program mobs from the area on the other side of the wormhole to appear in places they wouldn't otherwise, but that would be incredibly immersive. But, that's likely more trouble to program than its worth. Far more feasible, there could be unique mobs hopping out when you get near them, from "the void" or what have you. They could be vanilla enemies depending on which bosses you've defeated (such as a corrupted bunny), or completely new enemies that look like abominations from another world. Either way, seeing other npc's coming out of the wormholes would truly add another layer of uniqueness to the mod.


Regardless, wonderful job on this mod -- loving what it adds so far!
 
Last edited:

hamstar

Steampunker
Improved wormhole animation, added a brief exit debuff (chaos state + distortion), assorted fixes and tweaks.

Edit: New version exposes classes for DLL reference use. No gameplay changes.
 

Attachments

Last edited:
Top Bottom