2 Commits
Author SHA1 Message Date
esilva 31140b5df4 API fix. Copied something without looking twice and broke it. Fixed
Docstring fixes
2026-06-30 23:52:14 +01:00
esilva 3857f5983f added the API for the outgauge flag fields 2026-06-30 23:47:02 +01:00
+27
View File
@@ -262,3 +262,30 @@ func (sdk *BeamNGSDK) HasABSLight() bool {
}
// DashLights - functions to check if a given dash light is provided [END]
// Flags - functions to check if a given flag is ON [START]
// HasTurbo returns:
// true if the car has a turbo
// false if it doesn't
func (sdk *BeamNGSDK) HasTurbo() bool {
return sdk.Data.Flags&OG_TURBO != 0
}
// PrefersKm returns:
// true if true
// false if false
// wow
func (sdk *BeamNGSDK) PrefersKm() bool {
return sdk.Data.Flags&OG_KM != 0
}
// PrefersBAR returns:
// true if true
// false if false
// wow
func (sdk *BeamNGSDK) PrefersBAR() bool {
return sdk.Data.Flags&OG_BAR != 0
}
// Flags - functions to check if a given flag is ON [END]