// Code generated by the FlatBuffers compiler. DO NOT EDIT.

package scrabblefb

import (
	flatbuffers "github.com/google/flatbuffers/go"
)

type AdsInfo struct {
	_tab flatbuffers.Table
}

func GetRootAsAdsInfo(buf []byte, offset flatbuffers.UOffsetT) *AdsInfo {
	n := flatbuffers.GetUOffsetT(buf[offset:])
	x := &AdsInfo{}
	x.Init(buf, n+offset)
	return x
}

func FinishAdsInfoBuffer(builder *flatbuffers.Builder, offset flatbuffers.UOffsetT) {
	builder.Finish(offset)
}

func GetSizePrefixedRootAsAdsInfo(buf []byte, offset flatbuffers.UOffsetT) *AdsInfo {
	n := flatbuffers.GetUOffsetT(buf[offset+flatbuffers.SizeUint32:])
	x := &AdsInfo{}
	x.Init(buf, n+offset+flatbuffers.SizeUint32)
	return x
}

func FinishSizePrefixedAdsInfoBuffer(builder *flatbuffers.Builder, offset flatbuffers.UOffsetT) {
	builder.FinishSizePrefixed(offset)
}

func (rcv *AdsInfo) Init(buf []byte, i flatbuffers.UOffsetT) {
	rcv._tab.Bytes = buf
	rcv._tab.Pos = i
}

func (rcv *AdsInfo) Table() flatbuffers.Table {
	return rcv._tab
}

func (rcv *AdsInfo) CooldownGlobalS() int32 {
	o := flatbuffers.UOffsetT(rcv._tab.Offset(4))
	if o != 0 {
		return rcv._tab.GetInt32(o + rcv._tab.Pos)
	}
	return 0
}

func (rcv *AdsInfo) MutateCooldownGlobalS(n int32) bool {
	return rcv._tab.MutateInt32Slot(4, n)
}

func (rcv *AdsInfo) CooldownVsAiS() int32 {
	o := flatbuffers.UOffsetT(rcv._tab.Offset(6))
	if o != 0 {
		return rcv._tab.GetInt32(o + rcv._tab.Pos)
	}
	return 0
}

func (rcv *AdsInfo) MutateCooldownVsAiS(n int32) bool {
	return rcv._tab.MutateInt32Slot(6, n)
}

func (rcv *AdsInfo) CooldownHintS() int32 {
	o := flatbuffers.UOffsetT(rcv._tab.Offset(8))
	if o != 0 {
		return rcv._tab.GetInt32(o + rcv._tab.Pos)
	}
	return 0
}

func (rcv *AdsInfo) MutateCooldownHintS(n int32) bool {
	return rcv._tab.MutateInt32Slot(8, n)
}

func (rcv *AdsInfo) Suppressed() bool {
	o := flatbuffers.UOffsetT(rcv._tab.Offset(10))
	if o != 0 {
		return rcv._tab.GetBool(o + rcv._tab.Pos)
	}
	return false
}

func (rcv *AdsInfo) MutateSuppressed(n bool) bool {
	return rcv._tab.MutateBoolSlot(10, n)
}

func AdsInfoStart(builder *flatbuffers.Builder) {
	builder.StartObject(4)
}
func AdsInfoAddCooldownGlobalS(builder *flatbuffers.Builder, cooldownGlobalS int32) {
	builder.PrependInt32Slot(0, cooldownGlobalS, 0)
}
func AdsInfoAddCooldownVsAiS(builder *flatbuffers.Builder, cooldownVsAiS int32) {
	builder.PrependInt32Slot(1, cooldownVsAiS, 0)
}
func AdsInfoAddCooldownHintS(builder *flatbuffers.Builder, cooldownHintS int32) {
	builder.PrependInt32Slot(2, cooldownHintS, 0)
}
func AdsInfoAddSuppressed(builder *flatbuffers.Builder, suppressed bool) {
	builder.PrependBoolSlot(3, suppressed, false)
}
func AdsInfoEnd(builder *flatbuffers.Builder) flatbuffers.UOffsetT {
	return builder.EndObject()
}
