Skip to content

silverua/slay-the-spire-map-in-unity

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Slay the Spire Map in Unity

Demo video:

FEATURES

Longer video with some how-to info:

HOW-TO

This repo contains an implementation of the Slay the Spire Map in Unity3d. Key features:

  • Pick any orientation (left to right, right to left, top to bottom, bottom to top)
  • Map appearance and player position get saved between game sessions
  • Node position randomization
  • Cross nodes elimination
  • Scrolling map content for long maps

Free resources and assets used in the project:

December 13 2022 Update: Thanks to hojjatjafary

  • Better algorithm for generating paths
  • New algorithm uses a for loop instead of a while loop to generate paths, which makes it more precise and eliminates the need of limiting max amount of attempts
  • New algorithm respects precise numbers of starting nodes and pre-boss nodes
  • Use the new field extraPaths in MapConfig to generate more paths and create more connections between the nodes

February 25 2023 Update: Got several requests to make this map work with Unity UI and scroll rects. In this update:

  • New test scene with the Unity UI version of the map: Assets/Scenes/SampleSceneUI.unity
  • New UI-specific prefabs: Assets/Prefabs/MapObjectsUI Variant.prefab, Assets/Prefabs/UINode.prefab, Assets/Prefabs/UILine.prefab
  • UI setup requires 2 scroll rects created for horizontal, vertical maps. Check out the SampleSceneUI for an example of this.

March 14 2023 Update: Upgraded to Unity 2021 on master to:

  • Fix "Self referencing loop detected" errors related to Newtonsoft.Json serializing Vectors
  • Fix some issues with lines connecting nodes in SampleSceneUI

About

Implementation of the Slay the Spire Map in Unity3d

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Contributors 4

  •  
  •  
  •  
  •