Spawn

From Terraria Wiki
Jump to navigation Jump to search
This article is about the player's spawn location. For details about the respawning of players after dying, see Death § Respawn. For the spawning mechanics of other entities, see NPC spawning.

The world spawn point is where players appear in a newly created world or when joining a multiplayer server. The world's spawn point will be above surface layer, and not submerged in any liquid. It will usually be on the topmost block within five tiles of the horizontal center of the world, but the horizontal range can increase if no valid tile is within range.[1] It will almost always be located in the Forest biome as more hazardous biomes cannot appear at the world's center.

A player's spawn point is initially the world spawn point, but can be changed by crafting a Bed, placing it in a house and pressing the Open / Activate button on it. The spawn point is where players respawn after dying, and where a Magic/Ice Mirror (or its upgrades) or Recall Potion will teleport them. Once the house the Bed is in is broken or Open / Activate is pressed on the Bed a second time, the player's spawn point reverts back to the world's initial spawn point.

(Desktop, Console and Mobile versions) The world's spawn point is marked by a Map Spawn.png green arrow icon on the minimap, and the player's spawn point is marked by a Map Bed.png bed icon.

Notes

  • Marking the position of the world spawn point as (x, y), the spawning process can be described as following:
    • When the player is (re-)spawning at or teleporting to the world spawn point (except teleporting to the world spawn point via Shellphone (Spawn)), the game will check the 3×3-tile area above the spawn point (from (x-1,y-3) to (x+1, y-1)). If this area contains any solid block or liquid, the spawn point is considered obstructed.[2]
      • (Desktop, Console and Mobile versions) When the world spawn point is obstructed, the game will check 30 tiles directly above the world spawn point (from (x, y) to (x, y-29)) for unobstructed spawn point (3×3-tile area above the tile does not contain any solid block or liquid). If a tile is found at a height of y1, the new spawn point will be (x, y1), and the game will clear the area above spawn point.[3]
        • If no such tile is found, then the player will spawn at world spawn point.
      • (Old-gen console and 3DS versions) When the world spawn point is obstructed, the game will always clear the world spawn point.
To clear a spawn point, all solid blocks and liquids within the 3×3-tile area above the spawn point are destroyed so the player can spawn correctly.[4] Filled storage items and their supporting tiles will not be destroyed, causing the player to instead spawn inside tiles in this case.
  • If the world spawn point is not obstructed but is in midair, the game will check a 3-tile-wide×50-tile-high rectangular area below the world spawn point (from (x-1, y) to (x+1, y+49)) for solid tile. If a tile is found at a height of y2, the new spawn point will be (x, y2).[5]
  • If no such tile is found, then the player will spawn at world spawn point.
  • When the player is teleporting to the world spawn point via Shellphone (Spawn):
    • If the world spawn point is obstructed, the game will check 30 tiles directly above the world spawn point for unobstructed spawn point and set the spawn point to valid tile found.
    • If no such tile is found, then the game will clear the area above world spawn point and the player will spawn there.

Tips

  • It might be useful to build a shelter over the world spawn point so that the player is provided some amount of safety if they happen to respawn at the world spawn point, like when the set spawn point is inadvertently reverted back to the initial world spawn point. Similarly, it should be avoided to dig directly underneath the world spawn point, as players respawning there will inevitably fall down.
  • It is possible, albeit extremely rare, for the player to spawn on a Floating Island. In this case, it is highly advisable to use the available blocks to create a staircase to the ground. If there happens to be a Lucky Horseshoe or Fledgling Wings(Desktop, Console and Mobile versions) in the Skyware Chest, then equipping that item allows jumping down without taking fall damage.
    • Alternatively, one could also generate a new world.

History

  • Desktop 1.4.0.1:
    • Added icons for the world spawn point and bed spawn point on the minimap.
    • Players can now spawn up to 30 tiles above their spawn point if the location is covered by blocks, rather than destroying those blocks.
    • Since the Snow biome now generally generates further away from spawn, it is now significantly less likely to spawn in one.
  • Desktop 1.2.4: It is now much more likely that the player will spawn on a flat clean surface when creating a new world.
  • Desktop 1.2.0.2: If a Bed is placed somewhere that would cause the player not to spawn without breaking through blocks, they will now get a message when trying to set the spawn point letting them know the Bed is not in a suitable position.
  • Desktop 1.0.1: Spawning no longer destroys chests that are placed on ground that is removed due to spawn point clearing.

References

  1. Information taken from the Desktop version Desktop 1.4.4.9 source code, method GenerateWorld() in Terraria.WorldGen.cs. The related world generation pass is called "Spawn Point".
  2. Information taken from the Desktop version Desktop 1.4.4.9 source code, method Spawn_IsAreaAValidWorldSpawn() in Terraria.Player.cs.
  3. Information taken from the Desktop version Desktop 1.4.4.9 source code, method Spawn_GetPositionAtWorldSpawn() in Terraria.Player.cs.
  4. Information taken from the Desktop version Desktop 1.4.4.9 source code, method Spawn_ForceClearArea() in Terraria.Player.cs.
  5. Information taken from the Desktop version Desktop 1.4.4.9 source code, method Spawn_DescendFromDefaultSpace() in Terraria.Player.cs.