gameinfo

package
v0.1.89 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Nov 20, 2026 License: MIT Imports: 4 Imported by: 1 module, 0 packages

The first number is the count of modules that contain a package that imports this one. The module count is a better indicator of popularity than the package count. A module with 100 importing packages is counted only once instead of 100 times, reflecting the fact that the choice to use the package was likely made only once, not 100 times.
A '?' means that the value hasn't been computed yet.

Documentation

Overview

Package gameinfo edits the search paths in a Source 2 game's gameinfo.gi, which several programs share: Steam, mod managers and tools that mount content for a while. Each tool's paths sit in a block between its own marker comments, and a tool removes exactly the lines it wrote, keeping every other byte of the file.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Mount

func Mount(source []byte, name string, paths ...string) ([]byte, error)

Mount returns source with the block of the tool named name holding paths as Game search paths, replacing the tool's earlier block. The block goes on its own line ahead of every other Game path and other tools' blocks, so its files win while it is mounted. The block also names the engine's Mod and Write paths, which the engine would otherwise take from its first path: the ones the file already names, or else the Game path that came first.

func Unmount

func Unmount(source []byte, name string) ([]byte, error)

Unmount returns source without the block of the tool named name: its marker lines and the Game, Mod and Write lines between them. Any other line another program put inside the block stays.

Types

This section is empty.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL