relaxutils

package
v0.12.20 Latest Latest
Warning

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

Go to latest
Published: Sep 4, 2023 License: Apache-2.0 Imports: 6 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func SaveConfig

func SaveConfig(fn string, cfg any, procSelfCloseTags FuncOnSelfCloseTags) error

Types

type Config

type Config struct {
	XMLName        xml.Name    `xml:"config"`
	GeneralComment string      `xml:",comment"`
	SD             float32     `xml:"sd"`
	ID             int         `xml:"id"`
	Name           string      `xml:"name"`
	ConfigVersion  string      `xml:"configVersion"`
	RTPsComment    string      `xml:",comment"`
	RTPs           *FloatList  `xml:"rtp"`
	ConfigComment  string      `xml:",comment"`
	Symbols        *Symbols    `xml:"symbols"`
	Wilds          *StringList `xml:"wilds"`
	Payouts        *Payouts    `xml:"payouts"`
	PayingSymbols  *StringList `xml:"payingSymbols"`
}

func NewConfig

func NewConfig() *Config

type FloatList

type FloatList struct {
	Vals []float32 `xml:"item"`
}

type FuncOnSelfCloseTags

type FuncOnSelfCloseTags func(string) string

type Int2DArray

type Int2DArray struct {
	Rows []*IntList `xml:"row"`
}

func BuildInt2DArray

func BuildInt2DArray(arr2 [][]int) *Int2DArray

func BuildInt2DArrayEx

func BuildInt2DArrayEx(avw *sgc7game.ArrValWeights) *Int2DArray

func BuildIntArrValMapping added in v0.10.357

func BuildIntArrValMapping(avw *sgc7game.ValMapping2) *Int2DArray

func BuildLineData

func BuildLineData(ld *sgc7game.LineData) *Int2DArray

type Int3DArray

type Int3DArray struct {
	Tables []*Int2DArray `xml:"tbl"`
}

func BuildInt3DArray

func BuildInt3DArray(lst []*sgc7game.ReelsPosData) *Int3DArray

type IntList

type IntList struct {
	Vals []int `xml:"item"`
}

type Payout

type Payout struct {
	XMLName xml.Name `xml:"symbol"`
	Name    string   `xml:"name,attr"`
	Wins    []*PayoutWin
}

type PayoutWin

type PayoutWin struct {
	XMLName xml.Name `xml:"win"`
	Count   int      `xml:"count,attr"`
	Payout  int      `xml:"payout,attr"`
}

type Payouts

type Payouts struct {
	XMLName xml.Name `xml:"payouts"`
	Payouts []*Payout
}

func BuildPayouts

func BuildPayouts(pt *sgc7game.PayTables) *Payouts

type Reels

type Reels struct {
	Tables []*Table
}

func BuildReels

func BuildReels(reels []*sgc7game.ReelsData, pt *sgc7game.PayTables) *Reels

type StringList

type StringList struct {
	Vals []string `xml:"item"`
}

type Symbol

type Symbol struct {
	XMLName xml.Name `xml:"symbol"`
	Name    string   `xml:"name,attr"`
	Val     int      `xml:"value,attr"`
}

type Symbols

type Symbols struct {
	XMLName xml.Name  `xml:"symbols"`
	Symbols []*Symbol `xml:"symbol"`
}

func BuildSymbols

func BuildSymbols(symbols []string) *Symbols

type Table

type Table struct {
	XMLName      xml.Name      `xml:"table"`
	TableComment string        `xml:",comment"`
	Reel         []*StringList `xml:"reel"`
}

type Weights

type Weights struct {
	Entries []*IntList `xml:"entry"`
}

func BuildIntValWeights2 added in v0.10.356

func BuildIntValWeights2(vw *sgc7game.ValWeights2) *Weights

func BuildWeights

func BuildWeights(weights []int) *Weights

func BuildWeightsEx

func BuildWeightsEx(vals []int, weights []int) *Weights

func BuildWeightsEx2

func BuildWeightsEx2(vw *sgc7game.ValWeights) *Weights

type WeightsArr

type WeightsArr struct {
	Weights []*Weights `xml:"weights"`
}

func BuildIntValWeights2Arr added in v0.10.355

func BuildIntValWeights2Arr(vws []*sgc7game.ValWeights2) *WeightsArr

func BuildWeightsArr

func BuildWeightsArr(weights [][]int) *WeightsArr

func BuildWeightsArrEx

func BuildWeightsArrEx(vals []int, weights [][]int) *WeightsArr

func BuildWeightsArrEx2

func BuildWeightsArrEx2(vals [][]int, weights [][]int) *WeightsArr

func BuildWeightsArrEx3

func BuildWeightsArrEx3(vws []*sgc7game.ValWeights) *WeightsArr

Jump to

Keyboard shortcuts

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