encoder

package
v0.0.0-...-79f8d15 Latest Latest
Warning

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

Go to latest
Published: Jan 27, 2023 License: MIT Imports: 6 Imported by: 0

Documentation

Index

Constants

View Source
const FIELDS_ANGLES int32 = 1 << 1
View Source
const FIELDS_ORIGIN int32 = 1 << 0
View Source
const FIELDS_VELOCITY int32 = 1 << 2

Variables

View Source
var PlayerFramesMap map[string][]FrameInfo = make(map[string][]FrameInfo)

Functions

func InitPlayer

func InitPlayer(initFrame FrameInitInfo)

func PathExists

func PathExists(path string) (bool, error)

func WriteToBuf

func WriteToBuf(key string, data interface{})

func WriteToRecFile

func WriteToRecFile(playerName string, roundNum int32, subdir string)

Types

type FrameInfo

type FrameInfo struct {
	PlayerButtons     int32
	PlayerImpulse     int32
	ActualVelocity    [3]float32
	PredictedVelocity [3]float32
	PredictedAngles   [2]float32
	CSWeaponID        int32
	PlayerSubtype     int32
	PlayerSeed        int32
	AdditionalFields  int32
	// 附加信息
	AtOrigin   [3]float32
	AtAngles   [3]float32
	AtVelocity [3]float32
}

replay frame

type FrameInitInfo

type FrameInitInfo struct {
	PlayerName string
	Position   [3]float32
	Angles     [2]float32
}

Jump to

Keyboard shortcuts

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