llando
  • Overview
    • 💡Introduction
    • ✨Feature List
  • Guides
    • 📪Quick Setup
    • 📪Manual Setup
    • 📪Utilizing Time Trial Data Effectively
    • 📪Adding Time Trial UI
    • 📪Adding Time Trial Saves
    • 📪Accessing Time Trial Data
    • 📪Adding New Tracks
  • Components/Prefabs
    • 📪TrackManager
    • 📪LapTimeTrackingObject
    • 📪TrackPoint
    • 📪TimeTrialUIManager
    • 📪TimeTrialSaveManager
    • 📪TTSystem
  • Internal Classes
    • 📪Sector
    • 📪LapTimeTrackingEditor
Powered by GitBook
On this page
  • How To Add Time Trial Saves Using TimeTrialSaveManager
  • How To Add Time Trial Data To Your Existing Save System:
  1. Guides

Adding Time Trial Saves

Guide

Last updated 1 year ago

How To Add Time Trial Saves Using TimeTrialSaveManager

Saving your time trial data is an important aspect to ensure that player progress persists across different scenes and game sessions. This means that when players close and relaunch your game, their personal best time will still be displayed instead of being reset.

To add persistent time trial data to your project, simply add the component to an object in your scene. For convenience, it is recommended to add it to the same object where you added the component.

Optionally, you can also specify a custom file name by setting it in the inspector of the component.

NOTE: This save system is intended for testing/debugging purposes. It uses unencrypted JSON and lap times are easily modifiable by players.

How To Add Time Trial Data To Your Existing Save System:

TimeTrialSaveData is a serializable class in the component that holds the relevant time trial data to be saved. It is used to convert time trial data to/from the JSON save file. This class can be modified to include any data you wish to save by adding your own fields to the class.

Otherwise, you can add time trial data to your own save system by accessing the public properties exposed in the . See sections for a full breakdown of time trial data that can be used.

📪
TimeTrialSaveManager
TrackManager
TimeTrialSaveManager
TimeTrialSaveManager
LapTimeTrackingObject
Accessing Time Trial Data