Compare commits
No commits in common. "4adf1f90b10b932cc093e3ca5074fbce72ca3773" and "289538fdb1fe7f170fc373b43da46161d8b63353" have entirely different histories.
4adf1f90b1
...
289538fdb1
|
|
@ -19,4 +19,4 @@ const (
|
||||||
)
|
)
|
||||||
const NowByte int64 = 10000
|
const NowByte int64 = 10000
|
||||||
|
|
||||||
const GameDataKey = "FortuneDragonData"
|
const GameDataKey = "FortuneData"
|
||||||
|
|
|
||||||
|
|
@ -19,4 +19,4 @@ const (
|
||||||
)
|
)
|
||||||
const NowByte int64 = 10000
|
const NowByte int64 = 10000
|
||||||
|
|
||||||
const GameDataKey = "FortuneMouseData"
|
const GameDataKey = "FortuneData"
|
||||||
|
|
|
||||||
|
|
@ -19,4 +19,4 @@ const (
|
||||||
)
|
)
|
||||||
const NowByte int64 = 10000
|
const NowByte int64 = 10000
|
||||||
|
|
||||||
const GameDataKey = "FortuneOxData"
|
const GameDataKey = "FortuneData"
|
||||||
|
|
|
||||||
|
|
@ -19,4 +19,4 @@ const (
|
||||||
)
|
)
|
||||||
const NowByte int64 = 10000
|
const NowByte int64 = 10000
|
||||||
|
|
||||||
const GameDataKey = "FortuneRabbit"
|
const GameDataKey = "FortuneData"
|
||||||
|
|
|
||||||
|
|
@ -19,4 +19,4 @@ const (
|
||||||
)
|
)
|
||||||
const NowByte int64 = 10000
|
const NowByte int64 = 10000
|
||||||
|
|
||||||
const GameDataKey = "FortuneTigerData"
|
const GameDataKey = "FortuneData"
|
||||||
|
|
|
||||||
|
|
@ -19,4 +19,4 @@ const (
|
||||||
)
|
)
|
||||||
const NowByte int64 = 10000
|
const NowByte int64 = 10000
|
||||||
|
|
||||||
const GameDataKey = "GatesOfOlympusData"
|
const GameDataKey = "FortuneData"
|
||||||
|
|
|
||||||
|
|
@ -1,22 +0,0 @@
|
||||||
package sugarrush
|
|
||||||
|
|
||||||
// 房间类型
|
|
||||||
const (
|
|
||||||
RoomMode_Classic int = iota //经典
|
|
||||||
RoomMode_Max
|
|
||||||
)
|
|
||||||
|
|
||||||
// 场景状态
|
|
||||||
const (
|
|
||||||
SugarRushStateStart int = iota //默认状态
|
|
||||||
SugarRushStateMax
|
|
||||||
)
|
|
||||||
|
|
||||||
// 玩家操作
|
|
||||||
const (
|
|
||||||
SugarRushPlayerOpStart int = iota
|
|
||||||
SugarRushPlayerOpSwitch
|
|
||||||
)
|
|
||||||
const NowByte int64 = 10000
|
|
||||||
|
|
||||||
const GameDataKey = "SugarRushData"
|
|
||||||
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
|
|
@ -1,924 +0,0 @@
|
||||||
//go:build !debug
|
|
||||||
// +build !debug
|
|
||||||
|
|
||||||
// <important: auto generate by excel-to-go converter, do not modify>
|
|
||||||
package base
|
|
||||||
|
|
||||||
import "mongo.games.com/game/gamesrv/slotspkg/internal/exported/excel2go/structs"
|
|
||||||
|
|
||||||
func init() {
|
|
||||||
SugarRushBaseSymbolShowWeight = []*structs.SugarRushBaseSymbolShowWeight{
|
|
||||||
{
|
|
||||||
ID: 1,
|
|
||||||
ItemID: 1,
|
|
||||||
Weight: 8.5,
|
|
||||||
},
|
|
||||||
{
|
|
||||||
ID: 2,
|
|
||||||
ItemID: 2,
|
|
||||||
Weight: 0,
|
|
||||||
},
|
|
||||||
{
|
|
||||||
ID: 3,
|
|
||||||
ItemID: 3,
|
|
||||||
Weight: 80,
|
|
||||||
},
|
|
||||||
{
|
|
||||||
ID: 4,
|
|
||||||
ItemID: 4,
|
|
||||||
Weight: 120,
|
|
||||||
},
|
|
||||||
{
|
|
||||||
ID: 5,
|
|
||||||
ItemID: 5,
|
|
||||||
Weight: 120,
|
|
||||||
},
|
|
||||||
{
|
|
||||||
ID: 6,
|
|
||||||
ItemID: 6,
|
|
||||||
Weight: 150,
|
|
||||||
},
|
|
||||||
{
|
|
||||||
ID: 7,
|
|
||||||
ItemID: 7,
|
|
||||||
Weight: 160,
|
|
||||||
},
|
|
||||||
{
|
|
||||||
ID: 8,
|
|
||||||
ItemID: 8,
|
|
||||||
Weight: 160,
|
|
||||||
},
|
|
||||||
{
|
|
||||||
ID: 9,
|
|
||||||
ItemID: 9,
|
|
||||||
Weight: 160,
|
|
||||||
},
|
|
||||||
}
|
|
||||||
|
|
||||||
SugarRushBaseSymbolShowNumberWeight = []*structs.SugarRushBaseSymbolShowNumberWeight{
|
|
||||||
{
|
|
||||||
ID: 1,
|
|
||||||
ItemID: 1,
|
|
||||||
ShowNumberWeight: []float64{1, 0, 0, 0, 0, 0, 0},
|
|
||||||
},
|
|
||||||
{
|
|
||||||
ID: 2,
|
|
||||||
ItemID: 2,
|
|
||||||
ShowNumberWeight: []float64{0, 0, 0, 0, 0, 0, 0},
|
|
||||||
},
|
|
||||||
{
|
|
||||||
ID: 3,
|
|
||||||
ItemID: 3,
|
|
||||||
ShowNumberWeight: []float64{50, 30, 0, 0, 0, 0, 0},
|
|
||||||
},
|
|
||||||
{
|
|
||||||
ID: 4,
|
|
||||||
ItemID: 4,
|
|
||||||
ShowNumberWeight: []float64{50, 40, 1, 0, 0, 0, 0},
|
|
||||||
},
|
|
||||||
{
|
|
||||||
ID: 5,
|
|
||||||
ItemID: 5,
|
|
||||||
ShowNumberWeight: []float64{50, 50, 2, 0, 0, 0, 0},
|
|
||||||
},
|
|
||||||
{
|
|
||||||
ID: 6,
|
|
||||||
ItemID: 6,
|
|
||||||
ShowNumberWeight: []float64{50, 50, 2, 0, 0, 0, 0},
|
|
||||||
},
|
|
||||||
{
|
|
||||||
ID: 7,
|
|
||||||
ItemID: 7,
|
|
||||||
ShowNumberWeight: []float64{80, 50, 5, 0, 0, 0, 0},
|
|
||||||
},
|
|
||||||
{
|
|
||||||
ID: 8,
|
|
||||||
ItemID: 8,
|
|
||||||
ShowNumberWeight: []float64{80, 50, 5, 0, 0, 0, 0},
|
|
||||||
},
|
|
||||||
{
|
|
||||||
ID: 9,
|
|
||||||
ItemID: 9,
|
|
||||||
ShowNumberWeight: []float64{80, 50, 5, 0, 0, 0, 0},
|
|
||||||
},
|
|
||||||
}
|
|
||||||
|
|
||||||
SugarRushBetBetChangeList = map[int64]*structs.SugarRushBetBetChangeList{
|
|
||||||
0: {
|
|
||||||
Index: 0,
|
|
||||||
BetChangeList: 0.2,
|
|
||||||
BetSizeIndex: 0,
|
|
||||||
BetLevelIndex: 0,
|
|
||||||
},
|
|
||||||
1: {
|
|
||||||
Index: 1,
|
|
||||||
BetChangeList: 0.4,
|
|
||||||
BetSizeIndex: 0,
|
|
||||||
BetLevelIndex: 1,
|
|
||||||
},
|
|
||||||
2: {
|
|
||||||
Index: 2,
|
|
||||||
BetChangeList: 0.6,
|
|
||||||
BetSizeIndex: 0,
|
|
||||||
BetLevelIndex: 2,
|
|
||||||
},
|
|
||||||
3: {
|
|
||||||
Index: 3,
|
|
||||||
BetChangeList: 0.8,
|
|
||||||
BetSizeIndex: 0,
|
|
||||||
BetLevelIndex: 3,
|
|
||||||
},
|
|
||||||
4: {
|
|
||||||
Index: 4,
|
|
||||||
BetChangeList: 1,
|
|
||||||
BetSizeIndex: 0,
|
|
||||||
BetLevelIndex: 4,
|
|
||||||
},
|
|
||||||
5: {
|
|
||||||
Index: 5,
|
|
||||||
BetChangeList: 1.2,
|
|
||||||
BetSizeIndex: 0,
|
|
||||||
BetLevelIndex: 5,
|
|
||||||
},
|
|
||||||
6: {
|
|
||||||
Index: 6,
|
|
||||||
BetChangeList: 1.4,
|
|
||||||
BetSizeIndex: 0,
|
|
||||||
BetLevelIndex: 6,
|
|
||||||
},
|
|
||||||
7: {
|
|
||||||
Index: 7,
|
|
||||||
BetChangeList: 1.6,
|
|
||||||
BetSizeIndex: 0,
|
|
||||||
BetLevelIndex: 7,
|
|
||||||
},
|
|
||||||
8: {
|
|
||||||
Index: 8,
|
|
||||||
BetChangeList: 1.8,
|
|
||||||
BetSizeIndex: 0,
|
|
||||||
BetLevelIndex: 8,
|
|
||||||
},
|
|
||||||
9: {
|
|
||||||
Index: 9,
|
|
||||||
BetChangeList: 2,
|
|
||||||
BetSizeIndex: 0,
|
|
||||||
BetLevelIndex: 9,
|
|
||||||
},
|
|
||||||
10: {
|
|
||||||
Index: 10,
|
|
||||||
BetChangeList: 4,
|
|
||||||
BetSizeIndex: 1,
|
|
||||||
BetLevelIndex: 1,
|
|
||||||
},
|
|
||||||
11: {
|
|
||||||
Index: 11,
|
|
||||||
BetChangeList: 6,
|
|
||||||
BetSizeIndex: 1,
|
|
||||||
BetLevelIndex: 2,
|
|
||||||
},
|
|
||||||
12: {
|
|
||||||
Index: 12,
|
|
||||||
BetChangeList: 8,
|
|
||||||
BetSizeIndex: 1,
|
|
||||||
BetLevelIndex: 3,
|
|
||||||
},
|
|
||||||
13: {
|
|
||||||
Index: 13,
|
|
||||||
BetChangeList: 10,
|
|
||||||
BetSizeIndex: 1,
|
|
||||||
BetLevelIndex: 4,
|
|
||||||
},
|
|
||||||
14: {
|
|
||||||
Index: 14,
|
|
||||||
BetChangeList: 12,
|
|
||||||
BetSizeIndex: 1,
|
|
||||||
BetLevelIndex: 5,
|
|
||||||
},
|
|
||||||
15: {
|
|
||||||
Index: 15,
|
|
||||||
BetChangeList: 14,
|
|
||||||
BetSizeIndex: 1,
|
|
||||||
BetLevelIndex: 6,
|
|
||||||
},
|
|
||||||
16: {
|
|
||||||
Index: 16,
|
|
||||||
BetChangeList: 15,
|
|
||||||
BetSizeIndex: 4,
|
|
||||||
BetLevelIndex: 0,
|
|
||||||
},
|
|
||||||
17: {
|
|
||||||
Index: 17,
|
|
||||||
BetChangeList: 16,
|
|
||||||
BetSizeIndex: 1,
|
|
||||||
BetLevelIndex: 7,
|
|
||||||
},
|
|
||||||
18: {
|
|
||||||
Index: 18,
|
|
||||||
BetChangeList: 18,
|
|
||||||
BetSizeIndex: 1,
|
|
||||||
BetLevelIndex: 8,
|
|
||||||
},
|
|
||||||
19: {
|
|
||||||
Index: 19,
|
|
||||||
BetChangeList: 20,
|
|
||||||
BetSizeIndex: 1,
|
|
||||||
BetLevelIndex: 9,
|
|
||||||
},
|
|
||||||
20: {
|
|
||||||
Index: 20,
|
|
||||||
BetChangeList: 24,
|
|
||||||
BetSizeIndex: 2,
|
|
||||||
BetLevelIndex: 5,
|
|
||||||
},
|
|
||||||
21: {
|
|
||||||
Index: 21,
|
|
||||||
BetChangeList: 28,
|
|
||||||
BetSizeIndex: 2,
|
|
||||||
BetLevelIndex: 6,
|
|
||||||
},
|
|
||||||
22: {
|
|
||||||
Index: 22,
|
|
||||||
BetChangeList: 30,
|
|
||||||
BetSizeIndex: 3,
|
|
||||||
BetLevelIndex: 2,
|
|
||||||
},
|
|
||||||
23: {
|
|
||||||
Index: 23,
|
|
||||||
BetChangeList: 32,
|
|
||||||
BetSizeIndex: 2,
|
|
||||||
BetLevelIndex: 7,
|
|
||||||
},
|
|
||||||
24: {
|
|
||||||
Index: 24,
|
|
||||||
BetChangeList: 36,
|
|
||||||
BetSizeIndex: 2,
|
|
||||||
BetLevelIndex: 8,
|
|
||||||
},
|
|
||||||
25: {
|
|
||||||
Index: 25,
|
|
||||||
BetChangeList: 40,
|
|
||||||
BetSizeIndex: 2,
|
|
||||||
BetLevelIndex: 9,
|
|
||||||
},
|
|
||||||
26: {
|
|
||||||
Index: 26,
|
|
||||||
BetChangeList: 45,
|
|
||||||
BetSizeIndex: 4,
|
|
||||||
BetLevelIndex: 2,
|
|
||||||
},
|
|
||||||
27: {
|
|
||||||
Index: 27,
|
|
||||||
BetChangeList: 50,
|
|
||||||
BetSizeIndex: 3,
|
|
||||||
BetLevelIndex: 4,
|
|
||||||
},
|
|
||||||
28: {
|
|
||||||
Index: 28,
|
|
||||||
BetChangeList: 60,
|
|
||||||
BetSizeIndex: 3,
|
|
||||||
BetLevelIndex: 5,
|
|
||||||
},
|
|
||||||
29: {
|
|
||||||
Index: 29,
|
|
||||||
BetChangeList: 70,
|
|
||||||
BetSizeIndex: 3,
|
|
||||||
BetLevelIndex: 6,
|
|
||||||
},
|
|
||||||
30: {
|
|
||||||
Index: 30,
|
|
||||||
BetChangeList: 75,
|
|
||||||
BetSizeIndex: 4,
|
|
||||||
BetLevelIndex: 4,
|
|
||||||
},
|
|
||||||
31: {
|
|
||||||
Index: 31,
|
|
||||||
BetChangeList: 80,
|
|
||||||
BetSizeIndex: 3,
|
|
||||||
BetLevelIndex: 7,
|
|
||||||
},
|
|
||||||
32: {
|
|
||||||
Index: 32,
|
|
||||||
BetChangeList: 90,
|
|
||||||
BetSizeIndex: 3,
|
|
||||||
BetLevelIndex: 8,
|
|
||||||
},
|
|
||||||
33: {
|
|
||||||
Index: 33,
|
|
||||||
BetChangeList: 100,
|
|
||||||
BetSizeIndex: 3,
|
|
||||||
BetLevelIndex: 9,
|
|
||||||
},
|
|
||||||
34: {
|
|
||||||
Index: 34,
|
|
||||||
BetChangeList: 105,
|
|
||||||
BetSizeIndex: 4,
|
|
||||||
BetLevelIndex: 6,
|
|
||||||
},
|
|
||||||
35: {
|
|
||||||
Index: 35,
|
|
||||||
BetChangeList: 120,
|
|
||||||
BetSizeIndex: 4,
|
|
||||||
BetLevelIndex: 7,
|
|
||||||
},
|
|
||||||
36: {
|
|
||||||
Index: 36,
|
|
||||||
BetChangeList: 135,
|
|
||||||
BetSizeIndex: 4,
|
|
||||||
BetLevelIndex: 8,
|
|
||||||
},
|
|
||||||
37: {
|
|
||||||
Index: 37,
|
|
||||||
BetChangeList: 150,
|
|
||||||
BetSizeIndex: 4,
|
|
||||||
BetLevelIndex: 9,
|
|
||||||
},
|
|
||||||
38: {
|
|
||||||
Index: 38,
|
|
||||||
BetChangeList: 160,
|
|
||||||
BetSizeIndex: 5,
|
|
||||||
BetLevelIndex: 3,
|
|
||||||
},
|
|
||||||
39: {
|
|
||||||
Index: 39,
|
|
||||||
BetChangeList: 200,
|
|
||||||
BetSizeIndex: 5,
|
|
||||||
BetLevelIndex: 4,
|
|
||||||
},
|
|
||||||
40: {
|
|
||||||
Index: 40,
|
|
||||||
BetChangeList: 240,
|
|
||||||
BetSizeIndex: 5,
|
|
||||||
BetLevelIndex: 5,
|
|
||||||
},
|
|
||||||
41: {
|
|
||||||
Index: 41,
|
|
||||||
BetChangeList: 280,
|
|
||||||
BetSizeIndex: 5,
|
|
||||||
BetLevelIndex: 6,
|
|
||||||
},
|
|
||||||
42: {
|
|
||||||
Index: 42,
|
|
||||||
BetChangeList: 320,
|
|
||||||
BetSizeIndex: 5,
|
|
||||||
BetLevelIndex: 7,
|
|
||||||
},
|
|
||||||
43: {
|
|
||||||
Index: 43,
|
|
||||||
BetChangeList: 360,
|
|
||||||
BetSizeIndex: 5,
|
|
||||||
BetLevelIndex: 8,
|
|
||||||
},
|
|
||||||
44: {
|
|
||||||
Index: 44,
|
|
||||||
BetChangeList: 400,
|
|
||||||
BetSizeIndex: 5,
|
|
||||||
BetLevelIndex: 9,
|
|
||||||
},
|
|
||||||
45: {
|
|
||||||
Index: 45,
|
|
||||||
BetChangeList: 3,
|
|
||||||
BetSizeIndex: 6,
|
|
||||||
BetLevelIndex: 0,
|
|
||||||
},
|
|
||||||
46: {
|
|
||||||
Index: 46,
|
|
||||||
BetChangeList: 5,
|
|
||||||
BetSizeIndex: 7,
|
|
||||||
BetLevelIndex: 0,
|
|
||||||
},
|
|
||||||
47: {
|
|
||||||
Index: 47,
|
|
||||||
BetChangeList: 25,
|
|
||||||
BetSizeIndex: 8,
|
|
||||||
BetLevelIndex: 0,
|
|
||||||
},
|
|
||||||
48: {
|
|
||||||
Index: 48,
|
|
||||||
BetChangeList: 300,
|
|
||||||
BetSizeIndex: 9,
|
|
||||||
BetLevelIndex: 0,
|
|
||||||
},
|
|
||||||
}
|
|
||||||
|
|
||||||
SugarRushBetBetLevel = map[int64]*structs.SugarRushBetBetLevel{
|
|
||||||
0: {
|
|
||||||
Index: 0,
|
|
||||||
BetLevel: 1,
|
|
||||||
},
|
|
||||||
1: {
|
|
||||||
Index: 1,
|
|
||||||
BetLevel: 2,
|
|
||||||
},
|
|
||||||
2: {
|
|
||||||
Index: 2,
|
|
||||||
BetLevel: 3,
|
|
||||||
},
|
|
||||||
3: {
|
|
||||||
Index: 3,
|
|
||||||
BetLevel: 4,
|
|
||||||
},
|
|
||||||
4: {
|
|
||||||
Index: 4,
|
|
||||||
BetLevel: 5,
|
|
||||||
},
|
|
||||||
5: {
|
|
||||||
Index: 5,
|
|
||||||
BetLevel: 6,
|
|
||||||
},
|
|
||||||
6: {
|
|
||||||
Index: 6,
|
|
||||||
BetLevel: 7,
|
|
||||||
},
|
|
||||||
7: {
|
|
||||||
Index: 7,
|
|
||||||
BetLevel: 8,
|
|
||||||
},
|
|
||||||
8: {
|
|
||||||
Index: 8,
|
|
||||||
BetLevel: 9,
|
|
||||||
},
|
|
||||||
9: {
|
|
||||||
Index: 9,
|
|
||||||
BetLevel: 10,
|
|
||||||
},
|
|
||||||
}
|
|
||||||
|
|
||||||
SugarRushBetBetLine = map[int64]*structs.SugarRushBetBetLine{
|
|
||||||
0: {
|
|
||||||
Index: 0,
|
|
||||||
BetLine: 20,
|
|
||||||
BaseBet: 1,
|
|
||||||
},
|
|
||||||
}
|
|
||||||
|
|
||||||
SugarRushBetBetSize = map[int64]*structs.SugarRushBetBetSize{
|
|
||||||
0: {
|
|
||||||
Index: 0,
|
|
||||||
BetSize: 100,
|
|
||||||
},
|
|
||||||
1: {
|
|
||||||
Index: 1,
|
|
||||||
BetSize: 1000,
|
|
||||||
},
|
|
||||||
2: {
|
|
||||||
Index: 2,
|
|
||||||
BetSize: 2000,
|
|
||||||
},
|
|
||||||
3: {
|
|
||||||
Index: 3,
|
|
||||||
BetSize: 5000,
|
|
||||||
},
|
|
||||||
4: {
|
|
||||||
Index: 4,
|
|
||||||
BetSize: 7500,
|
|
||||||
},
|
|
||||||
5: {
|
|
||||||
Index: 5,
|
|
||||||
BetSize: 20000,
|
|
||||||
},
|
|
||||||
6: {
|
|
||||||
Index: 6,
|
|
||||||
BetSize: 1500,
|
|
||||||
},
|
|
||||||
7: {
|
|
||||||
Index: 7,
|
|
||||||
BetSize: 2500,
|
|
||||||
},
|
|
||||||
8: {
|
|
||||||
Index: 8,
|
|
||||||
BetSize: 12500,
|
|
||||||
},
|
|
||||||
9: {
|
|
||||||
Index: 9,
|
|
||||||
BetSize: 150000,
|
|
||||||
},
|
|
||||||
}
|
|
||||||
|
|
||||||
SugarRushBetFirstBet = map[int64]*structs.SugarRushBetFirstBet{
|
|
||||||
1: {
|
|
||||||
Index: 1,
|
|
||||||
BetSizeIndex: 1,
|
|
||||||
BetLevelIndex: 1,
|
|
||||||
},
|
|
||||||
}
|
|
||||||
|
|
||||||
SugarRushBuyFreeScatterShowWeight = []*structs.SugarRushBuyFreeScatterShowWeight{
|
|
||||||
{
|
|
||||||
ID: 1,
|
|
||||||
ScatterCount: 1,
|
|
||||||
Weight: 0,
|
|
||||||
},
|
|
||||||
{
|
|
||||||
ID: 2,
|
|
||||||
ScatterCount: 2,
|
|
||||||
Weight: 0,
|
|
||||||
},
|
|
||||||
{
|
|
||||||
ID: 3,
|
|
||||||
ScatterCount: 3,
|
|
||||||
Weight: 1900,
|
|
||||||
},
|
|
||||||
{
|
|
||||||
ID: 4,
|
|
||||||
ScatterCount: 4,
|
|
||||||
Weight: 99,
|
|
||||||
},
|
|
||||||
{
|
|
||||||
ID: 5,
|
|
||||||
ScatterCount: 5,
|
|
||||||
Weight: 1,
|
|
||||||
},
|
|
||||||
{
|
|
||||||
ID: 6,
|
|
||||||
ScatterCount: 6,
|
|
||||||
Weight: 0,
|
|
||||||
},
|
|
||||||
{
|
|
||||||
ID: 7,
|
|
||||||
ScatterCount: 7,
|
|
||||||
Weight: 0,
|
|
||||||
},
|
|
||||||
}
|
|
||||||
|
|
||||||
SugarRushFormation = []*structs.SugarRushFormation{
|
|
||||||
{
|
|
||||||
SpinType: 1,
|
|
||||||
NodeType: "BaseSpin",
|
|
||||||
ID: 1,
|
|
||||||
SeqID: 1,
|
|
||||||
Reel: "BaseSpin",
|
|
||||||
Matrix: "MatchForm7X7TypeA",
|
|
||||||
Symbol: "Default",
|
|
||||||
FirstInitMethod: 2,
|
|
||||||
OtherInitMethod: 3,
|
|
||||||
FirstInitSymbols: []int64{},
|
|
||||||
OtherInitSymbols: []int64{},
|
|
||||||
},
|
|
||||||
{
|
|
||||||
SpinType: 2,
|
|
||||||
NodeType: "FreeSpin",
|
|
||||||
ID: 2,
|
|
||||||
SeqID: 1,
|
|
||||||
Reel: "FreeSpin",
|
|
||||||
Matrix: "MatchForm7X7TypeA",
|
|
||||||
Symbol: "Default",
|
|
||||||
FirstInitMethod: 3,
|
|
||||||
OtherInitMethod: 3,
|
|
||||||
FirstInitSymbols: []int64{},
|
|
||||||
OtherInitSymbols: []int64{},
|
|
||||||
},
|
|
||||||
}
|
|
||||||
|
|
||||||
SugarRushFreeSymbolShowWeight = []*structs.SugarRushFreeSymbolShowWeight{
|
|
||||||
{
|
|
||||||
ID: 1,
|
|
||||||
ItemID: 1,
|
|
||||||
Weight: 8,
|
|
||||||
},
|
|
||||||
{
|
|
||||||
ID: 2,
|
|
||||||
ItemID: 2,
|
|
||||||
Weight: 0,
|
|
||||||
},
|
|
||||||
{
|
|
||||||
ID: 3,
|
|
||||||
ItemID: 3,
|
|
||||||
Weight: 100,
|
|
||||||
},
|
|
||||||
{
|
|
||||||
ID: 4,
|
|
||||||
ItemID: 4,
|
|
||||||
Weight: 120,
|
|
||||||
},
|
|
||||||
{
|
|
||||||
ID: 5,
|
|
||||||
ItemID: 5,
|
|
||||||
Weight: 120,
|
|
||||||
},
|
|
||||||
{
|
|
||||||
ID: 6,
|
|
||||||
ItemID: 6,
|
|
||||||
Weight: 150,
|
|
||||||
},
|
|
||||||
{
|
|
||||||
ID: 7,
|
|
||||||
ItemID: 7,
|
|
||||||
Weight: 150,
|
|
||||||
},
|
|
||||||
{
|
|
||||||
ID: 8,
|
|
||||||
ItemID: 8,
|
|
||||||
Weight: 150,
|
|
||||||
},
|
|
||||||
{
|
|
||||||
ID: 9,
|
|
||||||
ItemID: 9,
|
|
||||||
Weight: 150,
|
|
||||||
},
|
|
||||||
}
|
|
||||||
|
|
||||||
SugarRushFreeSymbolShowNumberWeight = []*structs.SugarRushFreeSymbolShowNumberWeight{
|
|
||||||
{
|
|
||||||
ID: 1,
|
|
||||||
ItemID: 1,
|
|
||||||
ShowNumberWeight: []float64{1, 0, 0, 0, 0, 0, 0},
|
|
||||||
},
|
|
||||||
{
|
|
||||||
ID: 2,
|
|
||||||
ItemID: 2,
|
|
||||||
ShowNumberWeight: []float64{0, 0, 0, 0, 0, 0, 0},
|
|
||||||
},
|
|
||||||
{
|
|
||||||
ID: 3,
|
|
||||||
ItemID: 3,
|
|
||||||
ShowNumberWeight: []float64{40, 50, 5, 0, 0, 0, 0},
|
|
||||||
},
|
|
||||||
{
|
|
||||||
ID: 4,
|
|
||||||
ItemID: 4,
|
|
||||||
ShowNumberWeight: []float64{50, 60, 6, 0, 0, 0, 0},
|
|
||||||
},
|
|
||||||
{
|
|
||||||
ID: 5,
|
|
||||||
ItemID: 5,
|
|
||||||
ShowNumberWeight: []float64{50, 60, 6, 0, 0, 0, 0},
|
|
||||||
},
|
|
||||||
{
|
|
||||||
ID: 6,
|
|
||||||
ItemID: 6,
|
|
||||||
ShowNumberWeight: []float64{80, 90, 9, 0, 0, 0, 0},
|
|
||||||
},
|
|
||||||
{
|
|
||||||
ID: 7,
|
|
||||||
ItemID: 7,
|
|
||||||
ShowNumberWeight: []float64{90, 100, 20, 0, 0, 0, 0},
|
|
||||||
},
|
|
||||||
{
|
|
||||||
ID: 8,
|
|
||||||
ItemID: 8,
|
|
||||||
ShowNumberWeight: []float64{90, 100, 20, 0, 0, 0, 0},
|
|
||||||
},
|
|
||||||
{
|
|
||||||
ID: 9,
|
|
||||||
ItemID: 9,
|
|
||||||
ShowNumberWeight: []float64{90, 100, 20, 0, 0, 0, 0},
|
|
||||||
},
|
|
||||||
}
|
|
||||||
|
|
||||||
SugarRushMultiplier = []*structs.SugarRushMultiplier{
|
|
||||||
{
|
|
||||||
ID: 1,
|
|
||||||
MatchTimes: 0,
|
|
||||||
Activate: 0,
|
|
||||||
Multiple: 0,
|
|
||||||
},
|
|
||||||
{
|
|
||||||
ID: 2,
|
|
||||||
MatchTimes: 1,
|
|
||||||
Activate: 0,
|
|
||||||
Multiple: 0,
|
|
||||||
},
|
|
||||||
{
|
|
||||||
ID: 3,
|
|
||||||
MatchTimes: 2,
|
|
||||||
Activate: 1,
|
|
||||||
Multiple: 2,
|
|
||||||
},
|
|
||||||
{
|
|
||||||
ID: 4,
|
|
||||||
MatchTimes: 3,
|
|
||||||
Activate: 1,
|
|
||||||
Multiple: 4,
|
|
||||||
},
|
|
||||||
{
|
|
||||||
ID: 5,
|
|
||||||
MatchTimes: 4,
|
|
||||||
Activate: 1,
|
|
||||||
Multiple: 8,
|
|
||||||
},
|
|
||||||
{
|
|
||||||
ID: 6,
|
|
||||||
MatchTimes: 5,
|
|
||||||
Activate: 1,
|
|
||||||
Multiple: 16,
|
|
||||||
},
|
|
||||||
{
|
|
||||||
ID: 7,
|
|
||||||
MatchTimes: 6,
|
|
||||||
Activate: 1,
|
|
||||||
Multiple: 32,
|
|
||||||
},
|
|
||||||
{
|
|
||||||
ID: 8,
|
|
||||||
MatchTimes: 7,
|
|
||||||
Activate: 1,
|
|
||||||
Multiple: 64,
|
|
||||||
},
|
|
||||||
{
|
|
||||||
ID: 9,
|
|
||||||
MatchTimes: 8,
|
|
||||||
Activate: 1,
|
|
||||||
Multiple: 128,
|
|
||||||
},
|
|
||||||
}
|
|
||||||
|
|
||||||
SugarRushOthers = []*structs.SugarRushOthers{
|
|
||||||
{
|
|
||||||
MaxScatterPerCol: 1,
|
|
||||||
BuyFreeTotalBetMultiplier: 100,
|
|
||||||
FallWeightMultiplier: 1,
|
|
||||||
FreespinMaxWin: 5000,
|
|
||||||
},
|
|
||||||
}
|
|
||||||
|
|
||||||
SugarRushReelBaseSpinRange = [][]int64{
|
|
||||||
{7, 7, 7, 7, 7, 7, 7},
|
|
||||||
}
|
|
||||||
|
|
||||||
SugarRushReelBaseSpinReel = [][]int64{
|
|
||||||
{5, 8, 8, 5, 8, 8, 7},
|
|
||||||
{6, 7, 4, 6, 7, 4, 3},
|
|
||||||
{5, 9, 5, 5, 9, 5, 9},
|
|
||||||
{3, 5, 6, 3, 5, 6, 6},
|
|
||||||
{9, 3, 7, 9, 3, 7, 9},
|
|
||||||
{6, 6, 8, 6, 6, 8, 3},
|
|
||||||
{9, 6, 9, 9, 6, 9, 5},
|
|
||||||
}
|
|
||||||
|
|
||||||
SugarRushReelBaseSpinWeight = [][]float64{
|
|
||||||
{1, 1, 1, 1, 1, 1, 1},
|
|
||||||
{1, 1, 1, 1, 1, 1, 1},
|
|
||||||
{1, 1, 1, 1, 1, 1, 1},
|
|
||||||
{1, 1, 1, 1, 1, 1, 1},
|
|
||||||
{1, 1, 1, 1, 1, 1, 1},
|
|
||||||
{1, 1, 1, 1, 1, 1, 1},
|
|
||||||
{1, 1, 1, 1, 1, 1, 1},
|
|
||||||
}
|
|
||||||
|
|
||||||
SugarRushReelFreeSpinRange = [][]int64{
|
|
||||||
{7, 7, 7, 7, 7, 7, 7},
|
|
||||||
}
|
|
||||||
|
|
||||||
SugarRushReelFreeSpinReel = [][]int64{
|
|
||||||
{1, 2, 3, 4, 5, 6, 7},
|
|
||||||
{1, 2, 3, 4, 5, 6, 7},
|
|
||||||
{1, 2, 3, 4, 5, 6, 7},
|
|
||||||
{1, 2, 3, 4, 5, 6, 7},
|
|
||||||
{1, 2, 3, 4, 5, 6, 7},
|
|
||||||
{1, 2, 3, 4, 5, 6, 7},
|
|
||||||
{1, 2, 3, 4, 5, 6, 7},
|
|
||||||
}
|
|
||||||
|
|
||||||
SugarRushReelFreeSpinWeight = [][]float64{
|
|
||||||
{1, 1, 1, 1, 1, 1, 1},
|
|
||||||
{1, 1, 1, 1, 1, 1, 1},
|
|
||||||
{1, 1, 1, 1, 1, 1, 1},
|
|
||||||
{1, 1, 1, 1, 1, 1, 1},
|
|
||||||
{1, 1, 1, 1, 1, 1, 1},
|
|
||||||
{1, 1, 1, 1, 1, 1, 1},
|
|
||||||
{1, 1, 1, 1, 1, 1, 1},
|
|
||||||
}
|
|
||||||
|
|
||||||
SugarRushScatter = map[int64]*structs.SugarRushScatter{
|
|
||||||
1: {
|
|
||||||
ScatterCount: 1,
|
|
||||||
FreeSpinBouts: 0,
|
|
||||||
FreeSpinExtraBouts: 0,
|
|
||||||
BasePayrate: 0,
|
|
||||||
FreePayrate: 0,
|
|
||||||
},
|
|
||||||
2: {
|
|
||||||
ScatterCount: 2,
|
|
||||||
FreeSpinBouts: 0,
|
|
||||||
FreeSpinExtraBouts: 0,
|
|
||||||
BasePayrate: 0,
|
|
||||||
FreePayrate: 0,
|
|
||||||
},
|
|
||||||
3: {
|
|
||||||
ScatterCount: 3,
|
|
||||||
FreeSpinBouts: 10,
|
|
||||||
FreeSpinExtraBouts: 10,
|
|
||||||
BasePayrate: 0,
|
|
||||||
FreePayrate: 0,
|
|
||||||
},
|
|
||||||
4: {
|
|
||||||
ScatterCount: 4,
|
|
||||||
FreeSpinBouts: 12,
|
|
||||||
FreeSpinExtraBouts: 12,
|
|
||||||
BasePayrate: 0,
|
|
||||||
FreePayrate: 0,
|
|
||||||
},
|
|
||||||
5: {
|
|
||||||
ScatterCount: 5,
|
|
||||||
FreeSpinBouts: 15,
|
|
||||||
FreeSpinExtraBouts: 15,
|
|
||||||
BasePayrate: 0,
|
|
||||||
FreePayrate: 0,
|
|
||||||
},
|
|
||||||
6: {
|
|
||||||
ScatterCount: 6,
|
|
||||||
FreeSpinBouts: 20,
|
|
||||||
FreeSpinExtraBouts: 20,
|
|
||||||
BasePayrate: 0,
|
|
||||||
FreePayrate: 0,
|
|
||||||
},
|
|
||||||
7: {
|
|
||||||
ScatterCount: 7,
|
|
||||||
FreeSpinBouts: 30,
|
|
||||||
FreeSpinExtraBouts: 30,
|
|
||||||
BasePayrate: 0,
|
|
||||||
FreePayrate: 0,
|
|
||||||
},
|
|
||||||
}
|
|
||||||
|
|
||||||
SugarRushSymbol = map[int64]*structs.SugarRushSymbol{
|
|
||||||
1: {
|
|
||||||
ID: 1,
|
|
||||||
Name: "Scatter",
|
|
||||||
IsWild: false,
|
|
||||||
Group: []int64{1},
|
|
||||||
PayRate: []int64{0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0},
|
|
||||||
ClientOrder: 0,
|
|
||||||
ClientDsc: "",
|
|
||||||
},
|
|
||||||
2: {
|
|
||||||
ID: 2,
|
|
||||||
Name: "无",
|
|
||||||
IsWild: false,
|
|
||||||
Group: []int64{2},
|
|
||||||
PayRate: []int64{0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0},
|
|
||||||
ClientOrder: 0,
|
|
||||||
ClientDsc: "",
|
|
||||||
},
|
|
||||||
3: {
|
|
||||||
ID: 3,
|
|
||||||
Name: "粉球",
|
|
||||||
IsWild: false,
|
|
||||||
Group: []int64{3},
|
|
||||||
PayRate: []int64{0, 0, 0, 0, 20, 30, 35, 40, 50, 100, 150, 300, 700, 1400, 3000, 3000, 3000, 3000, 3000, 3000, 3000, 3000, 3000, 3000, 3000, 3000, 3000, 3000, 3000, 3000, 3000, 3000, 3000, 3000, 3000, 3000, 3000, 3000, 3000, 3000, 3000, 3000, 3000, 3000, 3000, 3000, 3000, 3000, 3000},
|
|
||||||
ClientOrder: 1,
|
|
||||||
ClientDsc: "",
|
|
||||||
},
|
|
||||||
4: {
|
|
||||||
ID: 4,
|
|
||||||
Name: "橙心",
|
|
||||||
IsWild: false,
|
|
||||||
Group: []int64{4},
|
|
||||||
PayRate: []int64{0, 0, 0, 0, 15, 20, 25, 30, 40, 80, 120, 250, 600, 1200, 2000, 2000, 2000, 2000, 2000, 2000, 2000, 2000, 2000, 2000, 2000, 2000, 2000, 2000, 2000, 2000, 2000, 2000, 2000, 2000, 2000, 2000, 2000, 2000, 2000, 2000, 2000, 2000, 2000, 2000, 2000, 2000, 2000, 2000, 2000},
|
|
||||||
ClientOrder: 2,
|
|
||||||
ClientDsc: "",
|
|
||||||
},
|
|
||||||
5: {
|
|
||||||
ID: 5,
|
|
||||||
Name: "紫豆",
|
|
||||||
IsWild: false,
|
|
||||||
Group: []int64{5},
|
|
||||||
PayRate: []int64{0, 0, 0, 0, 10, 15, 20, 25, 30, 60, 90, 200, 400, 800, 1200, 1200, 1200, 1200, 1200, 1200, 1200, 1200, 1200, 1200, 1200, 1200, 1200, 1200, 1200, 1200, 1200, 1200, 1200, 1200, 1200, 1200, 1200, 1200, 1200, 1200, 1200, 1200, 1200, 1200, 1200, 1200, 1200, 1200, 1200},
|
|
||||||
ClientOrder: 3,
|
|
||||||
ClientDsc: "",
|
|
||||||
},
|
|
||||||
6: {
|
|
||||||
ID: 6,
|
|
||||||
Name: "绿星",
|
|
||||||
IsWild: false,
|
|
||||||
Group: []int64{6},
|
|
||||||
PayRate: []int64{0, 0, 0, 0, 8, 10, 15, 20, 25, 40, 60, 100, 200, 400, 800, 800, 800, 800, 800, 800, 800, 800, 800, 800, 800, 800, 800, 800, 800, 800, 800, 800, 800, 800, 800, 800, 800, 800, 800, 800, 800, 800, 800, 800, 800, 800, 800, 800, 800},
|
|
||||||
ClientOrder: 4,
|
|
||||||
ClientDsc: "",
|
|
||||||
},
|
|
||||||
7: {
|
|
||||||
ID: 7,
|
|
||||||
Name: "红熊",
|
|
||||||
IsWild: false,
|
|
||||||
Group: []int64{7},
|
|
||||||
PayRate: []int64{0, 0, 0, 0, 6, 8, 10, 15, 20, 30, 50, 70, 160, 300, 600, 600, 600, 600, 600, 600, 600, 600, 600, 600, 600, 600, 600, 600, 600, 600, 600, 600, 600, 600, 600, 600, 600, 600, 600, 600, 600, 600, 600, 600, 600, 600, 600, 600, 600},
|
|
||||||
ClientOrder: 5,
|
|
||||||
ClientDsc: "",
|
|
||||||
},
|
|
||||||
8: {
|
|
||||||
ID: 8,
|
|
||||||
Name: "紫熊",
|
|
||||||
IsWild: false,
|
|
||||||
Group: []int64{8},
|
|
||||||
PayRate: []int64{0, 0, 0, 0, 5, 6, 8, 10, 15, 25, 40, 60, 120, 240, 500, 500, 500, 500, 500, 500, 500, 500, 500, 500, 500, 500, 500, 500, 500, 500, 500, 500, 500, 500, 500, 500, 500, 500, 500, 500, 500, 500, 500, 500, 500, 500, 500, 500, 500},
|
|
||||||
ClientOrder: 6,
|
|
||||||
ClientDsc: "",
|
|
||||||
},
|
|
||||||
9: {
|
|
||||||
ID: 9,
|
|
||||||
Name: "橙熊",
|
|
||||||
IsWild: false,
|
|
||||||
Group: []int64{9},
|
|
||||||
PayRate: []int64{0, 0, 0, 0, 4, 5, 6, 8, 10, 20, 30, 50, 100, 200, 400, 400, 400, 400, 400, 400, 400, 400, 400, 400, 400, 400, 400, 400, 400, 400, 400, 400, 400, 400, 400, 400, 400, 400, 400, 400, 400, 400, 400, 400, 400, 400, 400, 400, 400},
|
|
||||||
ClientOrder: 7,
|
|
||||||
ClientDsc: "",
|
|
||||||
},
|
|
||||||
}
|
|
||||||
|
|
||||||
SugarRushSymbolBetRatio = []*structs.SugarRushSymbolBetRatio{
|
|
||||||
{
|
|
||||||
BetRatio: 1,
|
|
||||||
},
|
|
||||||
}
|
|
||||||
|
|
||||||
}
|
|
||||||
|
|
@ -250,28 +250,6 @@ var (
|
||||||
PrizeModelPrizeModelTypeB = map[int64]*structs.PrizeModelPrizeModelTypeB{}
|
PrizeModelPrizeModelTypeB = map[int64]*structs.PrizeModelPrizeModelTypeB{}
|
||||||
SimulatorFSMultiLevel = []*structs.SimulatorFSMultiLevel{}
|
SimulatorFSMultiLevel = []*structs.SimulatorFSMultiLevel{}
|
||||||
SimulatorMultiLevel = []*structs.SimulatorMultiLevel{}
|
SimulatorMultiLevel = []*structs.SimulatorMultiLevel{}
|
||||||
SugarRushBaseSymbolShowWeight = []*structs.SugarRushBaseSymbolShowWeight{}
|
|
||||||
SugarRushBaseSymbolShowNumberWeight = []*structs.SugarRushBaseSymbolShowNumberWeight{}
|
|
||||||
SugarRushBetBetChangeList = map[int64]*structs.SugarRushBetBetChangeList{}
|
|
||||||
SugarRushBetBetLevel = map[int64]*structs.SugarRushBetBetLevel{}
|
|
||||||
SugarRushBetBetLine = map[int64]*structs.SugarRushBetBetLine{}
|
|
||||||
SugarRushBetBetSize = map[int64]*structs.SugarRushBetBetSize{}
|
|
||||||
SugarRushBetFirstBet = map[int64]*structs.SugarRushBetFirstBet{}
|
|
||||||
SugarRushBuyFreeScatterShowWeight = []*structs.SugarRushBuyFreeScatterShowWeight{}
|
|
||||||
SugarRushFormation = []*structs.SugarRushFormation{}
|
|
||||||
SugarRushFreeSymbolShowWeight = []*structs.SugarRushFreeSymbolShowWeight{}
|
|
||||||
SugarRushFreeSymbolShowNumberWeight = []*structs.SugarRushFreeSymbolShowNumberWeight{}
|
|
||||||
SugarRushMultiplier = []*structs.SugarRushMultiplier{}
|
|
||||||
SugarRushOthers = []*structs.SugarRushOthers{}
|
|
||||||
SugarRushReelBaseSpinRange = [][]int64{}
|
|
||||||
SugarRushReelBaseSpinReel = [][]int64{}
|
|
||||||
SugarRushReelBaseSpinWeight = [][]float64{}
|
|
||||||
SugarRushReelFreeSpinRange = [][]int64{}
|
|
||||||
SugarRushReelFreeSpinReel = [][]int64{}
|
|
||||||
SugarRushReelFreeSpinWeight = [][]float64{}
|
|
||||||
SugarRushScatter = map[int64]*structs.SugarRushScatter{}
|
|
||||||
SugarRushSymbolBetRatio = []*structs.SugarRushSymbolBetRatio{}
|
|
||||||
SugarRushSymbol = map[int64]*structs.SugarRushSymbol{}
|
|
||||||
TestBetBetChangeList = map[int64]*structs.TestBetBetChangeList{}
|
TestBetBetChangeList = map[int64]*structs.TestBetBetChangeList{}
|
||||||
TestBetBetLevel = map[int64]*structs.TestBetBetLevel{}
|
TestBetBetLevel = map[int64]*structs.TestBetBetLevel{}
|
||||||
TestBetBetLine = map[int64]*structs.TestBetBetLine{}
|
TestBetBetLine = map[int64]*structs.TestBetBetLine{}
|
||||||
|
|
|
||||||
|
|
@ -309,28 +309,6 @@ func StoragesLoading(data map[string]string) {
|
||||||
Load(data, "Base.PrizeModel/PrizeModelTypeB.Default", &base.PrizeModelPrizeModelTypeB)
|
Load(data, "Base.PrizeModel/PrizeModelTypeB.Default", &base.PrizeModelPrizeModelTypeB)
|
||||||
Load(data, "Base.Simulator.FSMultiLevel", &base.SimulatorFSMultiLevel)
|
Load(data, "Base.Simulator.FSMultiLevel", &base.SimulatorFSMultiLevel)
|
||||||
Load(data, "Base.Simulator.MultiLevel", &base.SimulatorMultiLevel)
|
Load(data, "Base.Simulator.MultiLevel", &base.SimulatorMultiLevel)
|
||||||
Load(data, "Base.SugarRush/BaseSymbolShow.Weight", &base.SugarRushBaseSymbolShowWeight)
|
|
||||||
Load(data, "Base.SugarRush/BaseSymbolShowNumber.Weight", &base.SugarRushBaseSymbolShowNumberWeight)
|
|
||||||
Load(data, "Base.SugarRush/Bet.BetChangeList", &base.SugarRushBetBetChangeList)
|
|
||||||
Load(data, "Base.SugarRush/Bet.BetLevel", &base.SugarRushBetBetLevel)
|
|
||||||
Load(data, "Base.SugarRush/Bet.BetLine", &base.SugarRushBetBetLine)
|
|
||||||
Load(data, "Base.SugarRush/Bet.BetSize", &base.SugarRushBetBetSize)
|
|
||||||
Load(data, "Base.SugarRush/Bet.FirstBet", &base.SugarRushBetFirstBet)
|
|
||||||
Load(data, "Base.SugarRush/BuyFreeScatterShow.Weight", &base.SugarRushBuyFreeScatterShowWeight)
|
|
||||||
Load(data, "Base.SugarRush/Formation.Default", &base.SugarRushFormation)
|
|
||||||
Load(data, "Base.SugarRush/FreeSymbolShow.Weight", &base.SugarRushFreeSymbolShowWeight)
|
|
||||||
Load(data, "Base.SugarRush/FreeSymbolShowNumber.Weight", &base.SugarRushFreeSymbolShowNumberWeight)
|
|
||||||
Load(data, "Base.SugarRush/Multiplier.Default", &base.SugarRushMultiplier)
|
|
||||||
Load(data, "Base.SugarRush/Others.Default", &base.SugarRushOthers)
|
|
||||||
Load(data, "Base.SugarRush/ReelBaseSpin.Range", &base.SugarRushReelBaseSpinRange)
|
|
||||||
Load(data, "Base.SugarRush/ReelBaseSpin.Reel", &base.SugarRushReelBaseSpinReel)
|
|
||||||
Load(data, "Base.SugarRush/ReelBaseSpin.Weight", &base.SugarRushReelBaseSpinWeight)
|
|
||||||
Load(data, "Base.SugarRush/ReelFreeSpin.Range", &base.SugarRushReelFreeSpinRange)
|
|
||||||
Load(data, "Base.SugarRush/ReelFreeSpin.Reel", &base.SugarRushReelFreeSpinReel)
|
|
||||||
Load(data, "Base.SugarRush/ReelFreeSpin.Weight", &base.SugarRushReelFreeSpinWeight)
|
|
||||||
Load(data, "Base.SugarRush/Scatter.Default", &base.SugarRushScatter)
|
|
||||||
Load(data, "Base.SugarRush/Symbol.BetRatio", &base.SugarRushSymbolBetRatio)
|
|
||||||
Load(data, "Base.SugarRush/Symbol.Default", &base.SugarRushSymbol)
|
|
||||||
Load(data, "Base.Test/Bet.BetChangeList", &base.TestBetBetChangeList)
|
Load(data, "Base.Test/Bet.BetChangeList", &base.TestBetBetChangeList)
|
||||||
Load(data, "Base.Test/Bet.BetLevel", &base.TestBetBetLevel)
|
Load(data, "Base.Test/Bet.BetLevel", &base.TestBetBetLevel)
|
||||||
Load(data, "Base.Test/Bet.BetLine", &base.TestBetBetLine)
|
Load(data, "Base.Test/Bet.BetLine", &base.TestBetBetLine)
|
||||||
|
|
@ -593,28 +571,6 @@ func StoragesMapping() {
|
||||||
Set("Base", "PrizeModel/PrizeModelTypeB", "Default", base.PrizeModelPrizeModelTypeB)
|
Set("Base", "PrizeModel/PrizeModelTypeB", "Default", base.PrizeModelPrizeModelTypeB)
|
||||||
Set("Base", "Simulator", "FSMultiLevel", base.SimulatorFSMultiLevel)
|
Set("Base", "Simulator", "FSMultiLevel", base.SimulatorFSMultiLevel)
|
||||||
Set("Base", "Simulator", "MultiLevel", base.SimulatorMultiLevel)
|
Set("Base", "Simulator", "MultiLevel", base.SimulatorMultiLevel)
|
||||||
Set("Base", "SugarRush/BaseSymbolShow", "Weight", base.SugarRushBaseSymbolShowWeight)
|
|
||||||
Set("Base", "SugarRush/BaseSymbolShowNumber", "Weight", base.SugarRushBaseSymbolShowNumberWeight)
|
|
||||||
Set("Base", "SugarRush/Bet", "BetChangeList", base.SugarRushBetBetChangeList)
|
|
||||||
Set("Base", "SugarRush/Bet", "BetLevel", base.SugarRushBetBetLevel)
|
|
||||||
Set("Base", "SugarRush/Bet", "BetLine", base.SugarRushBetBetLine)
|
|
||||||
Set("Base", "SugarRush/Bet", "BetSize", base.SugarRushBetBetSize)
|
|
||||||
Set("Base", "SugarRush/Bet", "FirstBet", base.SugarRushBetFirstBet)
|
|
||||||
Set("Base", "SugarRush/BuyFreeScatterShow", "Weight", base.SugarRushBuyFreeScatterShowWeight)
|
|
||||||
Set("Base", "SugarRush/Formation", "Default", base.SugarRushFormation)
|
|
||||||
Set("Base", "SugarRush/FreeSymbolShow", "Weight", base.SugarRushFreeSymbolShowWeight)
|
|
||||||
Set("Base", "SugarRush/FreeSymbolShowNumber", "Weight", base.SugarRushFreeSymbolShowNumberWeight)
|
|
||||||
Set("Base", "SugarRush/Multiplier", "Default", base.SugarRushMultiplier)
|
|
||||||
Set("Base", "SugarRush/Others", "Default", base.SugarRushOthers)
|
|
||||||
Set("Base", "SugarRush/ReelBaseSpin", "Range", base.SugarRushReelBaseSpinRange)
|
|
||||||
Set("Base", "SugarRush/ReelBaseSpin", "Reel", base.SugarRushReelBaseSpinReel)
|
|
||||||
Set("Base", "SugarRush/ReelBaseSpin", "Weight", base.SugarRushReelBaseSpinWeight)
|
|
||||||
Set("Base", "SugarRush/ReelFreeSpin", "Range", base.SugarRushReelFreeSpinRange)
|
|
||||||
Set("Base", "SugarRush/ReelFreeSpin", "Reel", base.SugarRushReelFreeSpinReel)
|
|
||||||
Set("Base", "SugarRush/ReelFreeSpin", "Weight", base.SugarRushReelFreeSpinWeight)
|
|
||||||
Set("Base", "SugarRush/Scatter", "Default", base.SugarRushScatter)
|
|
||||||
Set("Base", "SugarRush/Symbol", "BetRatio", base.SugarRushSymbolBetRatio)
|
|
||||||
Set("Base", "SugarRush/Symbol", "Default", base.SugarRushSymbol)
|
|
||||||
Set("Base", "Test/Bet", "BetChangeList", base.TestBetBetChangeList)
|
Set("Base", "Test/Bet", "BetChangeList", base.TestBetBetChangeList)
|
||||||
Set("Base", "Test/Bet", "BetLevel", base.TestBetBetLevel)
|
Set("Base", "Test/Bet", "BetLevel", base.TestBetBetLevel)
|
||||||
Set("Base", "Test/Bet", "BetLine", base.TestBetBetLine)
|
Set("Base", "Test/Bet", "BetLine", base.TestBetBetLine)
|
||||||
|
|
@ -670,11 +626,6 @@ func LinksMapping() {
|
||||||
Link("GatesOfOlympus/ReelBaseSpin1", "Weight/1", "GatesOfOlympus/ReelBaseSpin1", "Weight")
|
Link("GatesOfOlympus/ReelBaseSpin1", "Weight/1", "GatesOfOlympus/ReelBaseSpin1", "Weight")
|
||||||
Link("GatesOfOlympus/ReelBaseSpin1", "Weight/2", "GatesOfOlympus/ReelBaseSpin1", "Weight")
|
Link("GatesOfOlympus/ReelBaseSpin1", "Weight/2", "GatesOfOlympus/ReelBaseSpin1", "Weight")
|
||||||
Link("GatesOfOlympus/ReelBaseSpin1", "Weight/3", "GatesOfOlympus/ReelBaseSpin1", "Weight")
|
Link("GatesOfOlympus/ReelBaseSpin1", "Weight/3", "GatesOfOlympus/ReelBaseSpin1", "Weight")
|
||||||
Link("SugarRush/MatrixMatchForm7X7TypeA", "Default", "Matrix/MatchForm7X7TypeA", "Default")
|
|
||||||
Link("SugarRush/PrizeModel", "Default", "PrizeModel/PrizeModelTypeB", "Default")
|
|
||||||
Link("SugarRush/ReelBaseSpin", "Weight/1", "SugarRush/ReelBaseSpin", "Weight")
|
|
||||||
Link("SugarRush/ReelBaseSpin", "Weight/2", "SugarRush/ReelBaseSpin", "Weight")
|
|
||||||
Link("SugarRush/ReelBaseSpin", "Weight/3", "SugarRush/ReelBaseSpin", "Weight")
|
|
||||||
Link("Test/MatrixLine1Form3X3TypeA", "Default", "Matrix/Line1Form3X3TypeA", "Default")
|
Link("Test/MatrixLine1Form3X3TypeA", "Default", "Matrix/Line1Form3X3TypeA", "Default")
|
||||||
Link("Test/PrizeModel", "Default", "PrizeModel/PrizeModelTypeB", "Default")
|
Link("Test/PrizeModel", "Default", "PrizeModel/PrizeModelTypeB", "Default")
|
||||||
Link("Test/ReelBaseSpin", "Weight/1", "Test/ReelBaseSpin", "Weight")
|
Link("Test/ReelBaseSpin", "Weight/1", "Test/ReelBaseSpin", "Weight")
|
||||||
|
|
|
||||||
|
|
@ -261,32 +261,6 @@ type (
|
||||||
Min int64
|
Min int64
|
||||||
Max int64
|
Max int64
|
||||||
}
|
}
|
||||||
// SugarRushBaseSymbolShowNumberWeight comment
|
|
||||||
SugarRushBaseSymbolShowNumberWeight struct {
|
|
||||||
ID int64
|
|
||||||
ItemID int64
|
|
||||||
ShowNumberWeight []float64
|
|
||||||
}
|
|
||||||
// SugarRushBuyFreeScatterShowWeight comment
|
|
||||||
SugarRushBuyFreeScatterShowWeight struct {
|
|
||||||
ID int64
|
|
||||||
ScatterCount int64
|
|
||||||
Weight float64
|
|
||||||
}
|
|
||||||
// SugarRushMultiplier comment
|
|
||||||
SugarRushMultiplier struct {
|
|
||||||
ID int64
|
|
||||||
MatchTimes int64
|
|
||||||
Activate int64
|
|
||||||
Multiple int64
|
|
||||||
}
|
|
||||||
// SugarRushOthers comment
|
|
||||||
SugarRushOthers struct {
|
|
||||||
MaxScatterPerCol int64
|
|
||||||
BuyFreeTotalBetMultiplier int64
|
|
||||||
FallWeightMultiplier int64
|
|
||||||
FreespinMaxWin int64
|
|
||||||
}
|
|
||||||
// SuperStackWeight comment
|
// SuperStackWeight comment
|
||||||
SuperStackWeight struct {
|
SuperStackWeight struct {
|
||||||
ID int64
|
ID int64
|
||||||
|
|
@ -860,42 +834,6 @@ type (
|
||||||
// SimulatorMultiLevel comment
|
// SimulatorMultiLevel comment
|
||||||
SimulatorMultiLevel = SimulatorFSMultiLevel
|
SimulatorMultiLevel = SimulatorFSMultiLevel
|
||||||
|
|
||||||
// SugarRushBaseSymbolShowWeight comment
|
|
||||||
SugarRushBaseSymbolShowWeight = SuperStackWeight
|
|
||||||
|
|
||||||
// SugarRushBetBetChangeList comment
|
|
||||||
SugarRushBetBetChangeList = BetChangeList
|
|
||||||
|
|
||||||
// SugarRushBetBetLevel comment
|
|
||||||
SugarRushBetBetLevel = BetLevel
|
|
||||||
|
|
||||||
// SugarRushBetBetLine comment
|
|
||||||
SugarRushBetBetLine = BetLine
|
|
||||||
|
|
||||||
// SugarRushBetBetSize comment
|
|
||||||
SugarRushBetBetSize = BetSize
|
|
||||||
|
|
||||||
// SugarRushBetFirstBet comment
|
|
||||||
SugarRushBetFirstBet = FirstBet
|
|
||||||
|
|
||||||
// SugarRushFormation comment
|
|
||||||
SugarRushFormation = Formation
|
|
||||||
|
|
||||||
// SugarRushFreeSymbolShowNumberWeight comment
|
|
||||||
SugarRushFreeSymbolShowNumberWeight = SugarRushBaseSymbolShowNumberWeight
|
|
||||||
|
|
||||||
// SugarRushFreeSymbolShowWeight comment
|
|
||||||
SugarRushFreeSymbolShowWeight = SuperStackWeight
|
|
||||||
|
|
||||||
// SugarRushScatter comment
|
|
||||||
SugarRushScatter = Scatter
|
|
||||||
|
|
||||||
// SugarRushSymbol comment
|
|
||||||
SugarRushSymbol = Symbol
|
|
||||||
|
|
||||||
// SugarRushSymbolBetRatio comment
|
|
||||||
SugarRushSymbolBetRatio = SymbolBetRatio
|
|
||||||
|
|
||||||
// TestBetBetChangeList comment
|
// TestBetBetChangeList comment
|
||||||
TestBetBetChangeList = BetChangeList
|
TestBetBetChangeList = BetChangeList
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -8,21 +8,50 @@ const (
|
||||||
FortuneMouse = "FortuneMouse"
|
FortuneMouse = "FortuneMouse"
|
||||||
CashMania = "CashMania"
|
CashMania = "CashMania"
|
||||||
GatesOfOlympus = "GatesOfOlympus"
|
GatesOfOlympus = "GatesOfOlympus"
|
||||||
FortuneSnake = "FortuneSnake"
|
|
||||||
GaneshaGold = "GaneshaGold"
|
|
||||||
SugarRush = "SugarRush"
|
|
||||||
Test = "Test"
|
Test = "Test"
|
||||||
)
|
)
|
||||||
|
const (
|
||||||
|
GameId_Min uint = iota
|
||||||
|
GameId_Tiger
|
||||||
|
GameId_Dragon
|
||||||
|
GameId_Rabbit
|
||||||
|
GameId_OX
|
||||||
|
GameId_Mouse
|
||||||
|
GameId_Cash_Mania
|
||||||
|
GameId_GatesOfOlympus
|
||||||
|
|
||||||
var GameKeyMap = map[int64]string{
|
GameId_Max
|
||||||
308: FortuneTiger,
|
GameId_Test = 999
|
||||||
309: FortuneDragon,
|
)
|
||||||
310: FortuneRabbit,
|
|
||||||
311: FortuneOx,
|
var GameMap = map[uint]string{
|
||||||
312: FortuneMouse,
|
GameId_Tiger: FortuneTiger,
|
||||||
313: CashMania,
|
GameId_Dragon: FortuneDragon,
|
||||||
314: GatesOfOlympus,
|
GameId_Rabbit: FortuneRabbit,
|
||||||
315: FortuneSnake,
|
GameId_OX: FortuneOx,
|
||||||
316: GaneshaGold,
|
GameId_Mouse: FortuneMouse,
|
||||||
317: SugarRush,
|
GameId_Cash_Mania: CashMania,
|
||||||
|
GameId_GatesOfOlympus: GatesOfOlympus,
|
||||||
|
GameId_Test: Test,
|
||||||
|
}
|
||||||
|
var GameMapTheme = map[string]uint{
|
||||||
|
FortuneTiger: GameId_Tiger,
|
||||||
|
FortuneDragon: GameId_Dragon,
|
||||||
|
FortuneRabbit: GameId_Rabbit,
|
||||||
|
FortuneOx: GameId_OX,
|
||||||
|
FortuneMouse: GameId_Mouse,
|
||||||
|
CashMania: GameId_Cash_Mania,
|
||||||
|
GatesOfOlympus: GameId_GatesOfOlympus,
|
||||||
|
Test: GameId_Test,
|
||||||
|
}
|
||||||
|
var GameKeyMap = map[int64]uint{
|
||||||
|
0: GameId_Min,
|
||||||
|
308: GameId_Tiger,
|
||||||
|
309: GameId_Dragon,
|
||||||
|
310: GameId_Rabbit,
|
||||||
|
311: GameId_OX,
|
||||||
|
312: GameId_Mouse,
|
||||||
|
313: GameId_Cash_Mania,
|
||||||
|
314: GameId_GatesOfOlympus,
|
||||||
|
999: GameId_Max,
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -70,7 +70,6 @@ type (
|
||||||
FortuneMouse JSON
|
FortuneMouse JSON
|
||||||
CashMania JSON
|
CashMania JSON
|
||||||
GatesOfOlympus JSON
|
GatesOfOlympus JSON
|
||||||
SugarRush JSON
|
|
||||||
Test JSON
|
Test JSON
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -3,9 +3,7 @@ package formation
|
||||||
import (
|
import (
|
||||||
"github.com/tomas-qstarrs/boost/mathx"
|
"github.com/tomas-qstarrs/boost/mathx"
|
||||||
"mongo.games.com/game/gamesrv/slotspkg/internal/generic/errors"
|
"mongo.games.com/game/gamesrv/slotspkg/internal/generic/errors"
|
||||||
"mongo.games.com/game/gamesrv/slotspkg/internal/module/shared"
|
|
||||||
"mongo.games.com/game/gamesrv/slotspkg/slots/desc"
|
"mongo.games.com/game/gamesrv/slotspkg/slots/desc"
|
||||||
"mongo.games.com/game/gamesrv/slotspkg/slots/types/cli"
|
|
||||||
)
|
)
|
||||||
|
|
||||||
// SymbolWay is the symbols of same symbol id
|
// SymbolWay is the symbols of same symbol id
|
||||||
|
|
@ -18,7 +16,6 @@ type SymbolWay struct {
|
||||||
Pay float64 // Pay of this symbol way
|
Pay float64 // Pay of this symbol way
|
||||||
LinkPositions []int64 // Link result
|
LinkPositions []int64 // Link result
|
||||||
LinkDirection int64 // Link direction for this Symbol way
|
LinkDirection int64 // Link direction for this Symbol way
|
||||||
Times int64 //n ways
|
|
||||||
}
|
}
|
||||||
|
|
||||||
// GenerateSymbolWays genertates all symbols ways and sum pays and links
|
// GenerateSymbolWays genertates all symbols ways and sum pays and links
|
||||||
|
|
@ -39,14 +36,6 @@ func (f *Formation) GenerateSymbolWays() {
|
||||||
f.Pay += float64(symbolway.Pay)
|
f.Pay += float64(symbolway.Pay)
|
||||||
f.LinePays = append(f.LinePays, float64(symbolway.Pay))
|
f.LinePays = append(f.LinePays, float64(symbolway.Pay))
|
||||||
f.addSymbolPay(symbolway.Symbol, symbolway.LinkCount, float64(symbolway.Pay))
|
f.addSymbolPay(symbolway.Symbol, symbolway.LinkCount, float64(symbolway.Pay))
|
||||||
|
|
||||||
f.RewardInfo = append(f.RewardInfo, &shared.RewardInfo{
|
|
||||||
Type: 2,
|
|
||||||
Index: int(symbolway.Times),
|
|
||||||
Item: symbolway.Symbol,
|
|
||||||
Reward: symbolway.Pay,
|
|
||||||
Pos: cli.ToPoss(f.MatrixForm, symbolway.LinkPositions),
|
|
||||||
})
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
@ -81,9 +70,9 @@ func (s *SymbolWay) Win() bool {
|
||||||
return s.Pay > 0
|
return s.Pay > 0
|
||||||
}
|
}
|
||||||
|
|
||||||
func (s *SymbolWay) pay(colCounts []int64) (float64, int64, int64) {
|
func (s *SymbolWay) pay(colCounts []int64) (float64, int64) {
|
||||||
if colCounts[0] == 0 {
|
if colCounts[0] == 0 {
|
||||||
return 0, 0, 0
|
return 0, 0
|
||||||
}
|
}
|
||||||
symbolDesc, ok := s.SymbolsDesc[s.Symbol]
|
symbolDesc, ok := s.SymbolsDesc[s.Symbol]
|
||||||
if !ok {
|
if !ok {
|
||||||
|
|
@ -101,7 +90,7 @@ func (s *SymbolWay) pay(colCounts []int64) (float64, int64, int64) {
|
||||||
if linkCount > int64(len(symbolDesc.PayRate)) {
|
if linkCount > int64(len(symbolDesc.PayRate)) {
|
||||||
panic(errors.Errorf("link %d pay is not found", linkCount))
|
panic(errors.Errorf("link %d pay is not found", linkCount))
|
||||||
}
|
}
|
||||||
return symbolDesc.Ratio(times * symbolDesc.PayRate[linkCount-1]), linkCount, times
|
return symbolDesc.Ratio(times * symbolDesc.PayRate[linkCount-1]), linkCount
|
||||||
}
|
}
|
||||||
|
|
||||||
func (s *SymbolWay) getSymbolDesc(symbol int64) *desc.SymbolDesc {
|
func (s *SymbolWay) getSymbolDesc(symbol int64) *desc.SymbolDesc {
|
||||||
|
|
@ -180,7 +169,7 @@ func (s *SymbolWay) calculatePayFromLeftToRight(positions []int64, allPositions
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
s.Pay, s.LinkCount, s.Times = s.pay(colCounts)
|
s.Pay, s.LinkCount = s.pay(colCounts)
|
||||||
|
|
||||||
var hasSymbol bool
|
var hasSymbol bool
|
||||||
for index := 0; index < len(positions); index++ {
|
for index := 0; index < len(positions); index++ {
|
||||||
|
|
@ -196,7 +185,6 @@ func (s *SymbolWay) calculatePayFromLeftToRight(positions []int64, allPositions
|
||||||
if !hasSymbol {
|
if !hasSymbol {
|
||||||
s.LinkPositions = nil
|
s.LinkPositions = nil
|
||||||
s.Pay = 0
|
s.Pay = 0
|
||||||
s.Times = 0
|
|
||||||
s.LinkCount = 0
|
s.LinkCount = 0
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
@ -221,7 +209,7 @@ func (s *SymbolWay) calculatePayFromRightToLeft(positions []int64, allPositions
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
s.Pay, s.LinkCount, s.Times = s.pay(colCounts)
|
s.Pay, s.LinkCount = s.pay(colCounts)
|
||||||
|
|
||||||
colCounts = make([]int64, len(s.MatrixDesc.Form))
|
colCounts = make([]int64, len(s.MatrixDesc.Form))
|
||||||
end = int64(len(positions) - 1)
|
end = int64(len(positions) - 1)
|
||||||
|
|
@ -247,7 +235,6 @@ func (s *SymbolWay) calculatePayFromRightToLeft(positions []int64, allPositions
|
||||||
if sumColCount == 0 {
|
if sumColCount == 0 {
|
||||||
s.LinkPositions = nil
|
s.LinkPositions = nil
|
||||||
s.Pay = 0
|
s.Pay = 0
|
||||||
s.Times = 0
|
|
||||||
s.LinkCount = 0
|
s.LinkCount = 0
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -13,9 +13,8 @@ import (
|
||||||
)
|
)
|
||||||
|
|
||||||
func (sm *SlotsMgr) Enter(s *base.SlotsSession, gameId int64) (*cli.SlotsEnterResponse, error) {
|
func (sm *SlotsMgr) Enter(s *base.SlotsSession, gameId int64) (*cli.SlotsEnterResponse, error) {
|
||||||
var theme string
|
if gid, ok := key.GameKeyMap[gameId]; ok {
|
||||||
if tm, ok := key.GameKeyMap[gameId]; ok {
|
gameId = int64(gid)
|
||||||
theme = tm
|
|
||||||
} else {
|
} else {
|
||||||
logger.Logger.Error("[slotsMgr.Enter] gameId not exist")
|
logger.Logger.Error("[slotsMgr.Enter] gameId not exist")
|
||||||
return nil, errors.New("gameId not exist")
|
return nil, errors.New("gameId not exist")
|
||||||
|
|
@ -25,6 +24,8 @@ func (sm *SlotsMgr) Enter(s *base.SlotsSession, gameId int64) (*cli.SlotsEnterRe
|
||||||
|
|
||||||
player.Init(s)
|
player.Init(s)
|
||||||
|
|
||||||
|
theme := key.GameMap[uint(gameId)]
|
||||||
|
|
||||||
m := machine.NewMachine(s, theme, DataSet(s).Shell, false)
|
m := machine.NewMachine(s, theme, DataSet(s).Shell, false)
|
||||||
if m == nil {
|
if m == nil {
|
||||||
logger.Logger.Error("[slotsMgr.enter] module is nil")
|
logger.Logger.Error("[slotsMgr.enter] module is nil")
|
||||||
|
|
@ -55,9 +56,8 @@ func (sm *SlotsMgr) Enter(s *base.SlotsSession, gameId int64) (*cli.SlotsEnterRe
|
||||||
}
|
}
|
||||||
|
|
||||||
func (sm *SlotsMgr) Play(s *base.SlotsSession, req *base.SpinReq) (*cli.SlotsPlayResponse, error) {
|
func (sm *SlotsMgr) Play(s *base.SlotsSession, req *base.SpinReq) (*cli.SlotsPlayResponse, error) {
|
||||||
var theme string
|
if gameId, ok := key.GameKeyMap[req.GameId]; ok {
|
||||||
if tm, ok := key.GameKeyMap[req.GameId]; ok {
|
req.GameId = int64(gameId)
|
||||||
theme = tm
|
|
||||||
} else {
|
} else {
|
||||||
logger.Logger.Error("[slotsMgr.play] gameId not exist")
|
logger.Logger.Error("[slotsMgr.play] gameId not exist")
|
||||||
return nil, errors.New("gameId not exist")
|
return nil, errors.New("gameId not exist")
|
||||||
|
|
@ -80,6 +80,7 @@ func (sm *SlotsMgr) Play(s *base.SlotsSession, req *base.SpinReq) (*cli.SlotsPla
|
||||||
|
|
||||||
player.Get(s).Book.Coin.Set(s.Coin())
|
player.Get(s).Book.Coin.Set(s.Coin())
|
||||||
|
|
||||||
|
theme := key.GameMap[uint(req.GameId)]
|
||||||
m := machine.NewMachine(s, theme, DataSet(s).Shell, false)
|
m := machine.NewMachine(s, theme, DataSet(s).Shell, false)
|
||||||
if m == nil {
|
if m == nil {
|
||||||
logger.Logger.Error("[slotsMgr.play] module is nil")
|
logger.Logger.Error("[slotsMgr.play] module is nil")
|
||||||
|
|
@ -161,9 +162,3 @@ func (*SlotsMgr) Leave(s *base.SlotsSession) (*cli.SlotsLeaveResponse, error) {
|
||||||
}
|
}
|
||||||
return Response, nil
|
return Response, nil
|
||||||
}
|
}
|
||||||
|
|
||||||
// pp
|
|
||||||
func (sm *SlotsMgr) PPGetBetIndex(s *base.SlotsSession, theme string, val float64) []int64 {
|
|
||||||
m := machine.NewMachine(s, theme, DataSet(s).Shell, false)
|
|
||||||
return m.GetBetIndexByVal(val)
|
|
||||||
}
|
|
||||||
|
|
|
||||||
|
|
@ -120,7 +120,7 @@ func (m *Machine) SyncLiteClose() *shared.LiteNodeTree {
|
||||||
// PlayLiteClose serialize the machine and transform into lite node tree for play
|
// PlayLiteClose serialize the machine and transform into lite node tree for play
|
||||||
func (m *Machine) PlayLiteClose() *shared.LiteNodeTree {
|
func (m *Machine) PlayLiteClose() *shared.LiteNodeTree {
|
||||||
m.Serialize()
|
m.Serialize()
|
||||||
//m.Session.Remove(key.SessionMachine)
|
m.Session.Remove(key.SessionMachine)
|
||||||
|
|
||||||
liteNodeTree := &shared.LiteNodeTree{
|
liteNodeTree := &shared.LiteNodeTree{
|
||||||
Step: m.NodeTree.Step,
|
Step: m.NodeTree.Step,
|
||||||
|
|
|
||||||
|
|
@ -9,7 +9,6 @@ import (
|
||||||
"mongo.games.com/game/gamesrv/slotspkg/slots/plugin/fortunerabbit"
|
"mongo.games.com/game/gamesrv/slotspkg/slots/plugin/fortunerabbit"
|
||||||
"mongo.games.com/game/gamesrv/slotspkg/slots/plugin/fortunetiger"
|
"mongo.games.com/game/gamesrv/slotspkg/slots/plugin/fortunetiger"
|
||||||
"mongo.games.com/game/gamesrv/slotspkg/slots/plugin/gatesofolympus"
|
"mongo.games.com/game/gamesrv/slotspkg/slots/plugin/gatesofolympus"
|
||||||
"mongo.games.com/game/gamesrv/slotspkg/slots/plugin/sugarrush"
|
|
||||||
"mongo.games.com/game/gamesrv/slotspkg/slots/plugin/test"
|
"mongo.games.com/game/gamesrv/slotspkg/slots/plugin/test"
|
||||||
"mongo.games.com/game/gamesrv/slotspkg/slots/reg"
|
"mongo.games.com/game/gamesrv/slotspkg/slots/reg"
|
||||||
)
|
)
|
||||||
|
|
@ -23,7 +22,6 @@ func Init() {
|
||||||
reg.Register(fortunemouse.Plugins...)
|
reg.Register(fortunemouse.Plugins...)
|
||||||
reg.Register(cashmania.Plugins...)
|
reg.Register(cashmania.Plugins...)
|
||||||
reg.Register(gatesofolympus.Plugins...)
|
reg.Register(gatesofolympus.Plugins...)
|
||||||
reg.Register(sugarrush.Plugins...)
|
|
||||||
reg.Register(test.Plugins...)
|
reg.Register(test.Plugins...)
|
||||||
|
|
||||||
if global.Mock {
|
if global.Mock {
|
||||||
|
|
@ -33,7 +31,6 @@ func Init() {
|
||||||
reg.Register(fortunedragon.SimulatorPlugins...)
|
reg.Register(fortunedragon.SimulatorPlugins...)
|
||||||
reg.Register(cashmania.SimulatorPlugins...)
|
reg.Register(cashmania.SimulatorPlugins...)
|
||||||
reg.Register(gatesofolympus.SimulatorPlugins...)
|
reg.Register(gatesofolympus.SimulatorPlugins...)
|
||||||
reg.Register(sugarrush.SimulatorPlugins...)
|
|
||||||
reg.Register(test.SimulatorPlugins...)
|
reg.Register(test.SimulatorPlugins...)
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
@ -47,7 +44,6 @@ func Close() {
|
||||||
reg.Deregister(fortunemouse.Plugins...)
|
reg.Deregister(fortunemouse.Plugins...)
|
||||||
reg.Deregister(cashmania.Plugins...)
|
reg.Deregister(cashmania.Plugins...)
|
||||||
reg.Deregister(gatesofolympus.Plugins...)
|
reg.Deregister(gatesofolympus.Plugins...)
|
||||||
reg.Deregister(sugarrush.Plugins...)
|
|
||||||
reg.Deregister(test.Plugins...)
|
reg.Deregister(test.Plugins...)
|
||||||
if global.Mock {
|
if global.Mock {
|
||||||
reg.Deregister(fortuneox.SimulatorPlugins...)
|
reg.Deregister(fortuneox.SimulatorPlugins...)
|
||||||
|
|
@ -56,7 +52,6 @@ func Close() {
|
||||||
reg.Deregister(fortunedragon.SimulatorPlugins...)
|
reg.Deregister(fortunedragon.SimulatorPlugins...)
|
||||||
reg.Deregister(cashmania.SimulatorPlugins...)
|
reg.Deregister(cashmania.SimulatorPlugins...)
|
||||||
reg.Deregister(gatesofolympus.SimulatorPlugins...)
|
reg.Deregister(gatesofolympus.SimulatorPlugins...)
|
||||||
reg.Deregister(sugarrush.SimulatorPlugins...)
|
|
||||||
reg.Deregister(test.SimulatorPlugins...)
|
reg.Deregister(test.SimulatorPlugins...)
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -1,419 +0,0 @@
|
||||||
package sugarrush
|
|
||||||
|
|
||||||
import (
|
|
||||||
"github.com/tomas-qstarrs/boost/mathx"
|
|
||||||
"github.com/tomas-qstarrs/boost/randx"
|
|
||||||
"mongo.games.com/game/gamesrv/slotspkg/internal/generic/key"
|
|
||||||
"mongo.games.com/game/gamesrv/slotspkg/internal/module/shared"
|
|
||||||
"mongo.games.com/game/gamesrv/slotspkg/slots/intf"
|
|
||||||
"mongo.games.com/game/gamesrv/slotspkg/slots/plugin/generic"
|
|
||||||
)
|
|
||||||
|
|
||||||
// PluginBaseSpin is derived from generic.PluginBase
|
|
||||||
type PluginBaseSpin struct {
|
|
||||||
generic.PluginBase
|
|
||||||
}
|
|
||||||
|
|
||||||
// Theme implements generic.PluginBase.Theme
|
|
||||||
func (p *PluginBaseSpin) Theme() string {
|
|
||||||
return key.SugarRush
|
|
||||||
}
|
|
||||||
|
|
||||||
type CustomEliminate struct {
|
|
||||||
LinkPositions []*shared.LinkPositions
|
|
||||||
AppendSymbols [][]int64
|
|
||||||
FormattedSymbols [][]int64
|
|
||||||
LinePays []float64
|
|
||||||
LineMultis []int64
|
|
||||||
WinCoins []int64
|
|
||||||
MaxWin bool
|
|
||||||
}
|
|
||||||
|
|
||||||
type CustomPay struct {
|
|
||||||
Pay int64
|
|
||||||
}
|
|
||||||
|
|
||||||
type CustomMulti struct {
|
|
||||||
MultiTable [][]int64
|
|
||||||
}
|
|
||||||
|
|
||||||
type Col struct {
|
|
||||||
Values []int64
|
|
||||||
}
|
|
||||||
|
|
||||||
type Formation struct {
|
|
||||||
Cols []Col
|
|
||||||
}
|
|
||||||
|
|
||||||
// Customs implements generic.PluginBase.Customs
|
|
||||||
func (p *PluginBaseSpin) Customs() []interface{} {
|
|
||||||
return []interface{}{
|
|
||||||
&CustomPay{},
|
|
||||||
&CustomEliminate{},
|
|
||||||
&MultiTable{},
|
|
||||||
&CustomMulti{},
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
// AfterBaseSpin is called after base spin
|
|
||||||
func (p *PluginBaseSpin) AfterBaseSpin(m intf.Master) {
|
|
||||||
|
|
||||||
}
|
|
||||||
|
|
||||||
func (f *Formation) AddFreeSpin(m intf.Master) {
|
|
||||||
if m.Cursor().GetType() != key.BaseSpin {
|
|
||||||
return
|
|
||||||
}
|
|
||||||
scatterCount := Descx(m).RandScatterCount()
|
|
||||||
// get current count
|
|
||||||
currentCount := int64(0)
|
|
||||||
for _, col := range f.Cols {
|
|
||||||
for _, v := range col.Values {
|
|
||||||
if v == SymbolScatter {
|
|
||||||
currentCount++
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
// get col not has scatter
|
|
||||||
colNotHasScatter := make([]int64, 0)
|
|
||||||
for i, col := range f.Cols {
|
|
||||||
hasScatter := false
|
|
||||||
for _, v := range col.Values {
|
|
||||||
if v == SymbolScatter {
|
|
||||||
hasScatter = true
|
|
||||||
break
|
|
||||||
}
|
|
||||||
}
|
|
||||||
if !hasScatter {
|
|
||||||
colNotHasScatter = append(colNotHasScatter, int64(i))
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
needCount := scatterCount - currentCount
|
|
||||||
if needCount <= 0 {
|
|
||||||
needCount = 0
|
|
||||||
}
|
|
||||||
|
|
||||||
// rand new scatter for col not has scatter
|
|
||||||
randx.RandShuffle(m.Randx(), colNotHasScatter)
|
|
||||||
for i := int64(0); i < needCount; i++ {
|
|
||||||
col := colNotHasScatter[i]
|
|
||||||
f.Cols[col].Values[randx.RandRangeInt63n(m.Randx(), 0, 6)] = SymbolScatter
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
func (f *Formation) fillCol(m intf.Master, col int64, eliminate bool, isFree bool) []int64 {
|
|
||||||
appendValues := make([]int64, 0)
|
|
||||||
values := f.Cols[col].Values
|
|
||||||
left := ReelHeight - int64(len(values))
|
|
||||||
scatterCount := int64(0)
|
|
||||||
for _, v := range values {
|
|
||||||
if v == SymbolScatter {
|
|
||||||
scatterCount++
|
|
||||||
break
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
topItemID := int64(0)
|
|
||||||
isTop := false
|
|
||||||
if len(values) > 0 && eliminate {
|
|
||||||
topItemID = values[0]
|
|
||||||
isTop = true
|
|
||||||
}
|
|
||||||
|
|
||||||
for left > 0 {
|
|
||||||
itemID := Descx(m).RandItemID(topItemID, isFree, isTop)
|
|
||||||
if isTop {
|
|
||||||
isTop = false
|
|
||||||
}
|
|
||||||
topItemID = itemID
|
|
||||||
|
|
||||||
itemCount := Descx(m).RandItemCount(itemID, left, isFree)
|
|
||||||
if SymbolScatter == itemID {
|
|
||||||
itemCount = mathx.Min(itemCount, Descx(m).GetOtherConfig().MaxScatterPerCol-scatterCount)
|
|
||||||
}
|
|
||||||
|
|
||||||
if SymbolScatter == itemID {
|
|
||||||
scatterCount += itemCount
|
|
||||||
}
|
|
||||||
|
|
||||||
for i := int64(0); i < itemCount; i++ {
|
|
||||||
// append at head
|
|
||||||
values = append([]int64{itemID}, values...)
|
|
||||||
appendValues = append([]int64{itemID}, appendValues...)
|
|
||||||
}
|
|
||||||
|
|
||||||
left -= itemCount
|
|
||||||
}
|
|
||||||
f.Cols[col].Values = values
|
|
||||||
return appendValues
|
|
||||||
}
|
|
||||||
|
|
||||||
func (f *Formation) fillCols(m intf.Master, eliminate bool, isFree bool) [][]int64 {
|
|
||||||
newSymbols := make([][]int64, ReelWidth)
|
|
||||||
for j := int64(0); j < ReelWidth; j++ {
|
|
||||||
newSymbols[j] = f.fillCol(m, j, eliminate, isFree)
|
|
||||||
}
|
|
||||||
return newSymbols
|
|
||||||
}
|
|
||||||
|
|
||||||
func (f *Formation) GetValues() [][]int64 {
|
|
||||||
values := make([][]int64, ReelHeight)
|
|
||||||
for j := int64(0); j < ReelWidth; j++ {
|
|
||||||
for i := int64(0); i < ReelHeight; i++ {
|
|
||||||
values[j] = append(values[j], f.Cols[j].Values[i])
|
|
||||||
}
|
|
||||||
}
|
|
||||||
return values
|
|
||||||
}
|
|
||||||
|
|
||||||
func createFormation() *Formation {
|
|
||||||
formation := &Formation{}
|
|
||||||
for i := 0; i < 7; i++ {
|
|
||||||
formation.Cols = make([]Col, 7)
|
|
||||||
}
|
|
||||||
return formation
|
|
||||||
}
|
|
||||||
|
|
||||||
func (p *PluginBaseSpin) RandFormation(m intf.Master) [][]int64 {
|
|
||||||
formation := &Formation{
|
|
||||||
Cols: make([]Col, 7),
|
|
||||||
}
|
|
||||||
for i := 0; i < 7; i++ {
|
|
||||||
formation.Cols[i] = Col{
|
|
||||||
Values: make([]int64, 0),
|
|
||||||
}
|
|
||||||
formation.fillCol(m, int64(i), false, m.Cursor().GetType() == key.FreeSpin)
|
|
||||||
}
|
|
||||||
|
|
||||||
// 购买freespin
|
|
||||||
if m.Exists(key.MachineRoundType) && m.Value(key.MachineRoundType).(int64) == RoundTypeBuyFreeSpin {
|
|
||||||
formation.AddFreeSpin(m)
|
|
||||||
}
|
|
||||||
|
|
||||||
return formation.GetValues()
|
|
||||||
}
|
|
||||||
|
|
||||||
func DumpReel(symbols [][]int64) {
|
|
||||||
// str := ""
|
|
||||||
// for row := int64(0); row < 7; row++ {
|
|
||||||
// for col := int64(0); col < 7; col++ {
|
|
||||||
// str += fmt.Sprintf("%d ", symbols[col][row])
|
|
||||||
// }
|
|
||||||
// str += "\n"
|
|
||||||
// }
|
|
||||||
// log.Infof("reel: \n%s\n", str)
|
|
||||||
}
|
|
||||||
|
|
||||||
func IsPositionLinked(linkPositions []*shared.LinkPositions, row int64, col int64) bool {
|
|
||||||
for _, positions := range linkPositions {
|
|
||||||
for _, position := range positions.Positions {
|
|
||||||
if position == col*7+row {
|
|
||||||
return true
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
return false
|
|
||||||
}
|
|
||||||
|
|
||||||
type MultiTable struct {
|
|
||||||
Multi [][]int64
|
|
||||||
Count [][]int64
|
|
||||||
}
|
|
||||||
|
|
||||||
func (t *MultiTable) Clear() {
|
|
||||||
for i := 0; i < 7; i++ {
|
|
||||||
for j := 0; j < 7; j++ {
|
|
||||||
t.Multi[i][j] = 0
|
|
||||||
t.Count[i][j] = 0
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
func (t *MultiTable) Update(m intf.Master, linkPositions []*shared.LinkPositions) {
|
|
||||||
for _, positions := range linkPositions {
|
|
||||||
for _, position := range positions.Positions {
|
|
||||||
t.Count[position/7][position%7]++
|
|
||||||
}
|
|
||||||
}
|
|
||||||
// update multi
|
|
||||||
for i := 0; i < 7; i++ {
|
|
||||||
for j := 0; j < 7; j++ {
|
|
||||||
t.Multi[i][j] = Descx(m).GetMulti(t.Count[i][j])
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
func calcMulti(linkPositions *shared.LinkPositions, multiTable *MultiTable) int64 {
|
|
||||||
totalMulti := int64(0)
|
|
||||||
|
|
||||||
for _, p := range linkPositions.Positions {
|
|
||||||
if multiTable.Multi[p/7][p%7] > 1 {
|
|
||||||
totalMulti += multiTable.Multi[p/7][p%7]
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
if totalMulti < 1 {
|
|
||||||
totalMulti = 1
|
|
||||||
}
|
|
||||||
|
|
||||||
return totalMulti
|
|
||||||
}
|
|
||||||
|
|
||||||
func (p *PluginBaseSpin) Eliminate(m intf.Master, customPay *CustomPay, multiTable *MultiTable) bool {
|
|
||||||
cursorFormation := m.CursorFormation()
|
|
||||||
formattedSymbols := cursorFormation.GetReelFormattedSymbols()
|
|
||||||
DumpReel(formattedSymbols)
|
|
||||||
// 清空基础赢钱
|
|
||||||
cursorFormation.SetWin(0)
|
|
||||||
|
|
||||||
// 根据赔付计算multi type
|
|
||||||
linkPositions, _, linePays := m.TryLinkMatrixSymbols(1, formattedSymbols)
|
|
||||||
DumpReel(multiTable.Multi)
|
|
||||||
lineMultis := make([]int64, len(linePays))
|
|
||||||
|
|
||||||
symbols := cursorFormation.GetReelFormattedSymbols()
|
|
||||||
success := mathx.Sum(linePays) > 0
|
|
||||||
|
|
||||||
// erase
|
|
||||||
formation := createFormation()
|
|
||||||
for j := int64(0); j < 7; j++ {
|
|
||||||
for i := int64(0); i < 7; i++ {
|
|
||||||
if !IsPositionLinked(linkPositions, i, j) {
|
|
||||||
formation.Cols[j].Values = append(formation.Cols[j].Values, symbols[j][i])
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
appendFormattedSymbols := formation.fillCols(m, true, m.Cursor().GetType() == key.FreeSpin)
|
|
||||||
|
|
||||||
lineNum := len(linePays)
|
|
||||||
winCoins := make([]int64, lineNum)
|
|
||||||
totalPay := int64(0)
|
|
||||||
|
|
||||||
for lineIdx, pay := range linePays {
|
|
||||||
multi := calcMulti(linkPositions[lineIdx], multiTable)
|
|
||||||
lineMultis[lineIdx] = multi
|
|
||||||
winCoins[lineIdx] = int64(float64(m.Cursor().GetSingleBet()) * pay * float64(multi))
|
|
||||||
totalPay += winCoins[lineIdx]
|
|
||||||
}
|
|
||||||
|
|
||||||
isMaxWin := false
|
|
||||||
|
|
||||||
maxValue := Descx(m).GetOtherConfig().FreespinMaxWin * m.Cursor().GetBet()
|
|
||||||
currentWin := m.TotalWin() + customPay.Pay
|
|
||||||
|
|
||||||
// log.Infof("Eliminate totalPay: %d, currentWin: %d, maxValue: %d", totalPay, currentWin, maxValue)
|
|
||||||
|
|
||||||
if m.Cursor().GetType() == key.FreeSpin {
|
|
||||||
if currentWin+totalPay >= maxValue {
|
|
||||||
success = false
|
|
||||||
isMaxWin = true
|
|
||||||
totalPay = maxValue - currentWin
|
|
||||||
m.SetProgressLeft(0)
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
// 添加后续feature,这里是消除
|
|
||||||
m.AddCursorFeature(&CustomEliminate{
|
|
||||||
LinkPositions: linkPositions,
|
|
||||||
AppendSymbols: appendFormattedSymbols,
|
|
||||||
FormattedSymbols: formattedSymbols,
|
|
||||||
LinePays: linePays,
|
|
||||||
LineMultis: lineMultis,
|
|
||||||
WinCoins: winCoins,
|
|
||||||
MaxWin: isMaxWin,
|
|
||||||
}).SetLifetime(1)
|
|
||||||
|
|
||||||
DumpReel(formation.GetValues())
|
|
||||||
cursorFormation.SetFormattedSymbols(formation.GetValues())
|
|
||||||
|
|
||||||
// 累加pay
|
|
||||||
customPay.Pay += totalPay
|
|
||||||
multiTable.Update(m, linkPositions)
|
|
||||||
|
|
||||||
// add new
|
|
||||||
return success
|
|
||||||
}
|
|
||||||
|
|
||||||
func (p *PluginBaseSpin) BeforeSpin(m intf.Master) {
|
|
||||||
m.AddCursorFeature(&CustomPay{}).SetLifetime(1)
|
|
||||||
}
|
|
||||||
|
|
||||||
func (p *PluginBaseSpin) Spin(m intf.Master, isFree bool) {
|
|
||||||
// 生成轴
|
|
||||||
symbols := p.RandFormation(m)
|
|
||||||
DumpReel(symbols)
|
|
||||||
formation := m.CursorFormation()
|
|
||||||
formation.SetFormattedSymbols(symbols)
|
|
||||||
customPay := m.CursorCustom(&CustomPay{}).(*CustomPay)
|
|
||||||
|
|
||||||
table := getMultiTable(m)
|
|
||||||
|
|
||||||
// 存储 Formation元素
|
|
||||||
formation.SetFormattedDisplaySymbols(symbols)
|
|
||||||
|
|
||||||
// 消除
|
|
||||||
n := 0
|
|
||||||
for p.Eliminate(m, customPay, table) {
|
|
||||||
n++
|
|
||||||
if n > 1000 {
|
|
||||||
break
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
if customPay.Pay > 0 {
|
|
||||||
m.CursorFeature(&CustomPay{}).SetWin(customPay.Pay)
|
|
||||||
}
|
|
||||||
|
|
||||||
m.AddCursorFeature(&CustomMulti{
|
|
||||||
MultiTable: table.Multi,
|
|
||||||
}).SetLifetime(1)
|
|
||||||
|
|
||||||
formattedSymbols := formation.GetReelFormattedSymbols()
|
|
||||||
formation.SetFormattedFinalSymbols(formattedSymbols)
|
|
||||||
}
|
|
||||||
|
|
||||||
func (p *PluginBaseSpin) CheckFreeLimit(m intf.Master) {
|
|
||||||
|
|
||||||
}
|
|
||||||
|
|
||||||
// AfterSpin implements generic.PluginBase.AfterSpin
|
|
||||||
func (p *PluginBaseSpin) AfterSpin(m intf.Master) {
|
|
||||||
p.Spin(m, m.Cursor().GetType() == key.FreeSpin)
|
|
||||||
|
|
||||||
switch m.Cursor().GetType() {
|
|
||||||
case key.BaseSpin:
|
|
||||||
p.AfterBaseSpin(m)
|
|
||||||
case key.FreeSpin:
|
|
||||||
p.AfterFreeSpin(m)
|
|
||||||
p.CheckFreeLimit(m)
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
// AfterFreeSpin is called after free spin
|
|
||||||
func (p *PluginBaseSpin) AfterFreeSpin(m intf.Master) {
|
|
||||||
|
|
||||||
}
|
|
||||||
|
|
||||||
func (p *PluginBaseSpin) OnLeaveNode(m intf.Master) {
|
|
||||||
if m.Next().GetType() == key.FreeSpin || m.Next().GetType() == key.BaseSpin {
|
|
||||||
getMultiTable(m).Clear()
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
func getMultiTable(m intf.Master) *MultiTable {
|
|
||||||
if len(m.RootFeatures(&MultiTable{})) == 0 {
|
|
||||||
table := &MultiTable{
|
|
||||||
Multi: make([][]int64, 7),
|
|
||||||
Count: make([][]int64, 7),
|
|
||||||
}
|
|
||||||
for i := 0; i < 7; i++ {
|
|
||||||
table.Multi[i] = make([]int64, 7)
|
|
||||||
table.Count[i] = make([]int64, 7)
|
|
||||||
}
|
|
||||||
m.AddRootFeature(table)
|
|
||||||
}
|
|
||||||
return m.RootCustom(&MultiTable{}).(*MultiTable)
|
|
||||||
}
|
|
||||||
|
|
@ -1,31 +0,0 @@
|
||||||
package sugarrush
|
|
||||||
|
|
||||||
import (
|
|
||||||
"mongo.games.com/game/gamesrv/slotspkg/internal/generic/key"
|
|
||||||
"mongo.games.com/game/gamesrv/slotspkg/slots/intf"
|
|
||||||
"mongo.games.com/game/gamesrv/slotspkg/slots/plugin/generic"
|
|
||||||
)
|
|
||||||
|
|
||||||
type PluginChooseWheel struct {
|
|
||||||
generic.PluginBase
|
|
||||||
}
|
|
||||||
|
|
||||||
func (p *PluginChooseWheel) Theme() string {
|
|
||||||
return key.SugarRush
|
|
||||||
}
|
|
||||||
|
|
||||||
func (p *PluginChooseWheel) OnStepBegin(m intf.Master) {
|
|
||||||
isFreeSpin := m.Next().GetType() == key.FreeSpin
|
|
||||||
typ := m.Choice()
|
|
||||||
|
|
||||||
if !isFreeSpin {
|
|
||||||
if typ == RoundTypeBuyFreeSpin {
|
|
||||||
m.SetRatio(key.MachineRatioMoreCoinSameBet, 100)
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
// 设置日志中的RoundType
|
|
||||||
if m.Next().GetType() == key.BaseSpin {
|
|
||||||
m.Set(key.MachineRoundType, typ)
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
@ -1,12 +0,0 @@
|
||||||
package sugarrush
|
|
||||||
|
|
||||||
const (
|
|
||||||
ReelWidth = int64(7)
|
|
||||||
ReelHeight = int64(7)
|
|
||||||
SymbolScatter = int64(1)
|
|
||||||
)
|
|
||||||
const (
|
|
||||||
RoundTypeBaseSpin = iota
|
|
||||||
RoundTypeMoreScatter // 25% more cost
|
|
||||||
RoundTypeBuyFreeSpin // 10000% more cost
|
|
||||||
)
|
|
||||||
|
|
@ -1,165 +0,0 @@
|
||||||
package sugarrush
|
|
||||||
|
|
||||||
import (
|
|
||||||
"github.com/tomas-qstarrs/boost/randx"
|
|
||||||
"mongo.games.com/game/gamesrv/slotspkg/internal/exported/excel2go/structs"
|
|
||||||
"mongo.games.com/game/gamesrv/slotspkg/internal/generic/errors"
|
|
||||||
"mongo.games.com/game/gamesrv/slotspkg/slots/desc"
|
|
||||||
"mongo.games.com/game/gamesrv/slotspkg/slots/intf"
|
|
||||||
)
|
|
||||||
|
|
||||||
type descx struct {
|
|
||||||
*randx.Randx
|
|
||||||
*desc.NodeDesc
|
|
||||||
}
|
|
||||||
|
|
||||||
func Descx(m intf.Master) *descx {
|
|
||||||
return &descx{
|
|
||||||
Randx: m.Randx(),
|
|
||||||
NodeDesc: m.Desc(),
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
func (n descx) GetOtherConfig() *structs.SugarRushOthers {
|
|
||||||
v := n.DefaultSheet("Others")
|
|
||||||
|
|
||||||
values, ok := v.([]*structs.SugarRushOthers)
|
|
||||||
if !ok {
|
|
||||||
panic(errors.ConfigTypeError.Error())
|
|
||||||
}
|
|
||||||
return values[0]
|
|
||||||
}
|
|
||||||
|
|
||||||
func (n descx) GetMulti(count int64) int64 {
|
|
||||||
v := n.DefaultSheet("Multiplier")
|
|
||||||
values, ok := v.([]*structs.SugarRushMultiplier)
|
|
||||||
if !ok {
|
|
||||||
panic(errors.ConfigTypeError.Error())
|
|
||||||
}
|
|
||||||
for _, v := range values {
|
|
||||||
if v.MatchTimes == count {
|
|
||||||
return v.Multiple
|
|
||||||
}
|
|
||||||
}
|
|
||||||
// return last one
|
|
||||||
return values[len(values)-1].Multiple
|
|
||||||
}
|
|
||||||
|
|
||||||
func (n descx) RandScatterCount() int64 {
|
|
||||||
v := n.Sheet("BuyFreeScatterShow", "Weight")
|
|
||||||
|
|
||||||
values, ok := v.([]*structs.SugarRushBuyFreeScatterShowWeight)
|
|
||||||
if !ok {
|
|
||||||
panic(errors.ConfigTypeError.Error())
|
|
||||||
}
|
|
||||||
|
|
||||||
weights := make([]float64, 0)
|
|
||||||
for _, v := range values {
|
|
||||||
weights = append(weights, v.Weight)
|
|
||||||
}
|
|
||||||
index := randx.RandWeight(n.Randx, weights)
|
|
||||||
|
|
||||||
return values[index].ScatterCount
|
|
||||||
}
|
|
||||||
|
|
||||||
func (n descx) RandItemID(topItemID int64, isFree bool, isTop bool) int64 {
|
|
||||||
if isFree {
|
|
||||||
v := n.Sheet("FreeSymbolShow", "Weight")
|
|
||||||
|
|
||||||
values, ok := v.([]*structs.SugarRushFreeSymbolShowWeight)
|
|
||||||
if !ok {
|
|
||||||
panic(errors.ConfigTypeError.Error())
|
|
||||||
}
|
|
||||||
|
|
||||||
typeWeights := make([]float64, 0)
|
|
||||||
|
|
||||||
for _, v := range values {
|
|
||||||
if v.ItemID == topItemID {
|
|
||||||
if isTop {
|
|
||||||
typeWeights = append(typeWeights, v.Weight*float64(n.GetOtherConfig().FallWeightMultiplier))
|
|
||||||
} else {
|
|
||||||
typeWeights = append(typeWeights, 0)
|
|
||||||
}
|
|
||||||
} else {
|
|
||||||
typeWeights = append(typeWeights, v.Weight)
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
value := randx.RandWeight(n.Randx, typeWeights)
|
|
||||||
return values[value].ItemID
|
|
||||||
}
|
|
||||||
|
|
||||||
v := n.Sheet("BaseSymbolShow", "Weight")
|
|
||||||
|
|
||||||
values, ok := v.([]*structs.SugarRushBaseSymbolShowWeight)
|
|
||||||
if !ok {
|
|
||||||
panic(errors.ConfigTypeError.Error())
|
|
||||||
}
|
|
||||||
|
|
||||||
typeWeights := make([]float64, 0)
|
|
||||||
|
|
||||||
for _, v := range values {
|
|
||||||
if v.ItemID == topItemID {
|
|
||||||
if isTop {
|
|
||||||
typeWeights = append(typeWeights, v.Weight*float64(n.GetOtherConfig().FallWeightMultiplier))
|
|
||||||
} else {
|
|
||||||
typeWeights = append(typeWeights, 0)
|
|
||||||
}
|
|
||||||
} else {
|
|
||||||
typeWeights = append(typeWeights, v.Weight)
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
value := randx.RandWeight(n.Randx, typeWeights)
|
|
||||||
return values[value].ItemID
|
|
||||||
}
|
|
||||||
|
|
||||||
func (n descx) RandItemCount(itemID int64, left int64, isFree bool) int64 {
|
|
||||||
if isFree {
|
|
||||||
v := n.Sheet("FreeSymbolShowNumber", "Weight")
|
|
||||||
|
|
||||||
values, ok := v.([]*structs.SugarRushFreeSymbolShowNumberWeight)
|
|
||||||
if !ok {
|
|
||||||
panic(errors.ConfigTypeError.Error())
|
|
||||||
}
|
|
||||||
|
|
||||||
for _, v := range values {
|
|
||||||
if v.ItemID == itemID {
|
|
||||||
typeWeights := make([]float64, 0)
|
|
||||||
typeWeights = append(typeWeights, v.ShowNumberWeight...)
|
|
||||||
|
|
||||||
value := randx.RandWeight(n.Randx, typeWeights)
|
|
||||||
count := int64(value) + 1
|
|
||||||
if count > left {
|
|
||||||
return left
|
|
||||||
}
|
|
||||||
return count
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
return 0
|
|
||||||
}
|
|
||||||
|
|
||||||
v := n.Sheet("BaseSymbolShowNumber", "Weight")
|
|
||||||
|
|
||||||
values, ok := v.([]*structs.SugarRushBaseSymbolShowNumberWeight)
|
|
||||||
if !ok {
|
|
||||||
panic(errors.ConfigTypeError.Error())
|
|
||||||
}
|
|
||||||
|
|
||||||
for _, v := range values {
|
|
||||||
if v.ItemID == itemID {
|
|
||||||
typeWeights := make([]float64, 0)
|
|
||||||
typeWeights = append(typeWeights, v.ShowNumberWeight...)
|
|
||||||
|
|
||||||
value := randx.RandWeight(n.Randx, typeWeights)
|
|
||||||
count := int64(value) + 1
|
|
||||||
if count > left {
|
|
||||||
return left
|
|
||||||
}
|
|
||||||
return count
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
return 0
|
|
||||||
}
|
|
||||||
|
|
@ -1,89 +0,0 @@
|
||||||
package sugarrush
|
|
||||||
|
|
||||||
import (
|
|
||||||
"github.com/tomas-qstarrs/boost/mathx"
|
|
||||||
"mongo.games.com/game/gamesrv/slotspkg/internal/generic/key"
|
|
||||||
"mongo.games.com/game/gamesrv/slotspkg/slots/intf"
|
|
||||||
"mongo.games.com/game/gamesrv/slotspkg/slots/plugin/generic"
|
|
||||||
)
|
|
||||||
|
|
||||||
// PluginFreeSpin is derived from generic.PluginBase
|
|
||||||
type PluginFreeSpin struct {
|
|
||||||
generic.PluginScatter
|
|
||||||
}
|
|
||||||
|
|
||||||
// Theme implements generic.PluginBase.Theme
|
|
||||||
func (p *PluginFreeSpin) Theme() string {
|
|
||||||
return key.SugarRush
|
|
||||||
}
|
|
||||||
|
|
||||||
// Customs implements generic.PluginBase.Customs
|
|
||||||
func (p *PluginFreeSpin) Customs() []interface{} {
|
|
||||||
return []interface{}{}
|
|
||||||
}
|
|
||||||
|
|
||||||
// AfterSpin implements generic.PluginBase.AfterSpin
|
|
||||||
func (p *PluginFreeSpin) AfterSpin(m intf.Master) {
|
|
||||||
switch m.Cursor().GetType() {
|
|
||||||
case key.BaseSpin:
|
|
||||||
p.AfterBaseSpin(m)
|
|
||||||
case key.FreeSpin:
|
|
||||||
p.AfterFreeSpin(m)
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
// AfterBaseSpin is called after base spin
|
|
||||||
func (p *PluginFreeSpin) AfterBaseSpin(m intf.Master) {
|
|
||||||
addTimes, win := p.GetScatterInfo(m, false)
|
|
||||||
if addTimes > 0 {
|
|
||||||
m.AddNodeOnCursor(key.FreeSpin, addTimes)
|
|
||||||
}
|
|
||||||
if win > 0 {
|
|
||||||
m.AddCursorFeature(&generic.CustomScatterWin{}).SetWin(win)
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
// AfterFreeSpin is called after free spin
|
|
||||||
func (p *PluginFreeSpin) AfterFreeSpin(m intf.Master) {
|
|
||||||
addTimes, win := p.GetScatterInfo(m, true)
|
|
||||||
if addTimes > 0 {
|
|
||||||
m.AddProgress(addTimes)
|
|
||||||
m.AddCursorFeature(&generic.CustomExtraFreeSpin{ExtraTimes: addTimes}).SetLifetime(1)
|
|
||||||
}
|
|
||||||
if win > 0 {
|
|
||||||
m.AddCursorFeature(&generic.CustomScatterWin{}).SetWin(win)
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
// GetScatterInfo gets add free spin times & pay rate
|
|
||||||
func (p *PluginFreeSpin) GetScatterInfo(m intf.Master, inFreeSpin bool) (int64, int64) {
|
|
||||||
var scatterCount int64
|
|
||||||
symbols := m.CursorFormation().GetFinalSymbols()
|
|
||||||
scatterSymbols := p.Scatters(m)
|
|
||||||
for _, scatterSymbol := range scatterSymbols {
|
|
||||||
scatterCount += int64(mathx.Count(scatterSymbol, symbols))
|
|
||||||
}
|
|
||||||
|
|
||||||
if scatterCount == 0 {
|
|
||||||
return 0, 0
|
|
||||||
}
|
|
||||||
|
|
||||||
freeSpinCount := generic.Descx(m).FreeSpin(inFreeSpin, scatterCount)
|
|
||||||
|
|
||||||
payRate := generic.Descx(m).ScatterPayRate(inFreeSpin, scatterCount)
|
|
||||||
|
|
||||||
win := m.Bet() * payRate
|
|
||||||
|
|
||||||
return freeSpinCount, win
|
|
||||||
}
|
|
||||||
|
|
||||||
// OnStepEnd is called on finalizing a step
|
|
||||||
func (p *PluginFreeSpin) OnStepEnd(m intf.Master) {
|
|
||||||
nextType := m.Next().GetType()
|
|
||||||
|
|
||||||
if m.Cursor().GetType() == key.FreeSpin && nextType == key.BaseSpin {
|
|
||||||
formation := m.NodeFormation(m.Next().GetID())
|
|
||||||
initSymbols := m.CursorFormation().GetFinalSymbols()
|
|
||||||
formation.SetInitSymbols(initSymbols)
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
@ -1,9 +0,0 @@
|
||||||
package sugarrush
|
|
||||||
|
|
||||||
var Plugins = []interface{}{
|
|
||||||
&PluginBaseSpin{},
|
|
||||||
&PluginFreeSpin{},
|
|
||||||
&PluginChooseWheel{},
|
|
||||||
}
|
|
||||||
|
|
||||||
var SimulatorPlugins = []interface{}{}
|
|
||||||
|
|
@ -1,46 +0,0 @@
|
||||||
package sugarrush
|
|
||||||
|
|
||||||
import (
|
|
||||||
"mongo.games.com/game/common"
|
|
||||||
"mongo.games.com/game/gamesrv/base"
|
|
||||||
"mongo.games.com/game/protocol/sugarrush"
|
|
||||||
"mongo.games.com/goserver/core/logger"
|
|
||||||
"mongo.games.com/goserver/core/netlib"
|
|
||||||
)
|
|
||||||
|
|
||||||
type CSSugarRushOpPacketFactory struct {
|
|
||||||
}
|
|
||||||
type CSSugarRushOpHandler struct {
|
|
||||||
}
|
|
||||||
|
|
||||||
func (this *CSSugarRushOpPacketFactory) CreatePacket() interface{} {
|
|
||||||
pack := &sugarrush.CSSugarRushOp{}
|
|
||||||
return pack
|
|
||||||
}
|
|
||||||
|
|
||||||
func (this *CSSugarRushOpHandler) Process(s *netlib.Session, packetid int, data interface{}, sid int64) error {
|
|
||||||
if op, ok := data.(*sugarrush.CSSugarRushOp); ok {
|
|
||||||
p := base.PlayerMgrSington.GetPlayer(sid)
|
|
||||||
if p == nil {
|
|
||||||
logger.Logger.Warn("CSSugarRushOpHandler p == nil")
|
|
||||||
return nil
|
|
||||||
}
|
|
||||||
scene := p.GetScene()
|
|
||||||
if scene == nil {
|
|
||||||
logger.Logger.Warn("CSSugarRushOpHandler p.scene == nil")
|
|
||||||
return nil
|
|
||||||
}
|
|
||||||
if !scene.HasPlayer(p) {
|
|
||||||
return nil
|
|
||||||
}
|
|
||||||
if scene.GetScenePolicy() != nil {
|
|
||||||
scene.GetScenePolicy().OnPlayerOp(scene, p, int(op.GetOpCode()), op.GetParams())
|
|
||||||
}
|
|
||||||
return nil
|
|
||||||
}
|
|
||||||
return nil
|
|
||||||
}
|
|
||||||
func init() {
|
|
||||||
common.RegisterHandler(int(sugarrush.SugarRushPID_PACKET_SUGARRUSH_CSSUGARRUSHOP), &CSSugarRushOpHandler{})
|
|
||||||
netlib.RegisterFactory(int(sugarrush.SugarRushPID_PACKET_SUGARRUSH_CSSUGARRUSHOP), &CSSugarRushOpPacketFactory{})
|
|
||||||
}
|
|
||||||
|
|
@ -1,68 +0,0 @@
|
||||||
package sugarrush
|
|
||||||
|
|
||||||
import (
|
|
||||||
"mongo.games.com/game/gamerule/sugarrush"
|
|
||||||
"mongo.games.com/game/gamesrv/base"
|
|
||||||
"mongo.games.com/game/gamesrv/slotspkg/slots"
|
|
||||||
)
|
|
||||||
|
|
||||||
type SugarRushPlayerData struct {
|
|
||||||
*base.Player
|
|
||||||
base.LabaLog
|
|
||||||
leaveTime int32 //离开时间
|
|
||||||
SlotsSession *base.SlotsSession
|
|
||||||
|
|
||||||
//BetSizeIndex int64 `json:"bsi"` //选中的单注下标
|
|
||||||
//BetLevelIndex int64 `json:"bli"` //选中的等级下标
|
|
||||||
//BetLineIndex int64 `json:"bii"` //选中的线数下标
|
|
||||||
BetMode int64 `json:"bm,optional"` //0.常规 1.%125 2.购买
|
|
||||||
|
|
||||||
taxCoin int64
|
|
||||||
winCoin int64
|
|
||||||
currentLogId string
|
|
||||||
totalBet int64
|
|
||||||
|
|
||||||
isFree bool //只用于判断是否可以离开
|
|
||||||
}
|
|
||||||
type LinkPositions struct {
|
|
||||||
Positions []int64 `json:"Positions,omitempty"`
|
|
||||||
}
|
|
||||||
type CustomEliminate struct {
|
|
||||||
LinkPositions []*LinkPositions `json:"LinkPositions,omitempty"` //消除的位置
|
|
||||||
AppendSymbols [][]int64 `json:"AppendSymbols,omitempty"` //新增
|
|
||||||
FormattedSymbols [][]int64 `json:"FormattedSymbols,omitempty"` //最终的结果
|
|
||||||
LinePays []float64 `json:"LinePays,omitempty"` //赔付
|
|
||||||
WinCoins []float64 `json:"WinCoins,omitempty"` //输赢
|
|
||||||
MultiStr string `json:"multi_str,omitempty"`
|
|
||||||
MultiStrVal string `json:"multi_str_val,omitempty"`
|
|
||||||
SymbolsAbove []int64 `json:"symbols_above,omitempty"`
|
|
||||||
SymbolsBelow []int64 `json:"symbols_below,omitempty"`
|
|
||||||
}
|
|
||||||
type SpinLock struct {
|
|
||||||
CustomEliminates []CustomEliminate `json:"CustomEliminates,omitempty"`
|
|
||||||
Pay float64 `json:"Pay,omitempty"`
|
|
||||||
Multi int64 `json:"Multi,omitempty"`
|
|
||||||
SymbolsAbove []int64 `json:"symbols_above,omitempty"`
|
|
||||||
SymbolsBelow []int64 `json:"symbols_below,omitempty"`
|
|
||||||
}
|
|
||||||
|
|
||||||
func (p *SugarRushPlayerData) init() {
|
|
||||||
p.SlotsSession = base.NewSession(uint64(p.SnId), p.Coin*sugarrush.NowByte)
|
|
||||||
}
|
|
||||||
func (p *SugarRushPlayerData) Clear() {
|
|
||||||
p.taxCoin = 0
|
|
||||||
p.winCoin = 0
|
|
||||||
p.currentLogId = ""
|
|
||||||
p.LabaLog.Clear()
|
|
||||||
}
|
|
||||||
|
|
||||||
// 需要带到world上进行数据处理
|
|
||||||
func (p *SugarRushPlayerData) PushPlayer() map[string]string {
|
|
||||||
cache := slots.SlotsMgrSington.PushPlayer(p.SlotsSession)
|
|
||||||
return cache
|
|
||||||
}
|
|
||||||
|
|
||||||
// 进房的时候需要带进来
|
|
||||||
func (p *SugarRushPlayerData) PullPlayer(data map[string]string) {
|
|
||||||
slots.SlotsMgrSington.PullPlayer(p.SlotsSession, data)
|
|
||||||
}
|
|
||||||
|
|
@ -1,43 +0,0 @@
|
||||||
package sugarrush
|
|
||||||
|
|
||||||
import (
|
|
||||||
"mongo.games.com/game/gamesrv/base"
|
|
||||||
)
|
|
||||||
|
|
||||||
type SugarRushSceneData struct {
|
|
||||||
*base.Scene //场景
|
|
||||||
players map[int32]*SugarRushPlayerData //玩家信息
|
|
||||||
}
|
|
||||||
|
|
||||||
func NewSugarRushSceneData(s *base.Scene) *SugarRushSceneData {
|
|
||||||
sceneEx := &SugarRushSceneData{
|
|
||||||
Scene: s,
|
|
||||||
players: make(map[int32]*SugarRushPlayerData),
|
|
||||||
}
|
|
||||||
sceneEx.Init()
|
|
||||||
return sceneEx
|
|
||||||
}
|
|
||||||
func (s *SugarRushSceneData) Init() {
|
|
||||||
|
|
||||||
}
|
|
||||||
|
|
||||||
func (s *SugarRushSceneData) Clear() {
|
|
||||||
//应该是水池变一次就判断修改一次
|
|
||||||
//s.slotRateWeight = s.slotRateWeightTotal[0]
|
|
||||||
}
|
|
||||||
func (s *SugarRushSceneData) SceneDestroy(force bool) {
|
|
||||||
//销毁房间
|
|
||||||
s.Scene.Destroy(force)
|
|
||||||
}
|
|
||||||
|
|
||||||
func (s *SugarRushSceneData) delPlayer(SnId int32) {
|
|
||||||
if _, exist := s.players[SnId]; exist {
|
|
||||||
delete(s.players, SnId)
|
|
||||||
}
|
|
||||||
}
|
|
||||||
func (s *SugarRushSceneData) OnPlayerLeave(p *base.Player, reason int) {
|
|
||||||
if /*playerEx*/ _, ok := p.ExtraData.(*SugarRushPlayerData); ok {
|
|
||||||
|
|
||||||
}
|
|
||||||
s.delPlayer(p.SnId)
|
|
||||||
}
|
|
||||||
|
|
@ -1,589 +0,0 @@
|
||||||
package sugarrush
|
|
||||||
|
|
||||||
import (
|
|
||||||
"encoding/json"
|
|
||||||
"mongo.games.com/game/common"
|
|
||||||
"mongo.games.com/game/gamerule/sugarrush"
|
|
||||||
"mongo.games.com/game/gamesrv/base"
|
|
||||||
"mongo.games.com/game/gamesrv/slotspkg/slots"
|
|
||||||
"mongo.games.com/game/gamesrv/slotspkg/slots/types/cli"
|
|
||||||
"mongo.games.com/game/model"
|
|
||||||
"mongo.games.com/game/proto"
|
|
||||||
"mongo.games.com/game/protocol/server"
|
|
||||||
protocol "mongo.games.com/game/protocol/sugarrush"
|
|
||||||
"mongo.games.com/goserver/core"
|
|
||||||
"mongo.games.com/goserver/core/logger"
|
|
||||||
"time"
|
|
||||||
)
|
|
||||||
|
|
||||||
// ////////////////////////////////////////////////////////////
|
|
||||||
var ScenePolicySugarRushSington = &ScenePolicySugarRush{}
|
|
||||||
|
|
||||||
type ScenePolicySugarRush struct {
|
|
||||||
base.BaseScenePolicy
|
|
||||||
states [sugarrush.SugarRushStateMax]base.SceneState
|
|
||||||
}
|
|
||||||
|
|
||||||
// 创建场景扩展数据
|
|
||||||
func (this *ScenePolicySugarRush) CreateSceneExData(s *base.Scene) interface{} {
|
|
||||||
sceneEx := NewSugarRushSceneData(s)
|
|
||||||
if sceneEx != nil {
|
|
||||||
if sceneEx.GetInit() {
|
|
||||||
s.SetExtraData(sceneEx)
|
|
||||||
}
|
|
||||||
}
|
|
||||||
return sceneEx
|
|
||||||
}
|
|
||||||
|
|
||||||
// 创建玩家扩展数据
|
|
||||||
func (this *ScenePolicySugarRush) CreatePlayerExData(s *base.Scene, p *base.Player) interface{} {
|
|
||||||
playerEx := &SugarRushPlayerData{Player: p}
|
|
||||||
p.SetExtraData(playerEx)
|
|
||||||
return playerEx
|
|
||||||
}
|
|
||||||
|
|
||||||
// 场景开启事件
|
|
||||||
func (this *ScenePolicySugarRush) OnStart(s *base.Scene) {
|
|
||||||
logger.Logger.Trace("(this *ScenePolicySugarRush) OnStart, sceneId=", s.GetSceneId())
|
|
||||||
sceneEx := NewSugarRushSceneData(s)
|
|
||||||
if sceneEx != nil {
|
|
||||||
if sceneEx.GetInit() {
|
|
||||||
s.SetExtraData(sceneEx)
|
|
||||||
s.ChangeSceneState(sugarrush.SugarRushStateStart)
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
// 场景关闭事件
|
|
||||||
func (this *ScenePolicySugarRush) OnStop(s *base.Scene) {
|
|
||||||
logger.Logger.Trace("(this *ScenePolicySugarRush) OnStop , sceneId=", s.GetSceneId())
|
|
||||||
}
|
|
||||||
|
|
||||||
// 场景心跳事件
|
|
||||||
func (this *ScenePolicySugarRush) OnTick(s *base.Scene) {
|
|
||||||
if s == nil {
|
|
||||||
return
|
|
||||||
}
|
|
||||||
if s.GetSceneState() != nil {
|
|
||||||
s.GetSceneState().OnTick(s)
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
// 玩家进入事件
|
|
||||||
func (this *ScenePolicySugarRush) OnPlayerEnter(s *base.Scene, p *base.Player) {
|
|
||||||
if s == nil || p == nil {
|
|
||||||
return
|
|
||||||
}
|
|
||||||
logger.Logger.Trace("(this *ScenePolicySugarRush) OnPlayerEnter, sceneId=", s.GetSceneId(), " player=", p.Name)
|
|
||||||
if sceneEx, ok := s.GetExtraData().(*SugarRushSceneData); ok {
|
|
||||||
playerEx := &SugarRushPlayerData{Player: p}
|
|
||||||
|
|
||||||
playerEx.init()
|
|
||||||
|
|
||||||
d := p.GameData[sugarrush.GameDataKey]
|
|
||||||
if d != nil {
|
|
||||||
m := make(map[string]string)
|
|
||||||
json.Unmarshal(d.Data.([]byte), &m)
|
|
||||||
playerEx.PullPlayer(m)
|
|
||||||
} else {
|
|
||||||
m := make(map[string]string)
|
|
||||||
//json.Unmarshal(d.Data.([]byte), &m)
|
|
||||||
playerEx.PullPlayer(m)
|
|
||||||
}
|
|
||||||
|
|
||||||
playerEx.SlotsSession.SetCoin(playerEx.Coin * sugarrush.NowByte)
|
|
||||||
|
|
||||||
playerEx.Clear()
|
|
||||||
|
|
||||||
sceneEx.players[p.SnId] = playerEx
|
|
||||||
|
|
||||||
p.SetExtraData(playerEx)
|
|
||||||
SugarRushSendRoomInfo(s, sceneEx, playerEx)
|
|
||||||
|
|
||||||
s.FirePlayerEvent(p, base.PlayerEventEnter, nil)
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
// 玩家离开事件
|
|
||||||
func (this *ScenePolicySugarRush) OnPlayerLeave(s *base.Scene, p *base.Player, reason int) {
|
|
||||||
if s == nil || p == nil {
|
|
||||||
return
|
|
||||||
}
|
|
||||||
logger.Logger.Trace("(this *ScenePolicySugarRush) OnPlayerLeave, sceneId=", s.GetSceneId(), " player=", p.SnId)
|
|
||||||
if playerEx, ok := p.ExtraData.(*SugarRushPlayerData); ok {
|
|
||||||
playerEx.LabaLog.Save(2) // 没有收到结束消息,算2秒游戏时长
|
|
||||||
m := playerEx.PushPlayer()
|
|
||||||
if m != nil && len(m) > 0 {
|
|
||||||
b, err := json.Marshal(m)
|
|
||||||
if err != nil {
|
|
||||||
logger.Logger.Error("OnPlayerLeave, json.Marshal error:", err)
|
|
||||||
} else {
|
|
||||||
p.GameData[sugarrush.GameDataKey] = &model.PlayerGameData{
|
|
||||||
Platform: p.Platform,
|
|
||||||
SnId: p.SnId,
|
|
||||||
Id: sugarrush.GameDataKey,
|
|
||||||
Data: b,
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
if sceneEx, ok := s.ExtraData.(*SugarRushSceneData); ok {
|
|
||||||
s.FirePlayerEvent(p, base.PlayerEventLeave, nil)
|
|
||||||
sceneEx.OnPlayerLeave(p, reason)
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
// 玩家掉线
|
|
||||||
func (this *ScenePolicySugarRush) OnPlayerDropLine(s *base.Scene, p *base.Player) {
|
|
||||||
if s == nil || p == nil {
|
|
||||||
return
|
|
||||||
}
|
|
||||||
logger.Logger.Trace("(this *ScenePolicySugarRush) OnPlayerDropLine, sceneId=", s.GetSceneId(), " player=", p.SnId)
|
|
||||||
s.FirePlayerEvent(p, base.PlayerEventDropLine, nil)
|
|
||||||
}
|
|
||||||
|
|
||||||
// 玩家重连
|
|
||||||
func (this *ScenePolicySugarRush) OnPlayerRehold(s *base.Scene, p *base.Player) {
|
|
||||||
if s == nil || p == nil {
|
|
||||||
return
|
|
||||||
}
|
|
||||||
logger.Logger.Trace("(this *ScenePolicySugarRush) OnPlayerRehold, sceneId=", s.GetSceneId(), " player=", p.SnId)
|
|
||||||
if sceneEx, ok := s.GetExtraData().(*SugarRushSceneData); ok {
|
|
||||||
if playerEx, ok := p.GetExtraData().(*SugarRushPlayerData); ok {
|
|
||||||
SugarRushSendRoomInfo(s, sceneEx, playerEx)
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
// 返回房间
|
|
||||||
func (this *ScenePolicySugarRush) OnPlayerReturn(s *base.Scene, p *base.Player) {
|
|
||||||
if s == nil || p == nil {
|
|
||||||
return
|
|
||||||
}
|
|
||||||
logger.Logger.Trace("(this *ScenePolicySugarRush) OnPlayerReturn, GetSceneId()=", s.GetSceneId(), " player=", p.Name)
|
|
||||||
if sceneEx, ok := s.GetExtraData().(*SugarRushSceneData); ok {
|
|
||||||
if playerEx, ok := p.GetExtraData().(*SugarRushPlayerData); ok {
|
|
||||||
//if p.IsMarkFlag(base.PlayerState_Auto) {
|
|
||||||
// p.UnmarkFlag(base.PlayerState_Auto)
|
|
||||||
// p.SyncFlag()
|
|
||||||
//}
|
|
||||||
//发送房间信息给自己
|
|
||||||
SugarRushSendRoomInfo(s, sceneEx, playerEx)
|
|
||||||
s.FirePlayerEvent(p, base.PlayerEventReturn, nil)
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
func SugarRushSendRoomInfo(s *base.Scene, sceneEx *SugarRushSceneData, playerEx *SugarRushPlayerData) {
|
|
||||||
pack := SugarRushCreateRoomInfoPacket(s, sceneEx, playerEx)
|
|
||||||
logger.Logger.Trace("RoomInfo: ", pack)
|
|
||||||
playerEx.SendToClient(int(protocol.SugarRushPID_PACKET_SUGARRUSH_SCSUGARRUSHROOMINFO), pack)
|
|
||||||
}
|
|
||||||
func SugarRushCreateRoomInfoPacket(s *base.Scene, sceneEx *SugarRushSceneData, playerEx *SugarRushPlayerData) interface{} {
|
|
||||||
//房间信息
|
|
||||||
pack := &protocol.SCSugarRushRoomInfo{
|
|
||||||
RoomId: s.SceneId,
|
|
||||||
GameId: s.GameId,
|
|
||||||
RoomMode: s.SceneMode,
|
|
||||||
SceneType: s.GetSceneType(),
|
|
||||||
Params: common.CopySliceInt64ToInt32(s.Params),
|
|
||||||
NumOfGames: proto.Int(sceneEx.NumOfGames),
|
|
||||||
State: proto.Int(s.SceneState.GetState()),
|
|
||||||
ParamsEx: s.GetDBGameFree().OtherIntParams,
|
|
||||||
GameFreeId: proto.Int32(s.GetDBGameFree().Id),
|
|
||||||
//BetLimit: s.GetDBGameFree().BetLimit,
|
|
||||||
}
|
|
||||||
|
|
||||||
//自己的信息
|
|
||||||
if playerEx != nil {
|
|
||||||
pd := &protocol.SugarRushPlayerData{
|
|
||||||
SnId: proto.Int32(playerEx.SnId),
|
|
||||||
Name: proto.String(playerEx.Name),
|
|
||||||
Head: proto.Int32(playerEx.Head),
|
|
||||||
Sex: proto.Int32(playerEx.Sex),
|
|
||||||
Coin: proto.Int64(playerEx.Coin),
|
|
||||||
Pos: proto.Int(playerEx.Pos),
|
|
||||||
Flag: proto.Int(playerEx.GetFlag()),
|
|
||||||
City: proto.String(playerEx.City),
|
|
||||||
HeadOutLine: proto.Int32(playerEx.HeadOutLine),
|
|
||||||
VIP: proto.Int32(playerEx.VIP),
|
|
||||||
}
|
|
||||||
pack.Player = pd
|
|
||||||
}
|
|
||||||
|
|
||||||
//get data
|
|
||||||
Response, err := slots.SlotsMgrSington.Enter(playerEx.SlotsSession, int64(s.GameId))
|
|
||||||
if err == nil {
|
|
||||||
pi, _ := json.Marshal(Response)
|
|
||||||
pack.PlayerInfo = string(pi)
|
|
||||||
} else {
|
|
||||||
logger.Logger.Error("slots enter err:", err)
|
|
||||||
}
|
|
||||||
proto.SetDefaults(pack)
|
|
||||||
return pack
|
|
||||||
}
|
|
||||||
func (this *ScenePolicySugarRush) OnPlayerOp(s *base.Scene, p *base.Player, opcode int, params []int64) bool {
|
|
||||||
if s == nil || p == nil {
|
|
||||||
return false
|
|
||||||
}
|
|
||||||
logger.Logger.Trace("(this *ScenePolicySugarRush) OnPlayerOp, sceneId=", s.GetSceneId(), " player=", p.SnId, " opcode=", opcode, " params=", params)
|
|
||||||
if s.GetSceneState() != nil {
|
|
||||||
if s.GetSceneState().OnPlayerOp(s, p, opcode, params) {
|
|
||||||
p.SetLastOPTimer(time.Now())
|
|
||||||
return true
|
|
||||||
}
|
|
||||||
return false
|
|
||||||
}
|
|
||||||
return true
|
|
||||||
}
|
|
||||||
|
|
||||||
func (this *ScenePolicySugarRush) OnPlayerEvent(s *base.Scene, p *base.Player, evtcode int, params []int64) {
|
|
||||||
if s == nil || p == nil {
|
|
||||||
return
|
|
||||||
}
|
|
||||||
logger.Logger.Trace("(this *ScenePolicySugarRush) OnPlayerEvent, sceneId=", s.GetSceneId(), " player=", p.SnId, " eventcode=", evtcode, " params=", params)
|
|
||||||
if s.GetSceneState() != nil {
|
|
||||||
s.GetSceneState().OnPlayerEvent(s, p, evtcode, params)
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
// 当前状态能否换桌
|
|
||||||
func (this *ScenePolicySugarRush) CanChangeCoinScene(s *base.Scene, p *base.Player) bool {
|
|
||||||
if s == nil || p == nil {
|
|
||||||
return false
|
|
||||||
}
|
|
||||||
if s.GetSceneState() != nil {
|
|
||||||
return s.GetSceneState().CanChangeCoinScene(s, p)
|
|
||||||
}
|
|
||||||
return false
|
|
||||||
}
|
|
||||||
|
|
||||||
// 状态基类
|
|
||||||
type SceneBaseStateSugarRush struct {
|
|
||||||
}
|
|
||||||
|
|
||||||
func (this *SceneBaseStateSugarRush) GetTimeout(s *base.Scene) int {
|
|
||||||
if sceneEx, ok := s.GetExtraData().(*SugarRushSceneData); ok {
|
|
||||||
return int(time.Now().Sub(sceneEx.GetStateStartTime()) / time.Second)
|
|
||||||
}
|
|
||||||
return 0
|
|
||||||
}
|
|
||||||
|
|
||||||
func (this *SceneBaseStateSugarRush) CanChangeTo(s base.SceneState) bool {
|
|
||||||
return true
|
|
||||||
}
|
|
||||||
|
|
||||||
// 当前状态能否换桌
|
|
||||||
func (this *SceneBaseStateSugarRush) CanChangeCoinScene(s *base.Scene, p *base.Player) bool {
|
|
||||||
return true
|
|
||||||
}
|
|
||||||
func (this *SceneBaseStateSugarRush) OnEnter(s *base.Scene) {
|
|
||||||
if sceneEx, ok := s.GetExtraData().(*SugarRushSceneData); ok {
|
|
||||||
sceneEx.SetStateStartTime(time.Now())
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
func (this *SceneBaseStateSugarRush) OnLeave(s *base.Scene) {}
|
|
||||||
func (this *SceneBaseStateSugarRush) OnTick(s *base.Scene) {
|
|
||||||
if time.Now().Sub(s.GameStartTime) > time.Second*3 {
|
|
||||||
if sceneEx, ok := s.ExtraData.(*SugarRushSceneData); ok {
|
|
||||||
for _, p := range sceneEx.players {
|
|
||||||
if p.IsOnLine() {
|
|
||||||
p.leaveTime = 0
|
|
||||||
continue
|
|
||||||
}
|
|
||||||
p.leaveTime++
|
|
||||||
if p.leaveTime < 60*2 {
|
|
||||||
continue
|
|
||||||
}
|
|
||||||
//踢出玩家
|
|
||||||
sceneEx.PlayerLeave(p.Player, common.PlayerLeaveReason_LongTimeNoOp, true)
|
|
||||||
}
|
|
||||||
}
|
|
||||||
s.GameStartTime = time.Now()
|
|
||||||
}
|
|
||||||
}
|
|
||||||
func (this *SceneBaseStateSugarRush) OnPlayerOp(s *base.Scene, p *base.Player, opcode int, params []int64) bool {
|
|
||||||
return false
|
|
||||||
}
|
|
||||||
func (this *SceneBaseStateSugarRush) OnPlayerEvent(s *base.Scene, p *base.Player, evtcode int, params []int64) {
|
|
||||||
}
|
|
||||||
|
|
||||||
// ////////////////////////////////////////////////////////////
|
|
||||||
// 开始状态
|
|
||||||
// ////////////////////////////////////////////////////////////
|
|
||||||
type SceneStateStartSugarRush struct {
|
|
||||||
SceneBaseStateSugarRush
|
|
||||||
}
|
|
||||||
|
|
||||||
func (this *SceneStateStartSugarRush) GetState() int {
|
|
||||||
return sugarrush.SugarRushStateStart
|
|
||||||
}
|
|
||||||
|
|
||||||
func (this *SceneStateStartSugarRush) CanChangeTo(s base.SceneState) bool {
|
|
||||||
return false
|
|
||||||
}
|
|
||||||
|
|
||||||
// 当前状态能否换桌
|
|
||||||
func (this *SceneStateStartSugarRush) CanChangeCoinScene(s *base.Scene, p *base.Player) bool {
|
|
||||||
if playerEx, ok := p.GetExtraData().(*SugarRushPlayerData); ok {
|
|
||||||
if playerEx.isFree {
|
|
||||||
return false
|
|
||||||
}
|
|
||||||
}
|
|
||||||
return true
|
|
||||||
}
|
|
||||||
|
|
||||||
func (this *SceneStateStartSugarRush) GetTimeout(s *base.Scene) int {
|
|
||||||
return 0
|
|
||||||
}
|
|
||||||
|
|
||||||
func (this *SceneStateStartSugarRush) OnEnter(s *base.Scene) {
|
|
||||||
this.SceneBaseStateSugarRush.OnEnter(s)
|
|
||||||
if sceneEx, ok := s.GetExtraData().(*SugarRushSceneData); ok {
|
|
||||||
sceneEx.SetGameNowTime(time.Now())
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
// 状态离开时
|
|
||||||
func (this *SceneStateStartSugarRush) OnLeave(s *base.Scene) {
|
|
||||||
this.SceneBaseStateSugarRush.OnLeave(s)
|
|
||||||
logger.Logger.Tracef("(this *SceneStateStartSugarRush) OnLeave, sceneid=%v", s.GetSceneId())
|
|
||||||
}
|
|
||||||
|
|
||||||
// 玩家操作
|
|
||||||
func (this *SceneStateStartSugarRush) OnPlayerOp(s *base.Scene, p *base.Player, opcode int, params []int64) bool {
|
|
||||||
logger.Logger.Tracef("(this *SceneStateStartSugarRush) OnPlayerOp, sceneid=%v params=%v", s.GetSceneId(), params)
|
|
||||||
if this.SceneBaseStateSugarRush.OnPlayerOp(s, p, opcode, params) {
|
|
||||||
return true
|
|
||||||
}
|
|
||||||
if sceneEx, ok := s.GetExtraData().(*SugarRushSceneData); ok {
|
|
||||||
if playerEx, ok := p.GetExtraData().(*SugarRushPlayerData); ok {
|
|
||||||
switch opcode {
|
|
||||||
case sugarrush.SugarRushPlayerOpStart:
|
|
||||||
playerEx.Clear()
|
|
||||||
if len(params) < 4 {
|
|
||||||
pack := &protocol.SCSugarRushBilled{
|
|
||||||
OpRetCode: proto.Int32(1),
|
|
||||||
}
|
|
||||||
proto.SetDefaults(pack)
|
|
||||||
logger.Logger.Trace("SCSugarRushBilled", pack.String())
|
|
||||||
playerEx.SendToClient(int(protocol.SugarRushPID_PACKET_SUGARRUSH_SCSUGARRUSHBILLED), pack)
|
|
||||||
return true
|
|
||||||
}
|
|
||||||
cval := params[0]
|
|
||||||
playerEx.BetMode = params[1]
|
|
||||||
needCoin := cval * 20
|
|
||||||
if needCoin > playerEx.Coin && !playerEx.isFree {
|
|
||||||
pack := &protocol.SCSugarRushBilled{
|
|
||||||
OpRetCode: proto.Int32(1),
|
|
||||||
}
|
|
||||||
proto.SetDefaults(pack)
|
|
||||||
logger.Logger.Trace("SCSugarRushBilled:", pack.String())
|
|
||||||
playerEx.SendToClient(int(protocol.SugarRushPID_PACKET_SUGARRUSH_SCSUGARRUSHBILLED), pack)
|
|
||||||
return true
|
|
||||||
}
|
|
||||||
|
|
||||||
//playerEx.SlotsSession.SetCoin(playerEx.Coin * sugarrush.NowByte)
|
|
||||||
//logger.Logger.Trace("=============init dif coin", playerEx.Coin-playerEx.SlotsSession.Coin()/sugarrush.NowByte)
|
|
||||||
|
|
||||||
index := slots.SlotsMgrSington.PPGetBetIndex(playerEx.SlotsSession, "SugarRush", float64(cval*20))
|
|
||||||
if index == nil {
|
|
||||||
pack := &protocol.SCSugarRushBilled{
|
|
||||||
OpRetCode: proto.Int32(2),
|
|
||||||
}
|
|
||||||
proto.SetDefaults(pack)
|
|
||||||
logger.Logger.Trace("SCSugarRushBilled:", pack.String())
|
|
||||||
playerEx.SendToClient(int(protocol.SugarRushPID_PACKET_SUGARRUSH_SCSUGARRUSHBILLED), pack)
|
|
||||||
return true
|
|
||||||
}
|
|
||||||
//get data
|
|
||||||
Response, err := slots.SlotsMgrSington.Play(playerEx.SlotsSession, &base.SpinReq{
|
|
||||||
GameId: int64(sceneEx.GameId),
|
|
||||||
BetSizeIndex: index[0],
|
|
||||||
BetLevelIndex: index[1],
|
|
||||||
BetLineIndex: 0,
|
|
||||||
BetMode: playerEx.BetMode,
|
|
||||||
Ts: time.Now().Unix(),
|
|
||||||
})
|
|
||||||
if err != nil {
|
|
||||||
logger.Logger.Error("slots Play err:", err)
|
|
||||||
pack := &protocol.SCSugarRushBilled{
|
|
||||||
OpRetCode: proto.Int32(3),
|
|
||||||
}
|
|
||||||
proto.SetDefaults(pack)
|
|
||||||
logger.Logger.Trace("SCSugarRushBilled:", pack.String())
|
|
||||||
playerEx.SendToClient(int(protocol.SugarRushPID_PACKET_SUGARRUSH_SCSUGARRUSHBILLED), pack)
|
|
||||||
return true
|
|
||||||
}
|
|
||||||
var ActualWin = Response.ActualWin / sugarrush.NowByte
|
|
||||||
s.SetGameNowTime(time.Now())
|
|
||||||
midNodes := Response.NodeTree.Nodes[1]
|
|
||||||
lastNodes := Response.NodeTree.Nodes[2]
|
|
||||||
playerEx.isFree = false
|
|
||||||
var needWinBilled = true
|
|
||||||
|
|
||||||
var totalIn, totalOut int64
|
|
||||||
//下注
|
|
||||||
if midNodes.Type == "BaseSpin" && lastNodes.Type == "FreeSpin" {
|
|
||||||
playerEx.isFree = true
|
|
||||||
needWinBilled = false
|
|
||||||
if lastNodes.ProgressValue == 0 {
|
|
||||||
//第一次触发
|
|
||||||
playerEx.totalBet = Response.ActualBet / sugarrush.NowByte
|
|
||||||
playerEx.AddCoin(-playerEx.totalBet, common.GainWay_HundredSceneLost, base.SyncFlag_ToClient, "system", s.GetSceneName())
|
|
||||||
totalIn = playerEx.totalBet
|
|
||||||
}
|
|
||||||
if lastNodes.ProgressValue == lastNodes.ProgressMax {
|
|
||||||
needWinBilled = true
|
|
||||||
}
|
|
||||||
} else {
|
|
||||||
//正常模式
|
|
||||||
playerEx.totalBet = Response.ActualBet / sugarrush.NowByte
|
|
||||||
totalIn = playerEx.totalBet
|
|
||||||
playerEx.AddCoin(-playerEx.totalBet, common.GainWay_HundredSceneLost, base.SyncFlag_ToClient, "system", s.GetSceneName())
|
|
||||||
}
|
|
||||||
|
|
||||||
if needWinBilled {
|
|
||||||
var taxCoin int64
|
|
||||||
if ActualWin > 0 {
|
|
||||||
//税收比例
|
|
||||||
taxRate := sceneEx.GetDBGameFree().GetTaxRate()
|
|
||||||
if taxRate < 0 || taxRate > 10000 {
|
|
||||||
taxRate = 500
|
|
||||||
}
|
|
||||||
taxCoin = ActualWin * int64(taxRate) / 10000
|
|
||||||
playerEx.AddServiceFee(taxCoin)
|
|
||||||
playerEx.taxCoin = taxCoin
|
|
||||||
playerEx.winCoin = ActualWin - taxCoin
|
|
||||||
ActualWin = playerEx.winCoin
|
|
||||||
}
|
|
||||||
|
|
||||||
totalOut = ActualWin
|
|
||||||
|
|
||||||
playerEx.AddCoin(ActualWin, common.GainWay_HundredSceneWin, 0, "system", s.GetSceneName())
|
|
||||||
//免费游戏结束或者正常模式
|
|
||||||
sceneEx.StaticsLaba(&base.StaticLabaParam{
|
|
||||||
SnId: playerEx.SnId,
|
|
||||||
Gain: ActualWin - playerEx.totalBet,
|
|
||||||
GainTax: playerEx.taxCoin,
|
|
||||||
IsAddTimes: true,
|
|
||||||
})
|
|
||||||
}
|
|
||||||
|
|
||||||
playerEx.SlotsSession.SetCoin(Response.Coin)
|
|
||||||
|
|
||||||
pi, _ := json.Marshal(Response)
|
|
||||||
gameEndStr := string(pi)
|
|
||||||
pack := &protocol.SCSugarRushBilled{
|
|
||||||
OpRetCode: proto.Int32(0),
|
|
||||||
GameEndStr: proto.String(gameEndStr),
|
|
||||||
}
|
|
||||||
proto.SetDefaults(pack)
|
|
||||||
logger.Logger.Trace("SCSugarRushBilled", pack.String())
|
|
||||||
playerEx.SendToClient(int(protocol.SugarRushPID_PACKET_SUGARRUSH_SCSUGARRUSHBILLED), pack)
|
|
||||||
|
|
||||||
if playerEx.Coin != ActualWin {
|
|
||||||
logger.Logger.Error("==========playerEx.Coin != Response.Coin==============", playerEx.Coin, ActualWin)
|
|
||||||
}
|
|
||||||
|
|
||||||
// 记录本次操作
|
|
||||||
SugarRushAndSaveLog(sceneEx, playerEx, Response, totalIn, totalOut)
|
|
||||||
case 1000:
|
|
||||||
playerEx.Save(0)
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
return true
|
|
||||||
}
|
|
||||||
|
|
||||||
// 玩家事件
|
|
||||||
func (this *SceneStateStartSugarRush) OnPlayerEvent(s *base.Scene, p *base.Player, evtcode int, params []int64) {
|
|
||||||
logger.Logger.Trace("(this *SceneStateStartSugarRush) OnPlayerEvent, sceneId=", s.GetSceneId(), " player=", p.SnId, " evtcode=", evtcode)
|
|
||||||
this.SceneBaseStateSugarRush.OnPlayerEvent(s, p, evtcode, params)
|
|
||||||
}
|
|
||||||
|
|
||||||
func (this *SceneStateStartSugarRush) OnTick(s *base.Scene) {
|
|
||||||
this.SceneBaseStateSugarRush.OnTick(s)
|
|
||||||
}
|
|
||||||
|
|
||||||
// //////////////////////////////////////////////////////////////////////////////
|
|
||||||
func (this *ScenePolicySugarRush) RegisteSceneState(state base.SceneState) {
|
|
||||||
if state == nil {
|
|
||||||
return
|
|
||||||
}
|
|
||||||
stateid := state.GetState()
|
|
||||||
if stateid < 0 || stateid >= sugarrush.SugarRushStateMax {
|
|
||||||
return
|
|
||||||
}
|
|
||||||
this.states[stateid] = state
|
|
||||||
}
|
|
||||||
|
|
||||||
func (this *ScenePolicySugarRush) GetSceneState(s *base.Scene, stateid int) base.SceneState {
|
|
||||||
if stateid >= 0 && stateid < sugarrush.SugarRushStateMax {
|
|
||||||
return this.states[stateid]
|
|
||||||
}
|
|
||||||
return nil
|
|
||||||
}
|
|
||||||
func SugarRushAndSaveLog(sceneEx *SugarRushSceneData, playerEx *SugarRushPlayerData, Response *cli.SlotsPlayResponse,
|
|
||||||
totalIn, totalOut int64) {
|
|
||||||
if !playerEx.IsRob {
|
|
||||||
info, err := model.MarshalGameNoteByROLL(Response)
|
|
||||||
if err == nil {
|
|
||||||
logid, _ := model.AutoIncGameLogId()
|
|
||||||
playerEx.currentLogId = logid
|
|
||||||
playerEx.Cache(sceneEx.Scene, &base.SaveGameDetailedParam{
|
|
||||||
LogId: logid,
|
|
||||||
Detail: info,
|
|
||||||
}, &base.SaveGamePlayerListLogParam{
|
|
||||||
LogId: logid,
|
|
||||||
Platform: playerEx.Platform,
|
|
||||||
Snid: playerEx.SnId,
|
|
||||||
PlayerName: playerEx.Name,
|
|
||||||
TotalIn: totalIn,
|
|
||||||
TotalOut: totalOut,
|
|
||||||
TaxCoin: playerEx.taxCoin,
|
|
||||||
BetAmount: totalIn,
|
|
||||||
WinAmountNoAnyTax: totalOut - totalIn - playerEx.taxCoin,
|
|
||||||
IsFirstGame: sceneEx.IsPlayerFirst(playerEx.Player),
|
|
||||||
IsFree: playerEx.isFree,
|
|
||||||
})
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
//统计输下注金币数
|
|
||||||
if !sceneEx.Testing && !playerEx.IsRob {
|
|
||||||
playerBet := &server.PlayerData{
|
|
||||||
SnId: proto.Int32(playerEx.SnId),
|
|
||||||
Bet: proto.Int64(playerEx.CurrentBet),
|
|
||||||
Gain: proto.Int64(Response.ActualWin/sugarrush.NowByte + playerEx.taxCoin),
|
|
||||||
Tax: proto.Int64(playerEx.taxCoin),
|
|
||||||
Coin: proto.Int64(playerEx.GetCoin()),
|
|
||||||
GameCoinTs: proto.Int64(playerEx.GameCoinTs),
|
|
||||||
}
|
|
||||||
gwPlayerBet := &server.GWPlayerData{
|
|
||||||
SceneId: sceneEx.SceneId,
|
|
||||||
GameFreeId: proto.Int32(sceneEx.GetDBGameFree().GetId()),
|
|
||||||
}
|
|
||||||
gwPlayerBet.Datas = append(gwPlayerBet.Datas, playerBet)
|
|
||||||
sceneEx.SyncPlayerDatas(&base.PlayerDataParam{
|
|
||||||
HasRobotGaming: false,
|
|
||||||
Data: gwPlayerBet,
|
|
||||||
})
|
|
||||||
}
|
|
||||||
|
|
||||||
playerEx.taxCoin = 0
|
|
||||||
playerEx.winCoin = 0
|
|
||||||
|
|
||||||
if sceneEx.CheckNeedDestroy() && !playerEx.isFree {
|
|
||||||
sceneEx.SceneDestroy(true)
|
|
||||||
}
|
|
||||||
}
|
|
||||||
func init() {
|
|
||||||
//主状态
|
|
||||||
ScenePolicySugarRushSington.RegisteSceneState(&SceneStateStartSugarRush{})
|
|
||||||
core.RegisteHook(core.HOOK_BEFORE_START, func() error {
|
|
||||||
base.RegisteScenePolicy(common.GameId_SugarRush, sugarrush.RoomMode_Classic, ScenePolicySugarRushSington)
|
|
||||||
return nil
|
|
||||||
})
|
|
||||||
}
|
|
||||||
|
|
@ -197,17 +197,5 @@
|
||||||
|
|
||||||
- 5670~5679
|
- 5670~5679
|
||||||
|
|
||||||
### fortunesnake.proto
|
|
||||||
|
|
||||||
- 5680~5689
|
|
||||||
|
|
||||||
### ganeshagold.proto
|
|
||||||
|
|
||||||
- 5690~5699
|
|
||||||
|
|
||||||
### sugarrush.proto
|
|
||||||
|
|
||||||
- 5700~5709
|
|
||||||
|
|
||||||
### game.proto(玩家离开)
|
### game.proto(玩家离开)
|
||||||
- 8000~8099
|
- 8000~8099
|
||||||
|
|
@ -1,803 +0,0 @@
|
||||||
// Code generated by protoc-gen-go. DO NOT EDIT.
|
|
||||||
// versions:
|
|
||||||
// protoc-gen-go v1.27.1-devel
|
|
||||||
// protoc v3.19.4
|
|
||||||
// source: protocol/fortunesnake/fortunesnake.proto
|
|
||||||
|
|
||||||
package fortunesnake
|
|
||||||
|
|
||||||
import (
|
|
||||||
protoreflect "google.golang.org/protobuf/reflect/protoreflect"
|
|
||||||
protoimpl "google.golang.org/protobuf/runtime/protoimpl"
|
|
||||||
reflect "reflect"
|
|
||||||
sync "sync"
|
|
||||||
)
|
|
||||||
|
|
||||||
const (
|
|
||||||
// Verify that this generated code is sufficiently up-to-date.
|
|
||||||
_ = protoimpl.EnforceVersion(20 - protoimpl.MinVersion)
|
|
||||||
// Verify that runtime/protoimpl is sufficiently up-to-date.
|
|
||||||
_ = protoimpl.EnforceVersion(protoimpl.MaxVersion - 20)
|
|
||||||
)
|
|
||||||
|
|
||||||
//fortunesnake
|
|
||||||
//龙
|
|
||||||
type FortuneSnakePID int32
|
|
||||||
|
|
||||||
const (
|
|
||||||
FortuneSnakePID_PACKET_FORTUNESNAKE_ZERO FortuneSnakePID = 0 // 弃用消息号
|
|
||||||
FortuneSnakePID_PACKET_FORTUNESNAKE_SCFORTUNESNAKEROOMINFO FortuneSnakePID = 5680 //房间信息
|
|
||||||
FortuneSnakePID_PACKET_FORTUNESNAKE_CSFORTUNESNAKEOP FortuneSnakePID = 5681
|
|
||||||
FortuneSnakePID_PACKET_FORTUNESNAKE_SCFORTUNESNAKEOP FortuneSnakePID = 5682
|
|
||||||
FortuneSnakePID_PACKET_FORTUNESNAKE_SCFORTUNESNAKEROOMSTATE FortuneSnakePID = 5683
|
|
||||||
FortuneSnakePID_PACKET_FORTUNESNAKE_SCFORTUNESNAKEBILLED FortuneSnakePID = 5684
|
|
||||||
)
|
|
||||||
|
|
||||||
// Enum value maps for FortuneSnakePID.
|
|
||||||
var (
|
|
||||||
FortuneSnakePID_name = map[int32]string{
|
|
||||||
0: "PACKET_FORTUNESNAKE_ZERO",
|
|
||||||
5680: "PACKET_FORTUNESNAKE_SCFORTUNESNAKEROOMINFO",
|
|
||||||
5681: "PACKET_FORTUNESNAKE_CSFORTUNESNAKEOP",
|
|
||||||
5682: "PACKET_FORTUNESNAKE_SCFORTUNESNAKEOP",
|
|
||||||
5683: "PACKET_FORTUNESNAKE_SCFORTUNESNAKEROOMSTATE",
|
|
||||||
5684: "PACKET_FORTUNESNAKE_SCFORTUNESNAKEBILLED",
|
|
||||||
}
|
|
||||||
FortuneSnakePID_value = map[string]int32{
|
|
||||||
"PACKET_FORTUNESNAKE_ZERO": 0,
|
|
||||||
"PACKET_FORTUNESNAKE_SCFORTUNESNAKEROOMINFO": 5680,
|
|
||||||
"PACKET_FORTUNESNAKE_CSFORTUNESNAKEOP": 5681,
|
|
||||||
"PACKET_FORTUNESNAKE_SCFORTUNESNAKEOP": 5682,
|
|
||||||
"PACKET_FORTUNESNAKE_SCFORTUNESNAKEROOMSTATE": 5683,
|
|
||||||
"PACKET_FORTUNESNAKE_SCFORTUNESNAKEBILLED": 5684,
|
|
||||||
}
|
|
||||||
)
|
|
||||||
|
|
||||||
func (x FortuneSnakePID) Enum() *FortuneSnakePID {
|
|
||||||
p := new(FortuneSnakePID)
|
|
||||||
*p = x
|
|
||||||
return p
|
|
||||||
}
|
|
||||||
|
|
||||||
func (x FortuneSnakePID) String() string {
|
|
||||||
return protoimpl.X.EnumStringOf(x.Descriptor(), protoreflect.EnumNumber(x))
|
|
||||||
}
|
|
||||||
|
|
||||||
func (FortuneSnakePID) Descriptor() protoreflect.EnumDescriptor {
|
|
||||||
return file_protocol_fortunesnake_fortunesnake_proto_enumTypes[0].Descriptor()
|
|
||||||
}
|
|
||||||
|
|
||||||
func (FortuneSnakePID) Type() protoreflect.EnumType {
|
|
||||||
return &file_protocol_fortunesnake_fortunesnake_proto_enumTypes[0]
|
|
||||||
}
|
|
||||||
|
|
||||||
func (x FortuneSnakePID) Number() protoreflect.EnumNumber {
|
|
||||||
return protoreflect.EnumNumber(x)
|
|
||||||
}
|
|
||||||
|
|
||||||
// Deprecated: Use FortuneSnakePID.Descriptor instead.
|
|
||||||
func (FortuneSnakePID) EnumDescriptor() ([]byte, []int) {
|
|
||||||
return file_protocol_fortunesnake_fortunesnake_proto_rawDescGZIP(), []int{0}
|
|
||||||
}
|
|
||||||
|
|
||||||
type FortuneSnakePlayerData struct {
|
|
||||||
state protoimpl.MessageState
|
|
||||||
sizeCache protoimpl.SizeCache
|
|
||||||
unknownFields protoimpl.UnknownFields
|
|
||||||
|
|
||||||
Name string `protobuf:"bytes,1,opt,name=Name,proto3" json:"Name,omitempty"` //名字
|
|
||||||
SnId int32 `protobuf:"varint,2,opt,name=SnId,proto3" json:"SnId,omitempty"` //账号
|
|
||||||
Head int32 `protobuf:"varint,3,opt,name=Head,proto3" json:"Head,omitempty"` //头像
|
|
||||||
Sex int32 `protobuf:"varint,4,opt,name=Sex,proto3" json:"Sex,omitempty"` //性别
|
|
||||||
Coin int64 `protobuf:"varint,5,opt,name=Coin,proto3" json:"Coin,omitempty"` //金币
|
|
||||||
Pos int32 `protobuf:"varint,6,opt,name=Pos,proto3" json:"Pos,omitempty"` //座位位置
|
|
||||||
Flag int32 `protobuf:"varint,7,opt,name=Flag,proto3" json:"Flag,omitempty"` //二进制标记
|
|
||||||
Params []string `protobuf:"bytes,8,rep,name=Params,proto3" json:"Params,omitempty"` //其他数据 如:ip 等
|
|
||||||
City string `protobuf:"bytes,9,opt,name=City,proto3" json:"City,omitempty"` //城市
|
|
||||||
HeadOutLine int32 `protobuf:"varint,10,opt,name=HeadOutLine,proto3" json:"HeadOutLine,omitempty"` //头像框
|
|
||||||
VIP int32 `protobuf:"varint,11,opt,name=VIP,proto3" json:"VIP,omitempty"`
|
|
||||||
}
|
|
||||||
|
|
||||||
func (x *FortuneSnakePlayerData) Reset() {
|
|
||||||
*x = FortuneSnakePlayerData{}
|
|
||||||
if protoimpl.UnsafeEnabled {
|
|
||||||
mi := &file_protocol_fortunesnake_fortunesnake_proto_msgTypes[0]
|
|
||||||
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
|
||||||
ms.StoreMessageInfo(mi)
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
func (x *FortuneSnakePlayerData) String() string {
|
|
||||||
return protoimpl.X.MessageStringOf(x)
|
|
||||||
}
|
|
||||||
|
|
||||||
func (*FortuneSnakePlayerData) ProtoMessage() {}
|
|
||||||
|
|
||||||
func (x *FortuneSnakePlayerData) ProtoReflect() protoreflect.Message {
|
|
||||||
mi := &file_protocol_fortunesnake_fortunesnake_proto_msgTypes[0]
|
|
||||||
if protoimpl.UnsafeEnabled && x != nil {
|
|
||||||
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
|
||||||
if ms.LoadMessageInfo() == nil {
|
|
||||||
ms.StoreMessageInfo(mi)
|
|
||||||
}
|
|
||||||
return ms
|
|
||||||
}
|
|
||||||
return mi.MessageOf(x)
|
|
||||||
}
|
|
||||||
|
|
||||||
// Deprecated: Use FortuneSnakePlayerData.ProtoReflect.Descriptor instead.
|
|
||||||
func (*FortuneSnakePlayerData) Descriptor() ([]byte, []int) {
|
|
||||||
return file_protocol_fortunesnake_fortunesnake_proto_rawDescGZIP(), []int{0}
|
|
||||||
}
|
|
||||||
|
|
||||||
func (x *FortuneSnakePlayerData) GetName() string {
|
|
||||||
if x != nil {
|
|
||||||
return x.Name
|
|
||||||
}
|
|
||||||
return ""
|
|
||||||
}
|
|
||||||
|
|
||||||
func (x *FortuneSnakePlayerData) GetSnId() int32 {
|
|
||||||
if x != nil {
|
|
||||||
return x.SnId
|
|
||||||
}
|
|
||||||
return 0
|
|
||||||
}
|
|
||||||
|
|
||||||
func (x *FortuneSnakePlayerData) GetHead() int32 {
|
|
||||||
if x != nil {
|
|
||||||
return x.Head
|
|
||||||
}
|
|
||||||
return 0
|
|
||||||
}
|
|
||||||
|
|
||||||
func (x *FortuneSnakePlayerData) GetSex() int32 {
|
|
||||||
if x != nil {
|
|
||||||
return x.Sex
|
|
||||||
}
|
|
||||||
return 0
|
|
||||||
}
|
|
||||||
|
|
||||||
func (x *FortuneSnakePlayerData) GetCoin() int64 {
|
|
||||||
if x != nil {
|
|
||||||
return x.Coin
|
|
||||||
}
|
|
||||||
return 0
|
|
||||||
}
|
|
||||||
|
|
||||||
func (x *FortuneSnakePlayerData) GetPos() int32 {
|
|
||||||
if x != nil {
|
|
||||||
return x.Pos
|
|
||||||
}
|
|
||||||
return 0
|
|
||||||
}
|
|
||||||
|
|
||||||
func (x *FortuneSnakePlayerData) GetFlag() int32 {
|
|
||||||
if x != nil {
|
|
||||||
return x.Flag
|
|
||||||
}
|
|
||||||
return 0
|
|
||||||
}
|
|
||||||
|
|
||||||
func (x *FortuneSnakePlayerData) GetParams() []string {
|
|
||||||
if x != nil {
|
|
||||||
return x.Params
|
|
||||||
}
|
|
||||||
return nil
|
|
||||||
}
|
|
||||||
|
|
||||||
func (x *FortuneSnakePlayerData) GetCity() string {
|
|
||||||
if x != nil {
|
|
||||||
return x.City
|
|
||||||
}
|
|
||||||
return ""
|
|
||||||
}
|
|
||||||
|
|
||||||
func (x *FortuneSnakePlayerData) GetHeadOutLine() int32 {
|
|
||||||
if x != nil {
|
|
||||||
return x.HeadOutLine
|
|
||||||
}
|
|
||||||
return 0
|
|
||||||
}
|
|
||||||
|
|
||||||
func (x *FortuneSnakePlayerData) GetVIP() int32 {
|
|
||||||
if x != nil {
|
|
||||||
return x.VIP
|
|
||||||
}
|
|
||||||
return 0
|
|
||||||
}
|
|
||||||
|
|
||||||
//房间信息
|
|
||||||
//PACKET_FORTUNESNAKE_SCFORTUNESNAKEROOMINFO
|
|
||||||
type SCFortuneSnakeRoomInfo struct {
|
|
||||||
state protoimpl.MessageState
|
|
||||||
sizeCache protoimpl.SizeCache
|
|
||||||
unknownFields protoimpl.UnknownFields
|
|
||||||
|
|
||||||
RoomId int32 `protobuf:"varint,1,opt,name=RoomId,proto3" json:"RoomId,omitempty"` //房间id
|
|
||||||
GameFreeId int32 `protobuf:"varint,2,opt,name=GameFreeId,proto3" json:"GameFreeId,omitempty"`
|
|
||||||
GameId int32 `protobuf:"varint,3,opt,name=GameId,proto3" json:"GameId,omitempty"` //游戏id
|
|
||||||
RoomMode int32 `protobuf:"varint,4,opt,name=RoomMode,proto3" json:"RoomMode,omitempty"` //游戏模式
|
|
||||||
Params []int32 `protobuf:"varint,5,rep,packed,name=Params,proto3" json:"Params,omitempty"` //规则参数
|
|
||||||
NumOfGames int32 `protobuf:"varint,6,opt,name=NumOfGames,proto3" json:"NumOfGames,omitempty"` //当前第几局
|
|
||||||
State int32 `protobuf:"varint,7,opt,name=State,proto3" json:"State,omitempty"` //房间当前状态
|
|
||||||
ParamsEx []int64 `protobuf:"varint,8,rep,packed,name=ParamsEx,proto3" json:"ParamsEx,omitempty"` //其他参数
|
|
||||||
SceneType int32 `protobuf:"varint,9,opt,name=SceneType,proto3" json:"SceneType,omitempty"` //房间模式
|
|
||||||
Player *FortuneSnakePlayerData `protobuf:"bytes,10,opt,name=Player,proto3" json:"Player,omitempty"` //房间内的玩家信息
|
|
||||||
PlayerInfo string `protobuf:"bytes,11,opt,name=PlayerInfo,proto3" json:"PlayerInfo,omitempty"`
|
|
||||||
}
|
|
||||||
|
|
||||||
func (x *SCFortuneSnakeRoomInfo) Reset() {
|
|
||||||
*x = SCFortuneSnakeRoomInfo{}
|
|
||||||
if protoimpl.UnsafeEnabled {
|
|
||||||
mi := &file_protocol_fortunesnake_fortunesnake_proto_msgTypes[1]
|
|
||||||
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
|
||||||
ms.StoreMessageInfo(mi)
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
func (x *SCFortuneSnakeRoomInfo) String() string {
|
|
||||||
return protoimpl.X.MessageStringOf(x)
|
|
||||||
}
|
|
||||||
|
|
||||||
func (*SCFortuneSnakeRoomInfo) ProtoMessage() {}
|
|
||||||
|
|
||||||
func (x *SCFortuneSnakeRoomInfo) ProtoReflect() protoreflect.Message {
|
|
||||||
mi := &file_protocol_fortunesnake_fortunesnake_proto_msgTypes[1]
|
|
||||||
if protoimpl.UnsafeEnabled && x != nil {
|
|
||||||
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
|
||||||
if ms.LoadMessageInfo() == nil {
|
|
||||||
ms.StoreMessageInfo(mi)
|
|
||||||
}
|
|
||||||
return ms
|
|
||||||
}
|
|
||||||
return mi.MessageOf(x)
|
|
||||||
}
|
|
||||||
|
|
||||||
// Deprecated: Use SCFortuneSnakeRoomInfo.ProtoReflect.Descriptor instead.
|
|
||||||
func (*SCFortuneSnakeRoomInfo) Descriptor() ([]byte, []int) {
|
|
||||||
return file_protocol_fortunesnake_fortunesnake_proto_rawDescGZIP(), []int{1}
|
|
||||||
}
|
|
||||||
|
|
||||||
func (x *SCFortuneSnakeRoomInfo) GetRoomId() int32 {
|
|
||||||
if x != nil {
|
|
||||||
return x.RoomId
|
|
||||||
}
|
|
||||||
return 0
|
|
||||||
}
|
|
||||||
|
|
||||||
func (x *SCFortuneSnakeRoomInfo) GetGameFreeId() int32 {
|
|
||||||
if x != nil {
|
|
||||||
return x.GameFreeId
|
|
||||||
}
|
|
||||||
return 0
|
|
||||||
}
|
|
||||||
|
|
||||||
func (x *SCFortuneSnakeRoomInfo) GetGameId() int32 {
|
|
||||||
if x != nil {
|
|
||||||
return x.GameId
|
|
||||||
}
|
|
||||||
return 0
|
|
||||||
}
|
|
||||||
|
|
||||||
func (x *SCFortuneSnakeRoomInfo) GetRoomMode() int32 {
|
|
||||||
if x != nil {
|
|
||||||
return x.RoomMode
|
|
||||||
}
|
|
||||||
return 0
|
|
||||||
}
|
|
||||||
|
|
||||||
func (x *SCFortuneSnakeRoomInfo) GetParams() []int32 {
|
|
||||||
if x != nil {
|
|
||||||
return x.Params
|
|
||||||
}
|
|
||||||
return nil
|
|
||||||
}
|
|
||||||
|
|
||||||
func (x *SCFortuneSnakeRoomInfo) GetNumOfGames() int32 {
|
|
||||||
if x != nil {
|
|
||||||
return x.NumOfGames
|
|
||||||
}
|
|
||||||
return 0
|
|
||||||
}
|
|
||||||
|
|
||||||
func (x *SCFortuneSnakeRoomInfo) GetState() int32 {
|
|
||||||
if x != nil {
|
|
||||||
return x.State
|
|
||||||
}
|
|
||||||
return 0
|
|
||||||
}
|
|
||||||
|
|
||||||
func (x *SCFortuneSnakeRoomInfo) GetParamsEx() []int64 {
|
|
||||||
if x != nil {
|
|
||||||
return x.ParamsEx
|
|
||||||
}
|
|
||||||
return nil
|
|
||||||
}
|
|
||||||
|
|
||||||
func (x *SCFortuneSnakeRoomInfo) GetSceneType() int32 {
|
|
||||||
if x != nil {
|
|
||||||
return x.SceneType
|
|
||||||
}
|
|
||||||
return 0
|
|
||||||
}
|
|
||||||
|
|
||||||
func (x *SCFortuneSnakeRoomInfo) GetPlayer() *FortuneSnakePlayerData {
|
|
||||||
if x != nil {
|
|
||||||
return x.Player
|
|
||||||
}
|
|
||||||
return nil
|
|
||||||
}
|
|
||||||
|
|
||||||
func (x *SCFortuneSnakeRoomInfo) GetPlayerInfo() string {
|
|
||||||
if x != nil {
|
|
||||||
return x.PlayerInfo
|
|
||||||
}
|
|
||||||
return ""
|
|
||||||
}
|
|
||||||
|
|
||||||
//玩家操作
|
|
||||||
//PACKET_FORTUNESNAKE_CSFORTUNESNAKEOP
|
|
||||||
type CSFortuneSnakeOp struct {
|
|
||||||
state protoimpl.MessageState
|
|
||||||
sizeCache protoimpl.SizeCache
|
|
||||||
unknownFields protoimpl.UnknownFields
|
|
||||||
|
|
||||||
OpCode int32 `protobuf:"varint,1,opt,name=OpCode,proto3" json:"OpCode,omitempty"` //操作码 0.spin
|
|
||||||
Params []int64 `protobuf:"varint,2,rep,packed,name=Params,proto3" json:"Params,omitempty"` //操作参数 下注索引编号
|
|
||||||
}
|
|
||||||
|
|
||||||
func (x *CSFortuneSnakeOp) Reset() {
|
|
||||||
*x = CSFortuneSnakeOp{}
|
|
||||||
if protoimpl.UnsafeEnabled {
|
|
||||||
mi := &file_protocol_fortunesnake_fortunesnake_proto_msgTypes[2]
|
|
||||||
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
|
||||||
ms.StoreMessageInfo(mi)
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
func (x *CSFortuneSnakeOp) String() string {
|
|
||||||
return protoimpl.X.MessageStringOf(x)
|
|
||||||
}
|
|
||||||
|
|
||||||
func (*CSFortuneSnakeOp) ProtoMessage() {}
|
|
||||||
|
|
||||||
func (x *CSFortuneSnakeOp) ProtoReflect() protoreflect.Message {
|
|
||||||
mi := &file_protocol_fortunesnake_fortunesnake_proto_msgTypes[2]
|
|
||||||
if protoimpl.UnsafeEnabled && x != nil {
|
|
||||||
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
|
||||||
if ms.LoadMessageInfo() == nil {
|
|
||||||
ms.StoreMessageInfo(mi)
|
|
||||||
}
|
|
||||||
return ms
|
|
||||||
}
|
|
||||||
return mi.MessageOf(x)
|
|
||||||
}
|
|
||||||
|
|
||||||
// Deprecated: Use CSFortuneSnakeOp.ProtoReflect.Descriptor instead.
|
|
||||||
func (*CSFortuneSnakeOp) Descriptor() ([]byte, []int) {
|
|
||||||
return file_protocol_fortunesnake_fortunesnake_proto_rawDescGZIP(), []int{2}
|
|
||||||
}
|
|
||||||
|
|
||||||
func (x *CSFortuneSnakeOp) GetOpCode() int32 {
|
|
||||||
if x != nil {
|
|
||||||
return x.OpCode
|
|
||||||
}
|
|
||||||
return 0
|
|
||||||
}
|
|
||||||
|
|
||||||
func (x *CSFortuneSnakeOp) GetParams() []int64 {
|
|
||||||
if x != nil {
|
|
||||||
return x.Params
|
|
||||||
}
|
|
||||||
return nil
|
|
||||||
}
|
|
||||||
|
|
||||||
//玩家操作返回
|
|
||||||
//PACKET_FORTUNESNAKE_SCFORTUNESNAKEOP
|
|
||||||
type SCFortuneSnakeOp struct {
|
|
||||||
state protoimpl.MessageState
|
|
||||||
sizeCache protoimpl.SizeCache
|
|
||||||
unknownFields protoimpl.UnknownFields
|
|
||||||
|
|
||||||
OpCode int32 `protobuf:"varint,1,opt,name=OpCode,proto3" json:"OpCode,omitempty"` //操作码
|
|
||||||
OpRetCode int32 `protobuf:"varint,2,opt,name=OpRetCode,proto3" json:"OpRetCode,omitempty"` //操作结果 1.金币不足 2.低于该值不能押注
|
|
||||||
Params []int64 `protobuf:"varint,3,rep,packed,name=Params,proto3" json:"Params,omitempty"` //操作参数
|
|
||||||
}
|
|
||||||
|
|
||||||
func (x *SCFortuneSnakeOp) Reset() {
|
|
||||||
*x = SCFortuneSnakeOp{}
|
|
||||||
if protoimpl.UnsafeEnabled {
|
|
||||||
mi := &file_protocol_fortunesnake_fortunesnake_proto_msgTypes[3]
|
|
||||||
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
|
||||||
ms.StoreMessageInfo(mi)
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
func (x *SCFortuneSnakeOp) String() string {
|
|
||||||
return protoimpl.X.MessageStringOf(x)
|
|
||||||
}
|
|
||||||
|
|
||||||
func (*SCFortuneSnakeOp) ProtoMessage() {}
|
|
||||||
|
|
||||||
func (x *SCFortuneSnakeOp) ProtoReflect() protoreflect.Message {
|
|
||||||
mi := &file_protocol_fortunesnake_fortunesnake_proto_msgTypes[3]
|
|
||||||
if protoimpl.UnsafeEnabled && x != nil {
|
|
||||||
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
|
||||||
if ms.LoadMessageInfo() == nil {
|
|
||||||
ms.StoreMessageInfo(mi)
|
|
||||||
}
|
|
||||||
return ms
|
|
||||||
}
|
|
||||||
return mi.MessageOf(x)
|
|
||||||
}
|
|
||||||
|
|
||||||
// Deprecated: Use SCFortuneSnakeOp.ProtoReflect.Descriptor instead.
|
|
||||||
func (*SCFortuneSnakeOp) Descriptor() ([]byte, []int) {
|
|
||||||
return file_protocol_fortunesnake_fortunesnake_proto_rawDescGZIP(), []int{3}
|
|
||||||
}
|
|
||||||
|
|
||||||
func (x *SCFortuneSnakeOp) GetOpCode() int32 {
|
|
||||||
if x != nil {
|
|
||||||
return x.OpCode
|
|
||||||
}
|
|
||||||
return 0
|
|
||||||
}
|
|
||||||
|
|
||||||
func (x *SCFortuneSnakeOp) GetOpRetCode() int32 {
|
|
||||||
if x != nil {
|
|
||||||
return x.OpRetCode
|
|
||||||
}
|
|
||||||
return 0
|
|
||||||
}
|
|
||||||
|
|
||||||
func (x *SCFortuneSnakeOp) GetParams() []int64 {
|
|
||||||
if x != nil {
|
|
||||||
return x.Params
|
|
||||||
}
|
|
||||||
return nil
|
|
||||||
}
|
|
||||||
|
|
||||||
//房间状态
|
|
||||||
//PACKET_FORTUNESNAKE_SCFORTUNESNAKEROOMSTATE
|
|
||||||
type SCFortuneSnakeRoomState struct {
|
|
||||||
state protoimpl.MessageState
|
|
||||||
sizeCache protoimpl.SizeCache
|
|
||||||
unknownFields protoimpl.UnknownFields
|
|
||||||
|
|
||||||
State int32 `protobuf:"varint,1,opt,name=State,proto3" json:"State,omitempty"` //房间当前状态
|
|
||||||
SubState int32 `protobuf:"varint,2,opt,name=SubState,proto3" json:"SubState,omitempty"` //房间当前子状态
|
|
||||||
Params []int32 `protobuf:"varint,3,rep,packed,name=Params,proto3" json:"Params,omitempty"` //状态参数
|
|
||||||
}
|
|
||||||
|
|
||||||
func (x *SCFortuneSnakeRoomState) Reset() {
|
|
||||||
*x = SCFortuneSnakeRoomState{}
|
|
||||||
if protoimpl.UnsafeEnabled {
|
|
||||||
mi := &file_protocol_fortunesnake_fortunesnake_proto_msgTypes[4]
|
|
||||||
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
|
||||||
ms.StoreMessageInfo(mi)
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
func (x *SCFortuneSnakeRoomState) String() string {
|
|
||||||
return protoimpl.X.MessageStringOf(x)
|
|
||||||
}
|
|
||||||
|
|
||||||
func (*SCFortuneSnakeRoomState) ProtoMessage() {}
|
|
||||||
|
|
||||||
func (x *SCFortuneSnakeRoomState) ProtoReflect() protoreflect.Message {
|
|
||||||
mi := &file_protocol_fortunesnake_fortunesnake_proto_msgTypes[4]
|
|
||||||
if protoimpl.UnsafeEnabled && x != nil {
|
|
||||||
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
|
||||||
if ms.LoadMessageInfo() == nil {
|
|
||||||
ms.StoreMessageInfo(mi)
|
|
||||||
}
|
|
||||||
return ms
|
|
||||||
}
|
|
||||||
return mi.MessageOf(x)
|
|
||||||
}
|
|
||||||
|
|
||||||
// Deprecated: Use SCFortuneSnakeRoomState.ProtoReflect.Descriptor instead.
|
|
||||||
func (*SCFortuneSnakeRoomState) Descriptor() ([]byte, []int) {
|
|
||||||
return file_protocol_fortunesnake_fortunesnake_proto_rawDescGZIP(), []int{4}
|
|
||||||
}
|
|
||||||
|
|
||||||
func (x *SCFortuneSnakeRoomState) GetState() int32 {
|
|
||||||
if x != nil {
|
|
||||||
return x.State
|
|
||||||
}
|
|
||||||
return 0
|
|
||||||
}
|
|
||||||
|
|
||||||
func (x *SCFortuneSnakeRoomState) GetSubState() int32 {
|
|
||||||
if x != nil {
|
|
||||||
return x.SubState
|
|
||||||
}
|
|
||||||
return 0
|
|
||||||
}
|
|
||||||
|
|
||||||
func (x *SCFortuneSnakeRoomState) GetParams() []int32 {
|
|
||||||
if x != nil {
|
|
||||||
return x.Params
|
|
||||||
}
|
|
||||||
return nil
|
|
||||||
}
|
|
||||||
|
|
||||||
//PACKET_FORTUNESNAKE_SCFORTUNESNAKEBILLED
|
|
||||||
type SCFortuneSnakeBilled struct {
|
|
||||||
state protoimpl.MessageState
|
|
||||||
sizeCache protoimpl.SizeCache
|
|
||||||
unknownFields protoimpl.UnknownFields
|
|
||||||
|
|
||||||
OpRetCode int32 `protobuf:"varint,1,opt,name=OpRetCode,proto3" json:"OpRetCode,omitempty"` //0.spin成功 1.spin失败
|
|
||||||
GameEndStr string `protobuf:"bytes,2,opt,name=GameEndStr,proto3" json:"GameEndStr,omitempty"`
|
|
||||||
}
|
|
||||||
|
|
||||||
func (x *SCFortuneSnakeBilled) Reset() {
|
|
||||||
*x = SCFortuneSnakeBilled{}
|
|
||||||
if protoimpl.UnsafeEnabled {
|
|
||||||
mi := &file_protocol_fortunesnake_fortunesnake_proto_msgTypes[5]
|
|
||||||
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
|
||||||
ms.StoreMessageInfo(mi)
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
func (x *SCFortuneSnakeBilled) String() string {
|
|
||||||
return protoimpl.X.MessageStringOf(x)
|
|
||||||
}
|
|
||||||
|
|
||||||
func (*SCFortuneSnakeBilled) ProtoMessage() {}
|
|
||||||
|
|
||||||
func (x *SCFortuneSnakeBilled) ProtoReflect() protoreflect.Message {
|
|
||||||
mi := &file_protocol_fortunesnake_fortunesnake_proto_msgTypes[5]
|
|
||||||
if protoimpl.UnsafeEnabled && x != nil {
|
|
||||||
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
|
||||||
if ms.LoadMessageInfo() == nil {
|
|
||||||
ms.StoreMessageInfo(mi)
|
|
||||||
}
|
|
||||||
return ms
|
|
||||||
}
|
|
||||||
return mi.MessageOf(x)
|
|
||||||
}
|
|
||||||
|
|
||||||
// Deprecated: Use SCFortuneSnakeBilled.ProtoReflect.Descriptor instead.
|
|
||||||
func (*SCFortuneSnakeBilled) Descriptor() ([]byte, []int) {
|
|
||||||
return file_protocol_fortunesnake_fortunesnake_proto_rawDescGZIP(), []int{5}
|
|
||||||
}
|
|
||||||
|
|
||||||
func (x *SCFortuneSnakeBilled) GetOpRetCode() int32 {
|
|
||||||
if x != nil {
|
|
||||||
return x.OpRetCode
|
|
||||||
}
|
|
||||||
return 0
|
|
||||||
}
|
|
||||||
|
|
||||||
func (x *SCFortuneSnakeBilled) GetGameEndStr() string {
|
|
||||||
if x != nil {
|
|
||||||
return x.GameEndStr
|
|
||||||
}
|
|
||||||
return ""
|
|
||||||
}
|
|
||||||
|
|
||||||
var File_protocol_fortunesnake_fortunesnake_proto protoreflect.FileDescriptor
|
|
||||||
|
|
||||||
var file_protocol_fortunesnake_fortunesnake_proto_rawDesc = []byte{
|
|
||||||
0x0a, 0x28, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x63, 0x6f, 0x6c, 0x2f, 0x66, 0x6f, 0x72, 0x74, 0x75,
|
|
||||||
0x6e, 0x65, 0x73, 0x6e, 0x61, 0x6b, 0x65, 0x2f, 0x66, 0x6f, 0x72, 0x74, 0x75, 0x6e, 0x65, 0x73,
|
|
||||||
0x6e, 0x61, 0x6b, 0x65, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x12, 0x0c, 0x66, 0x6f, 0x72, 0x74,
|
|
||||||
0x75, 0x6e, 0x65, 0x73, 0x6e, 0x61, 0x6b, 0x65, 0x22, 0x80, 0x02, 0x0a, 0x16, 0x46, 0x6f, 0x72,
|
|
||||||
0x74, 0x75, 0x6e, 0x65, 0x53, 0x6e, 0x61, 0x6b, 0x65, 0x50, 0x6c, 0x61, 0x79, 0x65, 0x72, 0x44,
|
|
||||||
0x61, 0x74, 0x61, 0x12, 0x12, 0x0a, 0x04, 0x4e, 0x61, 0x6d, 0x65, 0x18, 0x01, 0x20, 0x01, 0x28,
|
|
||||||
0x09, 0x52, 0x04, 0x4e, 0x61, 0x6d, 0x65, 0x12, 0x12, 0x0a, 0x04, 0x53, 0x6e, 0x49, 0x64, 0x18,
|
|
||||||
0x02, 0x20, 0x01, 0x28, 0x05, 0x52, 0x04, 0x53, 0x6e, 0x49, 0x64, 0x12, 0x12, 0x0a, 0x04, 0x48,
|
|
||||||
0x65, 0x61, 0x64, 0x18, 0x03, 0x20, 0x01, 0x28, 0x05, 0x52, 0x04, 0x48, 0x65, 0x61, 0x64, 0x12,
|
|
||||||
0x10, 0x0a, 0x03, 0x53, 0x65, 0x78, 0x18, 0x04, 0x20, 0x01, 0x28, 0x05, 0x52, 0x03, 0x53, 0x65,
|
|
||||||
0x78, 0x12, 0x12, 0x0a, 0x04, 0x43, 0x6f, 0x69, 0x6e, 0x18, 0x05, 0x20, 0x01, 0x28, 0x03, 0x52,
|
|
||||||
0x04, 0x43, 0x6f, 0x69, 0x6e, 0x12, 0x10, 0x0a, 0x03, 0x50, 0x6f, 0x73, 0x18, 0x06, 0x20, 0x01,
|
|
||||||
0x28, 0x05, 0x52, 0x03, 0x50, 0x6f, 0x73, 0x12, 0x12, 0x0a, 0x04, 0x46, 0x6c, 0x61, 0x67, 0x18,
|
|
||||||
0x07, 0x20, 0x01, 0x28, 0x05, 0x52, 0x04, 0x46, 0x6c, 0x61, 0x67, 0x12, 0x16, 0x0a, 0x06, 0x50,
|
|
||||||
0x61, 0x72, 0x61, 0x6d, 0x73, 0x18, 0x08, 0x20, 0x03, 0x28, 0x09, 0x52, 0x06, 0x50, 0x61, 0x72,
|
|
||||||
0x61, 0x6d, 0x73, 0x12, 0x12, 0x0a, 0x04, 0x43, 0x69, 0x74, 0x79, 0x18, 0x09, 0x20, 0x01, 0x28,
|
|
||||||
0x09, 0x52, 0x04, 0x43, 0x69, 0x74, 0x79, 0x12, 0x20, 0x0a, 0x0b, 0x48, 0x65, 0x61, 0x64, 0x4f,
|
|
||||||
0x75, 0x74, 0x4c, 0x69, 0x6e, 0x65, 0x18, 0x0a, 0x20, 0x01, 0x28, 0x05, 0x52, 0x0b, 0x48, 0x65,
|
|
||||||
0x61, 0x64, 0x4f, 0x75, 0x74, 0x4c, 0x69, 0x6e, 0x65, 0x12, 0x10, 0x0a, 0x03, 0x56, 0x49, 0x50,
|
|
||||||
0x18, 0x0b, 0x20, 0x01, 0x28, 0x05, 0x52, 0x03, 0x56, 0x49, 0x50, 0x22, 0xea, 0x02, 0x0a, 0x16,
|
|
||||||
0x53, 0x43, 0x46, 0x6f, 0x72, 0x74, 0x75, 0x6e, 0x65, 0x53, 0x6e, 0x61, 0x6b, 0x65, 0x52, 0x6f,
|
|
||||||
0x6f, 0x6d, 0x49, 0x6e, 0x66, 0x6f, 0x12, 0x16, 0x0a, 0x06, 0x52, 0x6f, 0x6f, 0x6d, 0x49, 0x64,
|
|
||||||
0x18, 0x01, 0x20, 0x01, 0x28, 0x05, 0x52, 0x06, 0x52, 0x6f, 0x6f, 0x6d, 0x49, 0x64, 0x12, 0x1e,
|
|
||||||
0x0a, 0x0a, 0x47, 0x61, 0x6d, 0x65, 0x46, 0x72, 0x65, 0x65, 0x49, 0x64, 0x18, 0x02, 0x20, 0x01,
|
|
||||||
0x28, 0x05, 0x52, 0x0a, 0x47, 0x61, 0x6d, 0x65, 0x46, 0x72, 0x65, 0x65, 0x49, 0x64, 0x12, 0x16,
|
|
||||||
0x0a, 0x06, 0x47, 0x61, 0x6d, 0x65, 0x49, 0x64, 0x18, 0x03, 0x20, 0x01, 0x28, 0x05, 0x52, 0x06,
|
|
||||||
0x47, 0x61, 0x6d, 0x65, 0x49, 0x64, 0x12, 0x1a, 0x0a, 0x08, 0x52, 0x6f, 0x6f, 0x6d, 0x4d, 0x6f,
|
|
||||||
0x64, 0x65, 0x18, 0x04, 0x20, 0x01, 0x28, 0x05, 0x52, 0x08, 0x52, 0x6f, 0x6f, 0x6d, 0x4d, 0x6f,
|
|
||||||
0x64, 0x65, 0x12, 0x16, 0x0a, 0x06, 0x50, 0x61, 0x72, 0x61, 0x6d, 0x73, 0x18, 0x05, 0x20, 0x03,
|
|
||||||
0x28, 0x05, 0x52, 0x06, 0x50, 0x61, 0x72, 0x61, 0x6d, 0x73, 0x12, 0x1e, 0x0a, 0x0a, 0x4e, 0x75,
|
|
||||||
0x6d, 0x4f, 0x66, 0x47, 0x61, 0x6d, 0x65, 0x73, 0x18, 0x06, 0x20, 0x01, 0x28, 0x05, 0x52, 0x0a,
|
|
||||||
0x4e, 0x75, 0x6d, 0x4f, 0x66, 0x47, 0x61, 0x6d, 0x65, 0x73, 0x12, 0x14, 0x0a, 0x05, 0x53, 0x74,
|
|
||||||
0x61, 0x74, 0x65, 0x18, 0x07, 0x20, 0x01, 0x28, 0x05, 0x52, 0x05, 0x53, 0x74, 0x61, 0x74, 0x65,
|
|
||||||
0x12, 0x1a, 0x0a, 0x08, 0x50, 0x61, 0x72, 0x61, 0x6d, 0x73, 0x45, 0x78, 0x18, 0x08, 0x20, 0x03,
|
|
||||||
0x28, 0x03, 0x52, 0x08, 0x50, 0x61, 0x72, 0x61, 0x6d, 0x73, 0x45, 0x78, 0x12, 0x1c, 0x0a, 0x09,
|
|
||||||
0x53, 0x63, 0x65, 0x6e, 0x65, 0x54, 0x79, 0x70, 0x65, 0x18, 0x09, 0x20, 0x01, 0x28, 0x05, 0x52,
|
|
||||||
0x09, 0x53, 0x63, 0x65, 0x6e, 0x65, 0x54, 0x79, 0x70, 0x65, 0x12, 0x3c, 0x0a, 0x06, 0x50, 0x6c,
|
|
||||||
0x61, 0x79, 0x65, 0x72, 0x18, 0x0a, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x24, 0x2e, 0x66, 0x6f, 0x72,
|
|
||||||
0x74, 0x75, 0x6e, 0x65, 0x73, 0x6e, 0x61, 0x6b, 0x65, 0x2e, 0x46, 0x6f, 0x72, 0x74, 0x75, 0x6e,
|
|
||||||
0x65, 0x53, 0x6e, 0x61, 0x6b, 0x65, 0x50, 0x6c, 0x61, 0x79, 0x65, 0x72, 0x44, 0x61, 0x74, 0x61,
|
|
||||||
0x52, 0x06, 0x50, 0x6c, 0x61, 0x79, 0x65, 0x72, 0x12, 0x1e, 0x0a, 0x0a, 0x50, 0x6c, 0x61, 0x79,
|
|
||||||
0x65, 0x72, 0x49, 0x6e, 0x66, 0x6f, 0x18, 0x0b, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0a, 0x50, 0x6c,
|
|
||||||
0x61, 0x79, 0x65, 0x72, 0x49, 0x6e, 0x66, 0x6f, 0x22, 0x42, 0x0a, 0x10, 0x43, 0x53, 0x46, 0x6f,
|
|
||||||
0x72, 0x74, 0x75, 0x6e, 0x65, 0x53, 0x6e, 0x61, 0x6b, 0x65, 0x4f, 0x70, 0x12, 0x16, 0x0a, 0x06,
|
|
||||||
0x4f, 0x70, 0x43, 0x6f, 0x64, 0x65, 0x18, 0x01, 0x20, 0x01, 0x28, 0x05, 0x52, 0x06, 0x4f, 0x70,
|
|
||||||
0x43, 0x6f, 0x64, 0x65, 0x12, 0x16, 0x0a, 0x06, 0x50, 0x61, 0x72, 0x61, 0x6d, 0x73, 0x18, 0x02,
|
|
||||||
0x20, 0x03, 0x28, 0x03, 0x52, 0x06, 0x50, 0x61, 0x72, 0x61, 0x6d, 0x73, 0x22, 0x60, 0x0a, 0x10,
|
|
||||||
0x53, 0x43, 0x46, 0x6f, 0x72, 0x74, 0x75, 0x6e, 0x65, 0x53, 0x6e, 0x61, 0x6b, 0x65, 0x4f, 0x70,
|
|
||||||
0x12, 0x16, 0x0a, 0x06, 0x4f, 0x70, 0x43, 0x6f, 0x64, 0x65, 0x18, 0x01, 0x20, 0x01, 0x28, 0x05,
|
|
||||||
0x52, 0x06, 0x4f, 0x70, 0x43, 0x6f, 0x64, 0x65, 0x12, 0x1c, 0x0a, 0x09, 0x4f, 0x70, 0x52, 0x65,
|
|
||||||
0x74, 0x43, 0x6f, 0x64, 0x65, 0x18, 0x02, 0x20, 0x01, 0x28, 0x05, 0x52, 0x09, 0x4f, 0x70, 0x52,
|
|
||||||
0x65, 0x74, 0x43, 0x6f, 0x64, 0x65, 0x12, 0x16, 0x0a, 0x06, 0x50, 0x61, 0x72, 0x61, 0x6d, 0x73,
|
|
||||||
0x18, 0x03, 0x20, 0x03, 0x28, 0x03, 0x52, 0x06, 0x50, 0x61, 0x72, 0x61, 0x6d, 0x73, 0x22, 0x63,
|
|
||||||
0x0a, 0x17, 0x53, 0x43, 0x46, 0x6f, 0x72, 0x74, 0x75, 0x6e, 0x65, 0x53, 0x6e, 0x61, 0x6b, 0x65,
|
|
||||||
0x52, 0x6f, 0x6f, 0x6d, 0x53, 0x74, 0x61, 0x74, 0x65, 0x12, 0x14, 0x0a, 0x05, 0x53, 0x74, 0x61,
|
|
||||||
0x74, 0x65, 0x18, 0x01, 0x20, 0x01, 0x28, 0x05, 0x52, 0x05, 0x53, 0x74, 0x61, 0x74, 0x65, 0x12,
|
|
||||||
0x1a, 0x0a, 0x08, 0x53, 0x75, 0x62, 0x53, 0x74, 0x61, 0x74, 0x65, 0x18, 0x02, 0x20, 0x01, 0x28,
|
|
||||||
0x05, 0x52, 0x08, 0x53, 0x75, 0x62, 0x53, 0x74, 0x61, 0x74, 0x65, 0x12, 0x16, 0x0a, 0x06, 0x50,
|
|
||||||
0x61, 0x72, 0x61, 0x6d, 0x73, 0x18, 0x03, 0x20, 0x03, 0x28, 0x05, 0x52, 0x06, 0x50, 0x61, 0x72,
|
|
||||||
0x61, 0x6d, 0x73, 0x22, 0x54, 0x0a, 0x14, 0x53, 0x43, 0x46, 0x6f, 0x72, 0x74, 0x75, 0x6e, 0x65,
|
|
||||||
0x53, 0x6e, 0x61, 0x6b, 0x65, 0x42, 0x69, 0x6c, 0x6c, 0x65, 0x64, 0x12, 0x1c, 0x0a, 0x09, 0x4f,
|
|
||||||
0x70, 0x52, 0x65, 0x74, 0x43, 0x6f, 0x64, 0x65, 0x18, 0x01, 0x20, 0x01, 0x28, 0x05, 0x52, 0x09,
|
|
||||||
0x4f, 0x70, 0x52, 0x65, 0x74, 0x43, 0x6f, 0x64, 0x65, 0x12, 0x1e, 0x0a, 0x0a, 0x47, 0x61, 0x6d,
|
|
||||||
0x65, 0x45, 0x6e, 0x64, 0x53, 0x74, 0x72, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0a, 0x47,
|
|
||||||
0x61, 0x6d, 0x65, 0x45, 0x6e, 0x64, 0x53, 0x74, 0x72, 0x2a, 0x97, 0x02, 0x0a, 0x0f, 0x46, 0x6f,
|
|
||||||
0x72, 0x74, 0x75, 0x6e, 0x65, 0x53, 0x6e, 0x61, 0x6b, 0x65, 0x50, 0x49, 0x44, 0x12, 0x1c, 0x0a,
|
|
||||||
0x18, 0x50, 0x41, 0x43, 0x4b, 0x45, 0x54, 0x5f, 0x46, 0x4f, 0x52, 0x54, 0x55, 0x4e, 0x45, 0x53,
|
|
||||||
0x4e, 0x41, 0x4b, 0x45, 0x5f, 0x5a, 0x45, 0x52, 0x4f, 0x10, 0x00, 0x12, 0x2f, 0x0a, 0x2a, 0x50,
|
|
||||||
0x41, 0x43, 0x4b, 0x45, 0x54, 0x5f, 0x46, 0x4f, 0x52, 0x54, 0x55, 0x4e, 0x45, 0x53, 0x4e, 0x41,
|
|
||||||
0x4b, 0x45, 0x5f, 0x53, 0x43, 0x46, 0x4f, 0x52, 0x54, 0x55, 0x4e, 0x45, 0x53, 0x4e, 0x41, 0x4b,
|
|
||||||
0x45, 0x52, 0x4f, 0x4f, 0x4d, 0x49, 0x4e, 0x46, 0x4f, 0x10, 0xb0, 0x2c, 0x12, 0x29, 0x0a, 0x24,
|
|
||||||
0x50, 0x41, 0x43, 0x4b, 0x45, 0x54, 0x5f, 0x46, 0x4f, 0x52, 0x54, 0x55, 0x4e, 0x45, 0x53, 0x4e,
|
|
||||||
0x41, 0x4b, 0x45, 0x5f, 0x43, 0x53, 0x46, 0x4f, 0x52, 0x54, 0x55, 0x4e, 0x45, 0x53, 0x4e, 0x41,
|
|
||||||
0x4b, 0x45, 0x4f, 0x50, 0x10, 0xb1, 0x2c, 0x12, 0x29, 0x0a, 0x24, 0x50, 0x41, 0x43, 0x4b, 0x45,
|
|
||||||
0x54, 0x5f, 0x46, 0x4f, 0x52, 0x54, 0x55, 0x4e, 0x45, 0x53, 0x4e, 0x41, 0x4b, 0x45, 0x5f, 0x53,
|
|
||||||
0x43, 0x46, 0x4f, 0x52, 0x54, 0x55, 0x4e, 0x45, 0x53, 0x4e, 0x41, 0x4b, 0x45, 0x4f, 0x50, 0x10,
|
|
||||||
0xb2, 0x2c, 0x12, 0x30, 0x0a, 0x2b, 0x50, 0x41, 0x43, 0x4b, 0x45, 0x54, 0x5f, 0x46, 0x4f, 0x52,
|
|
||||||
0x54, 0x55, 0x4e, 0x45, 0x53, 0x4e, 0x41, 0x4b, 0x45, 0x5f, 0x53, 0x43, 0x46, 0x4f, 0x52, 0x54,
|
|
||||||
0x55, 0x4e, 0x45, 0x53, 0x4e, 0x41, 0x4b, 0x45, 0x52, 0x4f, 0x4f, 0x4d, 0x53, 0x54, 0x41, 0x54,
|
|
||||||
0x45, 0x10, 0xb3, 0x2c, 0x12, 0x2d, 0x0a, 0x28, 0x50, 0x41, 0x43, 0x4b, 0x45, 0x54, 0x5f, 0x46,
|
|
||||||
0x4f, 0x52, 0x54, 0x55, 0x4e, 0x45, 0x53, 0x4e, 0x41, 0x4b, 0x45, 0x5f, 0x53, 0x43, 0x46, 0x4f,
|
|
||||||
0x52, 0x54, 0x55, 0x4e, 0x45, 0x53, 0x4e, 0x41, 0x4b, 0x45, 0x42, 0x49, 0x4c, 0x4c, 0x45, 0x44,
|
|
||||||
0x10, 0xb4, 0x2c, 0x42, 0x2c, 0x5a, 0x2a, 0x6d, 0x6f, 0x6e, 0x67, 0x6f, 0x2e, 0x67, 0x61, 0x6d,
|
|
||||||
0x65, 0x73, 0x2e, 0x63, 0x6f, 0x6d, 0x2f, 0x67, 0x61, 0x6d, 0x65, 0x2f, 0x70, 0x72, 0x6f, 0x74,
|
|
||||||
0x6f, 0x63, 0x6f, 0x6c, 0x2f, 0x66, 0x6f, 0x72, 0x74, 0x75, 0x6e, 0x65, 0x73, 0x6e, 0x61, 0x6b,
|
|
||||||
0x65, 0x62, 0x06, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x33,
|
|
||||||
}
|
|
||||||
|
|
||||||
var (
|
|
||||||
file_protocol_fortunesnake_fortunesnake_proto_rawDescOnce sync.Once
|
|
||||||
file_protocol_fortunesnake_fortunesnake_proto_rawDescData = file_protocol_fortunesnake_fortunesnake_proto_rawDesc
|
|
||||||
)
|
|
||||||
|
|
||||||
func file_protocol_fortunesnake_fortunesnake_proto_rawDescGZIP() []byte {
|
|
||||||
file_protocol_fortunesnake_fortunesnake_proto_rawDescOnce.Do(func() {
|
|
||||||
file_protocol_fortunesnake_fortunesnake_proto_rawDescData = protoimpl.X.CompressGZIP(file_protocol_fortunesnake_fortunesnake_proto_rawDescData)
|
|
||||||
})
|
|
||||||
return file_protocol_fortunesnake_fortunesnake_proto_rawDescData
|
|
||||||
}
|
|
||||||
|
|
||||||
var file_protocol_fortunesnake_fortunesnake_proto_enumTypes = make([]protoimpl.EnumInfo, 1)
|
|
||||||
var file_protocol_fortunesnake_fortunesnake_proto_msgTypes = make([]protoimpl.MessageInfo, 6)
|
|
||||||
var file_protocol_fortunesnake_fortunesnake_proto_goTypes = []interface{}{
|
|
||||||
(FortuneSnakePID)(0), // 0: fortunesnake.FortuneSnakePID
|
|
||||||
(*FortuneSnakePlayerData)(nil), // 1: fortunesnake.FortuneSnakePlayerData
|
|
||||||
(*SCFortuneSnakeRoomInfo)(nil), // 2: fortunesnake.SCFortuneSnakeRoomInfo
|
|
||||||
(*CSFortuneSnakeOp)(nil), // 3: fortunesnake.CSFortuneSnakeOp
|
|
||||||
(*SCFortuneSnakeOp)(nil), // 4: fortunesnake.SCFortuneSnakeOp
|
|
||||||
(*SCFortuneSnakeRoomState)(nil), // 5: fortunesnake.SCFortuneSnakeRoomState
|
|
||||||
(*SCFortuneSnakeBilled)(nil), // 6: fortunesnake.SCFortuneSnakeBilled
|
|
||||||
}
|
|
||||||
var file_protocol_fortunesnake_fortunesnake_proto_depIdxs = []int32{
|
|
||||||
1, // 0: fortunesnake.SCFortuneSnakeRoomInfo.Player:type_name -> fortunesnake.FortuneSnakePlayerData
|
|
||||||
1, // [1:1] is the sub-list for method output_type
|
|
||||||
1, // [1:1] is the sub-list for method input_type
|
|
||||||
1, // [1:1] is the sub-list for extension type_name
|
|
||||||
1, // [1:1] is the sub-list for extension extendee
|
|
||||||
0, // [0:1] is the sub-list for field type_name
|
|
||||||
}
|
|
||||||
|
|
||||||
func init() { file_protocol_fortunesnake_fortunesnake_proto_init() }
|
|
||||||
func file_protocol_fortunesnake_fortunesnake_proto_init() {
|
|
||||||
if File_protocol_fortunesnake_fortunesnake_proto != nil {
|
|
||||||
return
|
|
||||||
}
|
|
||||||
if !protoimpl.UnsafeEnabled {
|
|
||||||
file_protocol_fortunesnake_fortunesnake_proto_msgTypes[0].Exporter = func(v interface{}, i int) interface{} {
|
|
||||||
switch v := v.(*FortuneSnakePlayerData); i {
|
|
||||||
case 0:
|
|
||||||
return &v.state
|
|
||||||
case 1:
|
|
||||||
return &v.sizeCache
|
|
||||||
case 2:
|
|
||||||
return &v.unknownFields
|
|
||||||
default:
|
|
||||||
return nil
|
|
||||||
}
|
|
||||||
}
|
|
||||||
file_protocol_fortunesnake_fortunesnake_proto_msgTypes[1].Exporter = func(v interface{}, i int) interface{} {
|
|
||||||
switch v := v.(*SCFortuneSnakeRoomInfo); i {
|
|
||||||
case 0:
|
|
||||||
return &v.state
|
|
||||||
case 1:
|
|
||||||
return &v.sizeCache
|
|
||||||
case 2:
|
|
||||||
return &v.unknownFields
|
|
||||||
default:
|
|
||||||
return nil
|
|
||||||
}
|
|
||||||
}
|
|
||||||
file_protocol_fortunesnake_fortunesnake_proto_msgTypes[2].Exporter = func(v interface{}, i int) interface{} {
|
|
||||||
switch v := v.(*CSFortuneSnakeOp); i {
|
|
||||||
case 0:
|
|
||||||
return &v.state
|
|
||||||
case 1:
|
|
||||||
return &v.sizeCache
|
|
||||||
case 2:
|
|
||||||
return &v.unknownFields
|
|
||||||
default:
|
|
||||||
return nil
|
|
||||||
}
|
|
||||||
}
|
|
||||||
file_protocol_fortunesnake_fortunesnake_proto_msgTypes[3].Exporter = func(v interface{}, i int) interface{} {
|
|
||||||
switch v := v.(*SCFortuneSnakeOp); i {
|
|
||||||
case 0:
|
|
||||||
return &v.state
|
|
||||||
case 1:
|
|
||||||
return &v.sizeCache
|
|
||||||
case 2:
|
|
||||||
return &v.unknownFields
|
|
||||||
default:
|
|
||||||
return nil
|
|
||||||
}
|
|
||||||
}
|
|
||||||
file_protocol_fortunesnake_fortunesnake_proto_msgTypes[4].Exporter = func(v interface{}, i int) interface{} {
|
|
||||||
switch v := v.(*SCFortuneSnakeRoomState); i {
|
|
||||||
case 0:
|
|
||||||
return &v.state
|
|
||||||
case 1:
|
|
||||||
return &v.sizeCache
|
|
||||||
case 2:
|
|
||||||
return &v.unknownFields
|
|
||||||
default:
|
|
||||||
return nil
|
|
||||||
}
|
|
||||||
}
|
|
||||||
file_protocol_fortunesnake_fortunesnake_proto_msgTypes[5].Exporter = func(v interface{}, i int) interface{} {
|
|
||||||
switch v := v.(*SCFortuneSnakeBilled); i {
|
|
||||||
case 0:
|
|
||||||
return &v.state
|
|
||||||
case 1:
|
|
||||||
return &v.sizeCache
|
|
||||||
case 2:
|
|
||||||
return &v.unknownFields
|
|
||||||
default:
|
|
||||||
return nil
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
type x struct{}
|
|
||||||
out := protoimpl.TypeBuilder{
|
|
||||||
File: protoimpl.DescBuilder{
|
|
||||||
GoPackagePath: reflect.TypeOf(x{}).PkgPath(),
|
|
||||||
RawDescriptor: file_protocol_fortunesnake_fortunesnake_proto_rawDesc,
|
|
||||||
NumEnums: 1,
|
|
||||||
NumMessages: 6,
|
|
||||||
NumExtensions: 0,
|
|
||||||
NumServices: 0,
|
|
||||||
},
|
|
||||||
GoTypes: file_protocol_fortunesnake_fortunesnake_proto_goTypes,
|
|
||||||
DependencyIndexes: file_protocol_fortunesnake_fortunesnake_proto_depIdxs,
|
|
||||||
EnumInfos: file_protocol_fortunesnake_fortunesnake_proto_enumTypes,
|
|
||||||
MessageInfos: file_protocol_fortunesnake_fortunesnake_proto_msgTypes,
|
|
||||||
}.Build()
|
|
||||||
File_protocol_fortunesnake_fortunesnake_proto = out.File
|
|
||||||
file_protocol_fortunesnake_fortunesnake_proto_rawDesc = nil
|
|
||||||
file_protocol_fortunesnake_fortunesnake_proto_goTypes = nil
|
|
||||||
file_protocol_fortunesnake_fortunesnake_proto_depIdxs = nil
|
|
||||||
}
|
|
||||||
|
|
@ -1,68 +0,0 @@
|
||||||
syntax = "proto3";
|
|
||||||
package fortunesnake;
|
|
||||||
option go_package = "mongo.games.com/game/protocol/fortunesnake";
|
|
||||||
|
|
||||||
//fortunesnake
|
|
||||||
//龙
|
|
||||||
enum FortuneSnakePID {
|
|
||||||
PACKET_FORTUNESNAKE_ZERO = 0;// 弃用消息号
|
|
||||||
PACKET_FORTUNESNAKE_SCFORTUNESNAKEROOMINFO = 5680; //房间信息
|
|
||||||
PACKET_FORTUNESNAKE_CSFORTUNESNAKEOP = 5681;
|
|
||||||
PACKET_FORTUNESNAKE_SCFORTUNESNAKEOP = 5682;
|
|
||||||
PACKET_FORTUNESNAKE_SCFORTUNESNAKEROOMSTATE = 5683;
|
|
||||||
PACKET_FORTUNESNAKE_SCFORTUNESNAKEBILLED = 5684;
|
|
||||||
}
|
|
||||||
|
|
||||||
message FortuneSnakePlayerData {
|
|
||||||
string Name = 1; //名字
|
|
||||||
int32 SnId = 2; //账号
|
|
||||||
int32 Head = 3; //头像
|
|
||||||
int32 Sex = 4; //性别
|
|
||||||
int64 Coin = 5; //金币
|
|
||||||
int32 Pos = 6; //座位位置
|
|
||||||
int32 Flag = 7; //二进制标记
|
|
||||||
repeated string Params = 8; //其他数据 如:ip 等
|
|
||||||
string City = 9; //城市
|
|
||||||
int32 HeadOutLine = 10; //头像框
|
|
||||||
int32 VIP = 11;
|
|
||||||
}
|
|
||||||
//房间信息
|
|
||||||
//PACKET_FORTUNESNAKE_SCFORTUNESNAKEROOMINFO
|
|
||||||
message SCFortuneSnakeRoomInfo {
|
|
||||||
int32 RoomId = 1; //房间id
|
|
||||||
int32 GameFreeId = 2;
|
|
||||||
int32 GameId = 3; //游戏id
|
|
||||||
int32 RoomMode = 4; //游戏模式
|
|
||||||
repeated int32 Params = 5; //规则参数
|
|
||||||
int32 NumOfGames = 6; //当前第几局
|
|
||||||
int32 State = 7; //房间当前状态
|
|
||||||
repeated int64 ParamsEx = 8; //其他参数
|
|
||||||
int32 SceneType = 9; //房间模式
|
|
||||||
FortuneSnakePlayerData Player = 10; //房间内的玩家信息
|
|
||||||
string PlayerInfo = 11;
|
|
||||||
}
|
|
||||||
//玩家操作
|
|
||||||
//PACKET_FORTUNESNAKE_CSFORTUNESNAKEOP
|
|
||||||
message CSFortuneSnakeOp {
|
|
||||||
int32 OpCode = 1; //操作码 0.spin
|
|
||||||
repeated int64 Params = 2; //操作参数 下注索引编号
|
|
||||||
}
|
|
||||||
//玩家操作返回
|
|
||||||
//PACKET_FORTUNESNAKE_SCFORTUNESNAKEOP
|
|
||||||
message SCFortuneSnakeOp {
|
|
||||||
int32 OpCode = 1; //操作码
|
|
||||||
int32 OpRetCode = 2; //操作结果 1.金币不足 2.低于该值不能押注
|
|
||||||
repeated int64 Params = 3; //操作参数
|
|
||||||
}
|
|
||||||
//房间状态
|
|
||||||
//PACKET_FORTUNESNAKE_SCFORTUNESNAKEROOMSTATE
|
|
||||||
message SCFortuneSnakeRoomState {
|
|
||||||
int32 State = 1; //房间当前状态
|
|
||||||
int32 SubState = 2; //房间当前子状态
|
|
||||||
repeated int32 Params = 3; //状态参数
|
|
||||||
}
|
|
||||||
//PACKET_FORTUNESNAKE_SCFORTUNESNAKEBILLED
|
|
||||||
message SCFortuneSnakeBilled{
|
|
||||||
int32 OpRetCode = 1;//0.spin成功 1.spin失败
|
|
||||||
string GameEndStr = 2;
|
|
||||||
}
|
|
||||||
|
|
@ -1,802 +0,0 @@
|
||||||
// Code generated by protoc-gen-go. DO NOT EDIT.
|
|
||||||
// versions:
|
|
||||||
// protoc-gen-go v1.27.1-devel
|
|
||||||
// protoc v3.19.4
|
|
||||||
// source: protocol/ganeshagold/ganeshagold.proto
|
|
||||||
|
|
||||||
package ganeshagold
|
|
||||||
|
|
||||||
import (
|
|
||||||
protoreflect "google.golang.org/protobuf/reflect/protoreflect"
|
|
||||||
protoimpl "google.golang.org/protobuf/runtime/protoimpl"
|
|
||||||
reflect "reflect"
|
|
||||||
sync "sync"
|
|
||||||
)
|
|
||||||
|
|
||||||
const (
|
|
||||||
// Verify that this generated code is sufficiently up-to-date.
|
|
||||||
_ = protoimpl.EnforceVersion(20 - protoimpl.MinVersion)
|
|
||||||
// Verify that runtime/protoimpl is sufficiently up-to-date.
|
|
||||||
_ = protoimpl.EnforceVersion(protoimpl.MaxVersion - 20)
|
|
||||||
)
|
|
||||||
|
|
||||||
//ganeshagold
|
|
||||||
//龙
|
|
||||||
type GaneshaGoldPID int32
|
|
||||||
|
|
||||||
const (
|
|
||||||
GaneshaGoldPID_PACKET_GANESHAGOLD_ZERO GaneshaGoldPID = 0 // 弃用消息号
|
|
||||||
GaneshaGoldPID_PACKET_GANESHAGOLD_SCGANESHAGOLDROOMINFO GaneshaGoldPID = 5690 //房间信息
|
|
||||||
GaneshaGoldPID_PACKET_GANESHAGOLD_CSGANESHAGOLDOP GaneshaGoldPID = 5691
|
|
||||||
GaneshaGoldPID_PACKET_GANESHAGOLD_SCGANESHAGOLDOP GaneshaGoldPID = 5692
|
|
||||||
GaneshaGoldPID_PACKET_GANESHAGOLD_SCGANESHAGOLDROOMSTATE GaneshaGoldPID = 5693
|
|
||||||
GaneshaGoldPID_PACKET_GANESHAGOLD_SCGANESHAGOLDBILLED GaneshaGoldPID = 5694
|
|
||||||
)
|
|
||||||
|
|
||||||
// Enum value maps for GaneshaGoldPID.
|
|
||||||
var (
|
|
||||||
GaneshaGoldPID_name = map[int32]string{
|
|
||||||
0: "PACKET_GANESHAGOLD_ZERO",
|
|
||||||
5690: "PACKET_GANESHAGOLD_SCGANESHAGOLDROOMINFO",
|
|
||||||
5691: "PACKET_GANESHAGOLD_CSGANESHAGOLDOP",
|
|
||||||
5692: "PACKET_GANESHAGOLD_SCGANESHAGOLDOP",
|
|
||||||
5693: "PACKET_GANESHAGOLD_SCGANESHAGOLDROOMSTATE",
|
|
||||||
5694: "PACKET_GANESHAGOLD_SCGANESHAGOLDBILLED",
|
|
||||||
}
|
|
||||||
GaneshaGoldPID_value = map[string]int32{
|
|
||||||
"PACKET_GANESHAGOLD_ZERO": 0,
|
|
||||||
"PACKET_GANESHAGOLD_SCGANESHAGOLDROOMINFO": 5690,
|
|
||||||
"PACKET_GANESHAGOLD_CSGANESHAGOLDOP": 5691,
|
|
||||||
"PACKET_GANESHAGOLD_SCGANESHAGOLDOP": 5692,
|
|
||||||
"PACKET_GANESHAGOLD_SCGANESHAGOLDROOMSTATE": 5693,
|
|
||||||
"PACKET_GANESHAGOLD_SCGANESHAGOLDBILLED": 5694,
|
|
||||||
}
|
|
||||||
)
|
|
||||||
|
|
||||||
func (x GaneshaGoldPID) Enum() *GaneshaGoldPID {
|
|
||||||
p := new(GaneshaGoldPID)
|
|
||||||
*p = x
|
|
||||||
return p
|
|
||||||
}
|
|
||||||
|
|
||||||
func (x GaneshaGoldPID) String() string {
|
|
||||||
return protoimpl.X.EnumStringOf(x.Descriptor(), protoreflect.EnumNumber(x))
|
|
||||||
}
|
|
||||||
|
|
||||||
func (GaneshaGoldPID) Descriptor() protoreflect.EnumDescriptor {
|
|
||||||
return file_protocol_ganeshagold_ganeshagold_proto_enumTypes[0].Descriptor()
|
|
||||||
}
|
|
||||||
|
|
||||||
func (GaneshaGoldPID) Type() protoreflect.EnumType {
|
|
||||||
return &file_protocol_ganeshagold_ganeshagold_proto_enumTypes[0]
|
|
||||||
}
|
|
||||||
|
|
||||||
func (x GaneshaGoldPID) Number() protoreflect.EnumNumber {
|
|
||||||
return protoreflect.EnumNumber(x)
|
|
||||||
}
|
|
||||||
|
|
||||||
// Deprecated: Use GaneshaGoldPID.Descriptor instead.
|
|
||||||
func (GaneshaGoldPID) EnumDescriptor() ([]byte, []int) {
|
|
||||||
return file_protocol_ganeshagold_ganeshagold_proto_rawDescGZIP(), []int{0}
|
|
||||||
}
|
|
||||||
|
|
||||||
type GaneshaGoldPlayerData struct {
|
|
||||||
state protoimpl.MessageState
|
|
||||||
sizeCache protoimpl.SizeCache
|
|
||||||
unknownFields protoimpl.UnknownFields
|
|
||||||
|
|
||||||
Name string `protobuf:"bytes,1,opt,name=Name,proto3" json:"Name,omitempty"` //名字
|
|
||||||
SnId int32 `protobuf:"varint,2,opt,name=SnId,proto3" json:"SnId,omitempty"` //账号
|
|
||||||
Head int32 `protobuf:"varint,3,opt,name=Head,proto3" json:"Head,omitempty"` //头像
|
|
||||||
Sex int32 `protobuf:"varint,4,opt,name=Sex,proto3" json:"Sex,omitempty"` //性别
|
|
||||||
Coin int64 `protobuf:"varint,5,opt,name=Coin,proto3" json:"Coin,omitempty"` //金币
|
|
||||||
Pos int32 `protobuf:"varint,6,opt,name=Pos,proto3" json:"Pos,omitempty"` //座位位置
|
|
||||||
Flag int32 `protobuf:"varint,7,opt,name=Flag,proto3" json:"Flag,omitempty"` //二进制标记
|
|
||||||
Params []string `protobuf:"bytes,8,rep,name=Params,proto3" json:"Params,omitempty"` //其他数据 如:ip 等
|
|
||||||
City string `protobuf:"bytes,9,opt,name=City,proto3" json:"City,omitempty"` //城市
|
|
||||||
HeadOutLine int32 `protobuf:"varint,10,opt,name=HeadOutLine,proto3" json:"HeadOutLine,omitempty"` //头像框
|
|
||||||
VIP int32 `protobuf:"varint,11,opt,name=VIP,proto3" json:"VIP,omitempty"`
|
|
||||||
}
|
|
||||||
|
|
||||||
func (x *GaneshaGoldPlayerData) Reset() {
|
|
||||||
*x = GaneshaGoldPlayerData{}
|
|
||||||
if protoimpl.UnsafeEnabled {
|
|
||||||
mi := &file_protocol_ganeshagold_ganeshagold_proto_msgTypes[0]
|
|
||||||
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
|
||||||
ms.StoreMessageInfo(mi)
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
func (x *GaneshaGoldPlayerData) String() string {
|
|
||||||
return protoimpl.X.MessageStringOf(x)
|
|
||||||
}
|
|
||||||
|
|
||||||
func (*GaneshaGoldPlayerData) ProtoMessage() {}
|
|
||||||
|
|
||||||
func (x *GaneshaGoldPlayerData) ProtoReflect() protoreflect.Message {
|
|
||||||
mi := &file_protocol_ganeshagold_ganeshagold_proto_msgTypes[0]
|
|
||||||
if protoimpl.UnsafeEnabled && x != nil {
|
|
||||||
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
|
||||||
if ms.LoadMessageInfo() == nil {
|
|
||||||
ms.StoreMessageInfo(mi)
|
|
||||||
}
|
|
||||||
return ms
|
|
||||||
}
|
|
||||||
return mi.MessageOf(x)
|
|
||||||
}
|
|
||||||
|
|
||||||
// Deprecated: Use GaneshaGoldPlayerData.ProtoReflect.Descriptor instead.
|
|
||||||
func (*GaneshaGoldPlayerData) Descriptor() ([]byte, []int) {
|
|
||||||
return file_protocol_ganeshagold_ganeshagold_proto_rawDescGZIP(), []int{0}
|
|
||||||
}
|
|
||||||
|
|
||||||
func (x *GaneshaGoldPlayerData) GetName() string {
|
|
||||||
if x != nil {
|
|
||||||
return x.Name
|
|
||||||
}
|
|
||||||
return ""
|
|
||||||
}
|
|
||||||
|
|
||||||
func (x *GaneshaGoldPlayerData) GetSnId() int32 {
|
|
||||||
if x != nil {
|
|
||||||
return x.SnId
|
|
||||||
}
|
|
||||||
return 0
|
|
||||||
}
|
|
||||||
|
|
||||||
func (x *GaneshaGoldPlayerData) GetHead() int32 {
|
|
||||||
if x != nil {
|
|
||||||
return x.Head
|
|
||||||
}
|
|
||||||
return 0
|
|
||||||
}
|
|
||||||
|
|
||||||
func (x *GaneshaGoldPlayerData) GetSex() int32 {
|
|
||||||
if x != nil {
|
|
||||||
return x.Sex
|
|
||||||
}
|
|
||||||
return 0
|
|
||||||
}
|
|
||||||
|
|
||||||
func (x *GaneshaGoldPlayerData) GetCoin() int64 {
|
|
||||||
if x != nil {
|
|
||||||
return x.Coin
|
|
||||||
}
|
|
||||||
return 0
|
|
||||||
}
|
|
||||||
|
|
||||||
func (x *GaneshaGoldPlayerData) GetPos() int32 {
|
|
||||||
if x != nil {
|
|
||||||
return x.Pos
|
|
||||||
}
|
|
||||||
return 0
|
|
||||||
}
|
|
||||||
|
|
||||||
func (x *GaneshaGoldPlayerData) GetFlag() int32 {
|
|
||||||
if x != nil {
|
|
||||||
return x.Flag
|
|
||||||
}
|
|
||||||
return 0
|
|
||||||
}
|
|
||||||
|
|
||||||
func (x *GaneshaGoldPlayerData) GetParams() []string {
|
|
||||||
if x != nil {
|
|
||||||
return x.Params
|
|
||||||
}
|
|
||||||
return nil
|
|
||||||
}
|
|
||||||
|
|
||||||
func (x *GaneshaGoldPlayerData) GetCity() string {
|
|
||||||
if x != nil {
|
|
||||||
return x.City
|
|
||||||
}
|
|
||||||
return ""
|
|
||||||
}
|
|
||||||
|
|
||||||
func (x *GaneshaGoldPlayerData) GetHeadOutLine() int32 {
|
|
||||||
if x != nil {
|
|
||||||
return x.HeadOutLine
|
|
||||||
}
|
|
||||||
return 0
|
|
||||||
}
|
|
||||||
|
|
||||||
func (x *GaneshaGoldPlayerData) GetVIP() int32 {
|
|
||||||
if x != nil {
|
|
||||||
return x.VIP
|
|
||||||
}
|
|
||||||
return 0
|
|
||||||
}
|
|
||||||
|
|
||||||
//房间信息
|
|
||||||
//PACKET_GANESHAGOLD_SCGANESHAGOLDROOMINFO
|
|
||||||
type SCGaneshaGoldRoomInfo struct {
|
|
||||||
state protoimpl.MessageState
|
|
||||||
sizeCache protoimpl.SizeCache
|
|
||||||
unknownFields protoimpl.UnknownFields
|
|
||||||
|
|
||||||
RoomId int32 `protobuf:"varint,1,opt,name=RoomId,proto3" json:"RoomId,omitempty"` //房间id
|
|
||||||
GameFreeId int32 `protobuf:"varint,2,opt,name=GameFreeId,proto3" json:"GameFreeId,omitempty"`
|
|
||||||
GameId int32 `protobuf:"varint,3,opt,name=GameId,proto3" json:"GameId,omitempty"` //游戏id
|
|
||||||
RoomMode int32 `protobuf:"varint,4,opt,name=RoomMode,proto3" json:"RoomMode,omitempty"` //游戏模式
|
|
||||||
Params []int32 `protobuf:"varint,5,rep,packed,name=Params,proto3" json:"Params,omitempty"` //规则参数
|
|
||||||
NumOfGames int32 `protobuf:"varint,6,opt,name=NumOfGames,proto3" json:"NumOfGames,omitempty"` //当前第几局
|
|
||||||
State int32 `protobuf:"varint,7,opt,name=State,proto3" json:"State,omitempty"` //房间当前状态
|
|
||||||
ParamsEx []int64 `protobuf:"varint,8,rep,packed,name=ParamsEx,proto3" json:"ParamsEx,omitempty"` //其他参数
|
|
||||||
SceneType int32 `protobuf:"varint,9,opt,name=SceneType,proto3" json:"SceneType,omitempty"` //房间模式
|
|
||||||
Player *GaneshaGoldPlayerData `protobuf:"bytes,10,opt,name=Player,proto3" json:"Player,omitempty"` //房间内的玩家信息
|
|
||||||
PlayerInfo string `protobuf:"bytes,11,opt,name=PlayerInfo,proto3" json:"PlayerInfo,omitempty"`
|
|
||||||
}
|
|
||||||
|
|
||||||
func (x *SCGaneshaGoldRoomInfo) Reset() {
|
|
||||||
*x = SCGaneshaGoldRoomInfo{}
|
|
||||||
if protoimpl.UnsafeEnabled {
|
|
||||||
mi := &file_protocol_ganeshagold_ganeshagold_proto_msgTypes[1]
|
|
||||||
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
|
||||||
ms.StoreMessageInfo(mi)
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
func (x *SCGaneshaGoldRoomInfo) String() string {
|
|
||||||
return protoimpl.X.MessageStringOf(x)
|
|
||||||
}
|
|
||||||
|
|
||||||
func (*SCGaneshaGoldRoomInfo) ProtoMessage() {}
|
|
||||||
|
|
||||||
func (x *SCGaneshaGoldRoomInfo) ProtoReflect() protoreflect.Message {
|
|
||||||
mi := &file_protocol_ganeshagold_ganeshagold_proto_msgTypes[1]
|
|
||||||
if protoimpl.UnsafeEnabled && x != nil {
|
|
||||||
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
|
||||||
if ms.LoadMessageInfo() == nil {
|
|
||||||
ms.StoreMessageInfo(mi)
|
|
||||||
}
|
|
||||||
return ms
|
|
||||||
}
|
|
||||||
return mi.MessageOf(x)
|
|
||||||
}
|
|
||||||
|
|
||||||
// Deprecated: Use SCGaneshaGoldRoomInfo.ProtoReflect.Descriptor instead.
|
|
||||||
func (*SCGaneshaGoldRoomInfo) Descriptor() ([]byte, []int) {
|
|
||||||
return file_protocol_ganeshagold_ganeshagold_proto_rawDescGZIP(), []int{1}
|
|
||||||
}
|
|
||||||
|
|
||||||
func (x *SCGaneshaGoldRoomInfo) GetRoomId() int32 {
|
|
||||||
if x != nil {
|
|
||||||
return x.RoomId
|
|
||||||
}
|
|
||||||
return 0
|
|
||||||
}
|
|
||||||
|
|
||||||
func (x *SCGaneshaGoldRoomInfo) GetGameFreeId() int32 {
|
|
||||||
if x != nil {
|
|
||||||
return x.GameFreeId
|
|
||||||
}
|
|
||||||
return 0
|
|
||||||
}
|
|
||||||
|
|
||||||
func (x *SCGaneshaGoldRoomInfo) GetGameId() int32 {
|
|
||||||
if x != nil {
|
|
||||||
return x.GameId
|
|
||||||
}
|
|
||||||
return 0
|
|
||||||
}
|
|
||||||
|
|
||||||
func (x *SCGaneshaGoldRoomInfo) GetRoomMode() int32 {
|
|
||||||
if x != nil {
|
|
||||||
return x.RoomMode
|
|
||||||
}
|
|
||||||
return 0
|
|
||||||
}
|
|
||||||
|
|
||||||
func (x *SCGaneshaGoldRoomInfo) GetParams() []int32 {
|
|
||||||
if x != nil {
|
|
||||||
return x.Params
|
|
||||||
}
|
|
||||||
return nil
|
|
||||||
}
|
|
||||||
|
|
||||||
func (x *SCGaneshaGoldRoomInfo) GetNumOfGames() int32 {
|
|
||||||
if x != nil {
|
|
||||||
return x.NumOfGames
|
|
||||||
}
|
|
||||||
return 0
|
|
||||||
}
|
|
||||||
|
|
||||||
func (x *SCGaneshaGoldRoomInfo) GetState() int32 {
|
|
||||||
if x != nil {
|
|
||||||
return x.State
|
|
||||||
}
|
|
||||||
return 0
|
|
||||||
}
|
|
||||||
|
|
||||||
func (x *SCGaneshaGoldRoomInfo) GetParamsEx() []int64 {
|
|
||||||
if x != nil {
|
|
||||||
return x.ParamsEx
|
|
||||||
}
|
|
||||||
return nil
|
|
||||||
}
|
|
||||||
|
|
||||||
func (x *SCGaneshaGoldRoomInfo) GetSceneType() int32 {
|
|
||||||
if x != nil {
|
|
||||||
return x.SceneType
|
|
||||||
}
|
|
||||||
return 0
|
|
||||||
}
|
|
||||||
|
|
||||||
func (x *SCGaneshaGoldRoomInfo) GetPlayer() *GaneshaGoldPlayerData {
|
|
||||||
if x != nil {
|
|
||||||
return x.Player
|
|
||||||
}
|
|
||||||
return nil
|
|
||||||
}
|
|
||||||
|
|
||||||
func (x *SCGaneshaGoldRoomInfo) GetPlayerInfo() string {
|
|
||||||
if x != nil {
|
|
||||||
return x.PlayerInfo
|
|
||||||
}
|
|
||||||
return ""
|
|
||||||
}
|
|
||||||
|
|
||||||
//玩家操作
|
|
||||||
//PACKET_GANESHAGOLD_CSGANESHAGOLDOP
|
|
||||||
type CSGaneshaGoldOp struct {
|
|
||||||
state protoimpl.MessageState
|
|
||||||
sizeCache protoimpl.SizeCache
|
|
||||||
unknownFields protoimpl.UnknownFields
|
|
||||||
|
|
||||||
OpCode int32 `protobuf:"varint,1,opt,name=OpCode,proto3" json:"OpCode,omitempty"` //操作码 0.spin
|
|
||||||
Params []int64 `protobuf:"varint,2,rep,packed,name=Params,proto3" json:"Params,omitempty"` //操作参数 下注索引编号
|
|
||||||
}
|
|
||||||
|
|
||||||
func (x *CSGaneshaGoldOp) Reset() {
|
|
||||||
*x = CSGaneshaGoldOp{}
|
|
||||||
if protoimpl.UnsafeEnabled {
|
|
||||||
mi := &file_protocol_ganeshagold_ganeshagold_proto_msgTypes[2]
|
|
||||||
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
|
||||||
ms.StoreMessageInfo(mi)
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
func (x *CSGaneshaGoldOp) String() string {
|
|
||||||
return protoimpl.X.MessageStringOf(x)
|
|
||||||
}
|
|
||||||
|
|
||||||
func (*CSGaneshaGoldOp) ProtoMessage() {}
|
|
||||||
|
|
||||||
func (x *CSGaneshaGoldOp) ProtoReflect() protoreflect.Message {
|
|
||||||
mi := &file_protocol_ganeshagold_ganeshagold_proto_msgTypes[2]
|
|
||||||
if protoimpl.UnsafeEnabled && x != nil {
|
|
||||||
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
|
||||||
if ms.LoadMessageInfo() == nil {
|
|
||||||
ms.StoreMessageInfo(mi)
|
|
||||||
}
|
|
||||||
return ms
|
|
||||||
}
|
|
||||||
return mi.MessageOf(x)
|
|
||||||
}
|
|
||||||
|
|
||||||
// Deprecated: Use CSGaneshaGoldOp.ProtoReflect.Descriptor instead.
|
|
||||||
func (*CSGaneshaGoldOp) Descriptor() ([]byte, []int) {
|
|
||||||
return file_protocol_ganeshagold_ganeshagold_proto_rawDescGZIP(), []int{2}
|
|
||||||
}
|
|
||||||
|
|
||||||
func (x *CSGaneshaGoldOp) GetOpCode() int32 {
|
|
||||||
if x != nil {
|
|
||||||
return x.OpCode
|
|
||||||
}
|
|
||||||
return 0
|
|
||||||
}
|
|
||||||
|
|
||||||
func (x *CSGaneshaGoldOp) GetParams() []int64 {
|
|
||||||
if x != nil {
|
|
||||||
return x.Params
|
|
||||||
}
|
|
||||||
return nil
|
|
||||||
}
|
|
||||||
|
|
||||||
//玩家操作返回
|
|
||||||
//PACKET_GANESHAGOLD_SCGANESHAGOLDOP
|
|
||||||
type SCGaneshaGoldOp struct {
|
|
||||||
state protoimpl.MessageState
|
|
||||||
sizeCache protoimpl.SizeCache
|
|
||||||
unknownFields protoimpl.UnknownFields
|
|
||||||
|
|
||||||
OpCode int32 `protobuf:"varint,1,opt,name=OpCode,proto3" json:"OpCode,omitempty"` //操作码
|
|
||||||
OpRetCode int32 `protobuf:"varint,2,opt,name=OpRetCode,proto3" json:"OpRetCode,omitempty"` //操作结果 1.金币不足 2.低于该值不能押注
|
|
||||||
Params []int64 `protobuf:"varint,3,rep,packed,name=Params,proto3" json:"Params,omitempty"` //操作参数
|
|
||||||
}
|
|
||||||
|
|
||||||
func (x *SCGaneshaGoldOp) Reset() {
|
|
||||||
*x = SCGaneshaGoldOp{}
|
|
||||||
if protoimpl.UnsafeEnabled {
|
|
||||||
mi := &file_protocol_ganeshagold_ganeshagold_proto_msgTypes[3]
|
|
||||||
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
|
||||||
ms.StoreMessageInfo(mi)
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
func (x *SCGaneshaGoldOp) String() string {
|
|
||||||
return protoimpl.X.MessageStringOf(x)
|
|
||||||
}
|
|
||||||
|
|
||||||
func (*SCGaneshaGoldOp) ProtoMessage() {}
|
|
||||||
|
|
||||||
func (x *SCGaneshaGoldOp) ProtoReflect() protoreflect.Message {
|
|
||||||
mi := &file_protocol_ganeshagold_ganeshagold_proto_msgTypes[3]
|
|
||||||
if protoimpl.UnsafeEnabled && x != nil {
|
|
||||||
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
|
||||||
if ms.LoadMessageInfo() == nil {
|
|
||||||
ms.StoreMessageInfo(mi)
|
|
||||||
}
|
|
||||||
return ms
|
|
||||||
}
|
|
||||||
return mi.MessageOf(x)
|
|
||||||
}
|
|
||||||
|
|
||||||
// Deprecated: Use SCGaneshaGoldOp.ProtoReflect.Descriptor instead.
|
|
||||||
func (*SCGaneshaGoldOp) Descriptor() ([]byte, []int) {
|
|
||||||
return file_protocol_ganeshagold_ganeshagold_proto_rawDescGZIP(), []int{3}
|
|
||||||
}
|
|
||||||
|
|
||||||
func (x *SCGaneshaGoldOp) GetOpCode() int32 {
|
|
||||||
if x != nil {
|
|
||||||
return x.OpCode
|
|
||||||
}
|
|
||||||
return 0
|
|
||||||
}
|
|
||||||
|
|
||||||
func (x *SCGaneshaGoldOp) GetOpRetCode() int32 {
|
|
||||||
if x != nil {
|
|
||||||
return x.OpRetCode
|
|
||||||
}
|
|
||||||
return 0
|
|
||||||
}
|
|
||||||
|
|
||||||
func (x *SCGaneshaGoldOp) GetParams() []int64 {
|
|
||||||
if x != nil {
|
|
||||||
return x.Params
|
|
||||||
}
|
|
||||||
return nil
|
|
||||||
}
|
|
||||||
|
|
||||||
//房间状态
|
|
||||||
//PACKET_GANESHAGOLD_SCGANESHAGOLDROOMSTATE
|
|
||||||
type SCGaneshaGoldRoomState struct {
|
|
||||||
state protoimpl.MessageState
|
|
||||||
sizeCache protoimpl.SizeCache
|
|
||||||
unknownFields protoimpl.UnknownFields
|
|
||||||
|
|
||||||
State int32 `protobuf:"varint,1,opt,name=State,proto3" json:"State,omitempty"` //房间当前状态
|
|
||||||
SubState int32 `protobuf:"varint,2,opt,name=SubState,proto3" json:"SubState,omitempty"` //房间当前子状态
|
|
||||||
Params []int32 `protobuf:"varint,3,rep,packed,name=Params,proto3" json:"Params,omitempty"` //状态参数
|
|
||||||
}
|
|
||||||
|
|
||||||
func (x *SCGaneshaGoldRoomState) Reset() {
|
|
||||||
*x = SCGaneshaGoldRoomState{}
|
|
||||||
if protoimpl.UnsafeEnabled {
|
|
||||||
mi := &file_protocol_ganeshagold_ganeshagold_proto_msgTypes[4]
|
|
||||||
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
|
||||||
ms.StoreMessageInfo(mi)
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
func (x *SCGaneshaGoldRoomState) String() string {
|
|
||||||
return protoimpl.X.MessageStringOf(x)
|
|
||||||
}
|
|
||||||
|
|
||||||
func (*SCGaneshaGoldRoomState) ProtoMessage() {}
|
|
||||||
|
|
||||||
func (x *SCGaneshaGoldRoomState) ProtoReflect() protoreflect.Message {
|
|
||||||
mi := &file_protocol_ganeshagold_ganeshagold_proto_msgTypes[4]
|
|
||||||
if protoimpl.UnsafeEnabled && x != nil {
|
|
||||||
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
|
||||||
if ms.LoadMessageInfo() == nil {
|
|
||||||
ms.StoreMessageInfo(mi)
|
|
||||||
}
|
|
||||||
return ms
|
|
||||||
}
|
|
||||||
return mi.MessageOf(x)
|
|
||||||
}
|
|
||||||
|
|
||||||
// Deprecated: Use SCGaneshaGoldRoomState.ProtoReflect.Descriptor instead.
|
|
||||||
func (*SCGaneshaGoldRoomState) Descriptor() ([]byte, []int) {
|
|
||||||
return file_protocol_ganeshagold_ganeshagold_proto_rawDescGZIP(), []int{4}
|
|
||||||
}
|
|
||||||
|
|
||||||
func (x *SCGaneshaGoldRoomState) GetState() int32 {
|
|
||||||
if x != nil {
|
|
||||||
return x.State
|
|
||||||
}
|
|
||||||
return 0
|
|
||||||
}
|
|
||||||
|
|
||||||
func (x *SCGaneshaGoldRoomState) GetSubState() int32 {
|
|
||||||
if x != nil {
|
|
||||||
return x.SubState
|
|
||||||
}
|
|
||||||
return 0
|
|
||||||
}
|
|
||||||
|
|
||||||
func (x *SCGaneshaGoldRoomState) GetParams() []int32 {
|
|
||||||
if x != nil {
|
|
||||||
return x.Params
|
|
||||||
}
|
|
||||||
return nil
|
|
||||||
}
|
|
||||||
|
|
||||||
//PACKET_GANESHAGOLD_SCGANESHAGOLDBILLED
|
|
||||||
type SCGaneshaGoldBilled struct {
|
|
||||||
state protoimpl.MessageState
|
|
||||||
sizeCache protoimpl.SizeCache
|
|
||||||
unknownFields protoimpl.UnknownFields
|
|
||||||
|
|
||||||
OpRetCode int32 `protobuf:"varint,1,opt,name=OpRetCode,proto3" json:"OpRetCode,omitempty"` //0.spin成功 1.spin失败
|
|
||||||
GameEndStr string `protobuf:"bytes,2,opt,name=GameEndStr,proto3" json:"GameEndStr,omitempty"`
|
|
||||||
}
|
|
||||||
|
|
||||||
func (x *SCGaneshaGoldBilled) Reset() {
|
|
||||||
*x = SCGaneshaGoldBilled{}
|
|
||||||
if protoimpl.UnsafeEnabled {
|
|
||||||
mi := &file_protocol_ganeshagold_ganeshagold_proto_msgTypes[5]
|
|
||||||
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
|
||||||
ms.StoreMessageInfo(mi)
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
func (x *SCGaneshaGoldBilled) String() string {
|
|
||||||
return protoimpl.X.MessageStringOf(x)
|
|
||||||
}
|
|
||||||
|
|
||||||
func (*SCGaneshaGoldBilled) ProtoMessage() {}
|
|
||||||
|
|
||||||
func (x *SCGaneshaGoldBilled) ProtoReflect() protoreflect.Message {
|
|
||||||
mi := &file_protocol_ganeshagold_ganeshagold_proto_msgTypes[5]
|
|
||||||
if protoimpl.UnsafeEnabled && x != nil {
|
|
||||||
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
|
||||||
if ms.LoadMessageInfo() == nil {
|
|
||||||
ms.StoreMessageInfo(mi)
|
|
||||||
}
|
|
||||||
return ms
|
|
||||||
}
|
|
||||||
return mi.MessageOf(x)
|
|
||||||
}
|
|
||||||
|
|
||||||
// Deprecated: Use SCGaneshaGoldBilled.ProtoReflect.Descriptor instead.
|
|
||||||
func (*SCGaneshaGoldBilled) Descriptor() ([]byte, []int) {
|
|
||||||
return file_protocol_ganeshagold_ganeshagold_proto_rawDescGZIP(), []int{5}
|
|
||||||
}
|
|
||||||
|
|
||||||
func (x *SCGaneshaGoldBilled) GetOpRetCode() int32 {
|
|
||||||
if x != nil {
|
|
||||||
return x.OpRetCode
|
|
||||||
}
|
|
||||||
return 0
|
|
||||||
}
|
|
||||||
|
|
||||||
func (x *SCGaneshaGoldBilled) GetGameEndStr() string {
|
|
||||||
if x != nil {
|
|
||||||
return x.GameEndStr
|
|
||||||
}
|
|
||||||
return ""
|
|
||||||
}
|
|
||||||
|
|
||||||
var File_protocol_ganeshagold_ganeshagold_proto protoreflect.FileDescriptor
|
|
||||||
|
|
||||||
var file_protocol_ganeshagold_ganeshagold_proto_rawDesc = []byte{
|
|
||||||
0x0a, 0x26, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x63, 0x6f, 0x6c, 0x2f, 0x67, 0x61, 0x6e, 0x65, 0x73,
|
|
||||||
0x68, 0x61, 0x67, 0x6f, 0x6c, 0x64, 0x2f, 0x67, 0x61, 0x6e, 0x65, 0x73, 0x68, 0x61, 0x67, 0x6f,
|
|
||||||
0x6c, 0x64, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x12, 0x0b, 0x67, 0x61, 0x6e, 0x65, 0x73, 0x68,
|
|
||||||
0x61, 0x67, 0x6f, 0x6c, 0x64, 0x22, 0xff, 0x01, 0x0a, 0x15, 0x47, 0x61, 0x6e, 0x65, 0x73, 0x68,
|
|
||||||
0x61, 0x47, 0x6f, 0x6c, 0x64, 0x50, 0x6c, 0x61, 0x79, 0x65, 0x72, 0x44, 0x61, 0x74, 0x61, 0x12,
|
|
||||||
0x12, 0x0a, 0x04, 0x4e, 0x61, 0x6d, 0x65, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x4e,
|
|
||||||
0x61, 0x6d, 0x65, 0x12, 0x12, 0x0a, 0x04, 0x53, 0x6e, 0x49, 0x64, 0x18, 0x02, 0x20, 0x01, 0x28,
|
|
||||||
0x05, 0x52, 0x04, 0x53, 0x6e, 0x49, 0x64, 0x12, 0x12, 0x0a, 0x04, 0x48, 0x65, 0x61, 0x64, 0x18,
|
|
||||||
0x03, 0x20, 0x01, 0x28, 0x05, 0x52, 0x04, 0x48, 0x65, 0x61, 0x64, 0x12, 0x10, 0x0a, 0x03, 0x53,
|
|
||||||
0x65, 0x78, 0x18, 0x04, 0x20, 0x01, 0x28, 0x05, 0x52, 0x03, 0x53, 0x65, 0x78, 0x12, 0x12, 0x0a,
|
|
||||||
0x04, 0x43, 0x6f, 0x69, 0x6e, 0x18, 0x05, 0x20, 0x01, 0x28, 0x03, 0x52, 0x04, 0x43, 0x6f, 0x69,
|
|
||||||
0x6e, 0x12, 0x10, 0x0a, 0x03, 0x50, 0x6f, 0x73, 0x18, 0x06, 0x20, 0x01, 0x28, 0x05, 0x52, 0x03,
|
|
||||||
0x50, 0x6f, 0x73, 0x12, 0x12, 0x0a, 0x04, 0x46, 0x6c, 0x61, 0x67, 0x18, 0x07, 0x20, 0x01, 0x28,
|
|
||||||
0x05, 0x52, 0x04, 0x46, 0x6c, 0x61, 0x67, 0x12, 0x16, 0x0a, 0x06, 0x50, 0x61, 0x72, 0x61, 0x6d,
|
|
||||||
0x73, 0x18, 0x08, 0x20, 0x03, 0x28, 0x09, 0x52, 0x06, 0x50, 0x61, 0x72, 0x61, 0x6d, 0x73, 0x12,
|
|
||||||
0x12, 0x0a, 0x04, 0x43, 0x69, 0x74, 0x79, 0x18, 0x09, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x43,
|
|
||||||
0x69, 0x74, 0x79, 0x12, 0x20, 0x0a, 0x0b, 0x48, 0x65, 0x61, 0x64, 0x4f, 0x75, 0x74, 0x4c, 0x69,
|
|
||||||
0x6e, 0x65, 0x18, 0x0a, 0x20, 0x01, 0x28, 0x05, 0x52, 0x0b, 0x48, 0x65, 0x61, 0x64, 0x4f, 0x75,
|
|
||||||
0x74, 0x4c, 0x69, 0x6e, 0x65, 0x12, 0x10, 0x0a, 0x03, 0x56, 0x49, 0x50, 0x18, 0x0b, 0x20, 0x01,
|
|
||||||
0x28, 0x05, 0x52, 0x03, 0x56, 0x49, 0x50, 0x22, 0xe7, 0x02, 0x0a, 0x15, 0x53, 0x43, 0x47, 0x61,
|
|
||||||
0x6e, 0x65, 0x73, 0x68, 0x61, 0x47, 0x6f, 0x6c, 0x64, 0x52, 0x6f, 0x6f, 0x6d, 0x49, 0x6e, 0x66,
|
|
||||||
0x6f, 0x12, 0x16, 0x0a, 0x06, 0x52, 0x6f, 0x6f, 0x6d, 0x49, 0x64, 0x18, 0x01, 0x20, 0x01, 0x28,
|
|
||||||
0x05, 0x52, 0x06, 0x52, 0x6f, 0x6f, 0x6d, 0x49, 0x64, 0x12, 0x1e, 0x0a, 0x0a, 0x47, 0x61, 0x6d,
|
|
||||||
0x65, 0x46, 0x72, 0x65, 0x65, 0x49, 0x64, 0x18, 0x02, 0x20, 0x01, 0x28, 0x05, 0x52, 0x0a, 0x47,
|
|
||||||
0x61, 0x6d, 0x65, 0x46, 0x72, 0x65, 0x65, 0x49, 0x64, 0x12, 0x16, 0x0a, 0x06, 0x47, 0x61, 0x6d,
|
|
||||||
0x65, 0x49, 0x64, 0x18, 0x03, 0x20, 0x01, 0x28, 0x05, 0x52, 0x06, 0x47, 0x61, 0x6d, 0x65, 0x49,
|
|
||||||
0x64, 0x12, 0x1a, 0x0a, 0x08, 0x52, 0x6f, 0x6f, 0x6d, 0x4d, 0x6f, 0x64, 0x65, 0x18, 0x04, 0x20,
|
|
||||||
0x01, 0x28, 0x05, 0x52, 0x08, 0x52, 0x6f, 0x6f, 0x6d, 0x4d, 0x6f, 0x64, 0x65, 0x12, 0x16, 0x0a,
|
|
||||||
0x06, 0x50, 0x61, 0x72, 0x61, 0x6d, 0x73, 0x18, 0x05, 0x20, 0x03, 0x28, 0x05, 0x52, 0x06, 0x50,
|
|
||||||
0x61, 0x72, 0x61, 0x6d, 0x73, 0x12, 0x1e, 0x0a, 0x0a, 0x4e, 0x75, 0x6d, 0x4f, 0x66, 0x47, 0x61,
|
|
||||||
0x6d, 0x65, 0x73, 0x18, 0x06, 0x20, 0x01, 0x28, 0x05, 0x52, 0x0a, 0x4e, 0x75, 0x6d, 0x4f, 0x66,
|
|
||||||
0x47, 0x61, 0x6d, 0x65, 0x73, 0x12, 0x14, 0x0a, 0x05, 0x53, 0x74, 0x61, 0x74, 0x65, 0x18, 0x07,
|
|
||||||
0x20, 0x01, 0x28, 0x05, 0x52, 0x05, 0x53, 0x74, 0x61, 0x74, 0x65, 0x12, 0x1a, 0x0a, 0x08, 0x50,
|
|
||||||
0x61, 0x72, 0x61, 0x6d, 0x73, 0x45, 0x78, 0x18, 0x08, 0x20, 0x03, 0x28, 0x03, 0x52, 0x08, 0x50,
|
|
||||||
0x61, 0x72, 0x61, 0x6d, 0x73, 0x45, 0x78, 0x12, 0x1c, 0x0a, 0x09, 0x53, 0x63, 0x65, 0x6e, 0x65,
|
|
||||||
0x54, 0x79, 0x70, 0x65, 0x18, 0x09, 0x20, 0x01, 0x28, 0x05, 0x52, 0x09, 0x53, 0x63, 0x65, 0x6e,
|
|
||||||
0x65, 0x54, 0x79, 0x70, 0x65, 0x12, 0x3a, 0x0a, 0x06, 0x50, 0x6c, 0x61, 0x79, 0x65, 0x72, 0x18,
|
|
||||||
0x0a, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x22, 0x2e, 0x67, 0x61, 0x6e, 0x65, 0x73, 0x68, 0x61, 0x67,
|
|
||||||
0x6f, 0x6c, 0x64, 0x2e, 0x47, 0x61, 0x6e, 0x65, 0x73, 0x68, 0x61, 0x47, 0x6f, 0x6c, 0x64, 0x50,
|
|
||||||
0x6c, 0x61, 0x79, 0x65, 0x72, 0x44, 0x61, 0x74, 0x61, 0x52, 0x06, 0x50, 0x6c, 0x61, 0x79, 0x65,
|
|
||||||
0x72, 0x12, 0x1e, 0x0a, 0x0a, 0x50, 0x6c, 0x61, 0x79, 0x65, 0x72, 0x49, 0x6e, 0x66, 0x6f, 0x18,
|
|
||||||
0x0b, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0a, 0x50, 0x6c, 0x61, 0x79, 0x65, 0x72, 0x49, 0x6e, 0x66,
|
|
||||||
0x6f, 0x22, 0x41, 0x0a, 0x0f, 0x43, 0x53, 0x47, 0x61, 0x6e, 0x65, 0x73, 0x68, 0x61, 0x47, 0x6f,
|
|
||||||
0x6c, 0x64, 0x4f, 0x70, 0x12, 0x16, 0x0a, 0x06, 0x4f, 0x70, 0x43, 0x6f, 0x64, 0x65, 0x18, 0x01,
|
|
||||||
0x20, 0x01, 0x28, 0x05, 0x52, 0x06, 0x4f, 0x70, 0x43, 0x6f, 0x64, 0x65, 0x12, 0x16, 0x0a, 0x06,
|
|
||||||
0x50, 0x61, 0x72, 0x61, 0x6d, 0x73, 0x18, 0x02, 0x20, 0x03, 0x28, 0x03, 0x52, 0x06, 0x50, 0x61,
|
|
||||||
0x72, 0x61, 0x6d, 0x73, 0x22, 0x5f, 0x0a, 0x0f, 0x53, 0x43, 0x47, 0x61, 0x6e, 0x65, 0x73, 0x68,
|
|
||||||
0x61, 0x47, 0x6f, 0x6c, 0x64, 0x4f, 0x70, 0x12, 0x16, 0x0a, 0x06, 0x4f, 0x70, 0x43, 0x6f, 0x64,
|
|
||||||
0x65, 0x18, 0x01, 0x20, 0x01, 0x28, 0x05, 0x52, 0x06, 0x4f, 0x70, 0x43, 0x6f, 0x64, 0x65, 0x12,
|
|
||||||
0x1c, 0x0a, 0x09, 0x4f, 0x70, 0x52, 0x65, 0x74, 0x43, 0x6f, 0x64, 0x65, 0x18, 0x02, 0x20, 0x01,
|
|
||||||
0x28, 0x05, 0x52, 0x09, 0x4f, 0x70, 0x52, 0x65, 0x74, 0x43, 0x6f, 0x64, 0x65, 0x12, 0x16, 0x0a,
|
|
||||||
0x06, 0x50, 0x61, 0x72, 0x61, 0x6d, 0x73, 0x18, 0x03, 0x20, 0x03, 0x28, 0x03, 0x52, 0x06, 0x50,
|
|
||||||
0x61, 0x72, 0x61, 0x6d, 0x73, 0x22, 0x62, 0x0a, 0x16, 0x53, 0x43, 0x47, 0x61, 0x6e, 0x65, 0x73,
|
|
||||||
0x68, 0x61, 0x47, 0x6f, 0x6c, 0x64, 0x52, 0x6f, 0x6f, 0x6d, 0x53, 0x74, 0x61, 0x74, 0x65, 0x12,
|
|
||||||
0x14, 0x0a, 0x05, 0x53, 0x74, 0x61, 0x74, 0x65, 0x18, 0x01, 0x20, 0x01, 0x28, 0x05, 0x52, 0x05,
|
|
||||||
0x53, 0x74, 0x61, 0x74, 0x65, 0x12, 0x1a, 0x0a, 0x08, 0x53, 0x75, 0x62, 0x53, 0x74, 0x61, 0x74,
|
|
||||||
0x65, 0x18, 0x02, 0x20, 0x01, 0x28, 0x05, 0x52, 0x08, 0x53, 0x75, 0x62, 0x53, 0x74, 0x61, 0x74,
|
|
||||||
0x65, 0x12, 0x16, 0x0a, 0x06, 0x50, 0x61, 0x72, 0x61, 0x6d, 0x73, 0x18, 0x03, 0x20, 0x03, 0x28,
|
|
||||||
0x05, 0x52, 0x06, 0x50, 0x61, 0x72, 0x61, 0x6d, 0x73, 0x22, 0x53, 0x0a, 0x13, 0x53, 0x43, 0x47,
|
|
||||||
0x61, 0x6e, 0x65, 0x73, 0x68, 0x61, 0x47, 0x6f, 0x6c, 0x64, 0x42, 0x69, 0x6c, 0x6c, 0x65, 0x64,
|
|
||||||
0x12, 0x1c, 0x0a, 0x09, 0x4f, 0x70, 0x52, 0x65, 0x74, 0x43, 0x6f, 0x64, 0x65, 0x18, 0x01, 0x20,
|
|
||||||
0x01, 0x28, 0x05, 0x52, 0x09, 0x4f, 0x70, 0x52, 0x65, 0x74, 0x43, 0x6f, 0x64, 0x65, 0x12, 0x1e,
|
|
||||||
0x0a, 0x0a, 0x47, 0x61, 0x6d, 0x65, 0x45, 0x6e, 0x64, 0x53, 0x74, 0x72, 0x18, 0x02, 0x20, 0x01,
|
|
||||||
0x28, 0x09, 0x52, 0x0a, 0x47, 0x61, 0x6d, 0x65, 0x45, 0x6e, 0x64, 0x53, 0x74, 0x72, 0x2a, 0x8b,
|
|
||||||
0x02, 0x0a, 0x0e, 0x47, 0x61, 0x6e, 0x65, 0x73, 0x68, 0x61, 0x47, 0x6f, 0x6c, 0x64, 0x50, 0x49,
|
|
||||||
0x44, 0x12, 0x1b, 0x0a, 0x17, 0x50, 0x41, 0x43, 0x4b, 0x45, 0x54, 0x5f, 0x47, 0x41, 0x4e, 0x45,
|
|
||||||
0x53, 0x48, 0x41, 0x47, 0x4f, 0x4c, 0x44, 0x5f, 0x5a, 0x45, 0x52, 0x4f, 0x10, 0x00, 0x12, 0x2d,
|
|
||||||
0x0a, 0x28, 0x50, 0x41, 0x43, 0x4b, 0x45, 0x54, 0x5f, 0x47, 0x41, 0x4e, 0x45, 0x53, 0x48, 0x41,
|
|
||||||
0x47, 0x4f, 0x4c, 0x44, 0x5f, 0x53, 0x43, 0x47, 0x41, 0x4e, 0x45, 0x53, 0x48, 0x41, 0x47, 0x4f,
|
|
||||||
0x4c, 0x44, 0x52, 0x4f, 0x4f, 0x4d, 0x49, 0x4e, 0x46, 0x4f, 0x10, 0xba, 0x2c, 0x12, 0x27, 0x0a,
|
|
||||||
0x22, 0x50, 0x41, 0x43, 0x4b, 0x45, 0x54, 0x5f, 0x47, 0x41, 0x4e, 0x45, 0x53, 0x48, 0x41, 0x47,
|
|
||||||
0x4f, 0x4c, 0x44, 0x5f, 0x43, 0x53, 0x47, 0x41, 0x4e, 0x45, 0x53, 0x48, 0x41, 0x47, 0x4f, 0x4c,
|
|
||||||
0x44, 0x4f, 0x50, 0x10, 0xbb, 0x2c, 0x12, 0x27, 0x0a, 0x22, 0x50, 0x41, 0x43, 0x4b, 0x45, 0x54,
|
|
||||||
0x5f, 0x47, 0x41, 0x4e, 0x45, 0x53, 0x48, 0x41, 0x47, 0x4f, 0x4c, 0x44, 0x5f, 0x53, 0x43, 0x47,
|
|
||||||
0x41, 0x4e, 0x45, 0x53, 0x48, 0x41, 0x47, 0x4f, 0x4c, 0x44, 0x4f, 0x50, 0x10, 0xbc, 0x2c, 0x12,
|
|
||||||
0x2e, 0x0a, 0x29, 0x50, 0x41, 0x43, 0x4b, 0x45, 0x54, 0x5f, 0x47, 0x41, 0x4e, 0x45, 0x53, 0x48,
|
|
||||||
0x41, 0x47, 0x4f, 0x4c, 0x44, 0x5f, 0x53, 0x43, 0x47, 0x41, 0x4e, 0x45, 0x53, 0x48, 0x41, 0x47,
|
|
||||||
0x4f, 0x4c, 0x44, 0x52, 0x4f, 0x4f, 0x4d, 0x53, 0x54, 0x41, 0x54, 0x45, 0x10, 0xbd, 0x2c, 0x12,
|
|
||||||
0x2b, 0x0a, 0x26, 0x50, 0x41, 0x43, 0x4b, 0x45, 0x54, 0x5f, 0x47, 0x41, 0x4e, 0x45, 0x53, 0x48,
|
|
||||||
0x41, 0x47, 0x4f, 0x4c, 0x44, 0x5f, 0x53, 0x43, 0x47, 0x41, 0x4e, 0x45, 0x53, 0x48, 0x41, 0x47,
|
|
||||||
0x4f, 0x4c, 0x44, 0x42, 0x49, 0x4c, 0x4c, 0x45, 0x44, 0x10, 0xbe, 0x2c, 0x42, 0x2b, 0x5a, 0x29,
|
|
||||||
0x6d, 0x6f, 0x6e, 0x67, 0x6f, 0x2e, 0x67, 0x61, 0x6d, 0x65, 0x73, 0x2e, 0x63, 0x6f, 0x6d, 0x2f,
|
|
||||||
0x67, 0x61, 0x6d, 0x65, 0x2f, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x63, 0x6f, 0x6c, 0x2f, 0x67, 0x61,
|
|
||||||
0x6e, 0x65, 0x73, 0x68, 0x61, 0x67, 0x6f, 0x6c, 0x64, 0x62, 0x06, 0x70, 0x72, 0x6f, 0x74, 0x6f,
|
|
||||||
0x33,
|
|
||||||
}
|
|
||||||
|
|
||||||
var (
|
|
||||||
file_protocol_ganeshagold_ganeshagold_proto_rawDescOnce sync.Once
|
|
||||||
file_protocol_ganeshagold_ganeshagold_proto_rawDescData = file_protocol_ganeshagold_ganeshagold_proto_rawDesc
|
|
||||||
)
|
|
||||||
|
|
||||||
func file_protocol_ganeshagold_ganeshagold_proto_rawDescGZIP() []byte {
|
|
||||||
file_protocol_ganeshagold_ganeshagold_proto_rawDescOnce.Do(func() {
|
|
||||||
file_protocol_ganeshagold_ganeshagold_proto_rawDescData = protoimpl.X.CompressGZIP(file_protocol_ganeshagold_ganeshagold_proto_rawDescData)
|
|
||||||
})
|
|
||||||
return file_protocol_ganeshagold_ganeshagold_proto_rawDescData
|
|
||||||
}
|
|
||||||
|
|
||||||
var file_protocol_ganeshagold_ganeshagold_proto_enumTypes = make([]protoimpl.EnumInfo, 1)
|
|
||||||
var file_protocol_ganeshagold_ganeshagold_proto_msgTypes = make([]protoimpl.MessageInfo, 6)
|
|
||||||
var file_protocol_ganeshagold_ganeshagold_proto_goTypes = []interface{}{
|
|
||||||
(GaneshaGoldPID)(0), // 0: ganeshagold.GaneshaGoldPID
|
|
||||||
(*GaneshaGoldPlayerData)(nil), // 1: ganeshagold.GaneshaGoldPlayerData
|
|
||||||
(*SCGaneshaGoldRoomInfo)(nil), // 2: ganeshagold.SCGaneshaGoldRoomInfo
|
|
||||||
(*CSGaneshaGoldOp)(nil), // 3: ganeshagold.CSGaneshaGoldOp
|
|
||||||
(*SCGaneshaGoldOp)(nil), // 4: ganeshagold.SCGaneshaGoldOp
|
|
||||||
(*SCGaneshaGoldRoomState)(nil), // 5: ganeshagold.SCGaneshaGoldRoomState
|
|
||||||
(*SCGaneshaGoldBilled)(nil), // 6: ganeshagold.SCGaneshaGoldBilled
|
|
||||||
}
|
|
||||||
var file_protocol_ganeshagold_ganeshagold_proto_depIdxs = []int32{
|
|
||||||
1, // 0: ganeshagold.SCGaneshaGoldRoomInfo.Player:type_name -> ganeshagold.GaneshaGoldPlayerData
|
|
||||||
1, // [1:1] is the sub-list for method output_type
|
|
||||||
1, // [1:1] is the sub-list for method input_type
|
|
||||||
1, // [1:1] is the sub-list for extension type_name
|
|
||||||
1, // [1:1] is the sub-list for extension extendee
|
|
||||||
0, // [0:1] is the sub-list for field type_name
|
|
||||||
}
|
|
||||||
|
|
||||||
func init() { file_protocol_ganeshagold_ganeshagold_proto_init() }
|
|
||||||
func file_protocol_ganeshagold_ganeshagold_proto_init() {
|
|
||||||
if File_protocol_ganeshagold_ganeshagold_proto != nil {
|
|
||||||
return
|
|
||||||
}
|
|
||||||
if !protoimpl.UnsafeEnabled {
|
|
||||||
file_protocol_ganeshagold_ganeshagold_proto_msgTypes[0].Exporter = func(v interface{}, i int) interface{} {
|
|
||||||
switch v := v.(*GaneshaGoldPlayerData); i {
|
|
||||||
case 0:
|
|
||||||
return &v.state
|
|
||||||
case 1:
|
|
||||||
return &v.sizeCache
|
|
||||||
case 2:
|
|
||||||
return &v.unknownFields
|
|
||||||
default:
|
|
||||||
return nil
|
|
||||||
}
|
|
||||||
}
|
|
||||||
file_protocol_ganeshagold_ganeshagold_proto_msgTypes[1].Exporter = func(v interface{}, i int) interface{} {
|
|
||||||
switch v := v.(*SCGaneshaGoldRoomInfo); i {
|
|
||||||
case 0:
|
|
||||||
return &v.state
|
|
||||||
case 1:
|
|
||||||
return &v.sizeCache
|
|
||||||
case 2:
|
|
||||||
return &v.unknownFields
|
|
||||||
default:
|
|
||||||
return nil
|
|
||||||
}
|
|
||||||
}
|
|
||||||
file_protocol_ganeshagold_ganeshagold_proto_msgTypes[2].Exporter = func(v interface{}, i int) interface{} {
|
|
||||||
switch v := v.(*CSGaneshaGoldOp); i {
|
|
||||||
case 0:
|
|
||||||
return &v.state
|
|
||||||
case 1:
|
|
||||||
return &v.sizeCache
|
|
||||||
case 2:
|
|
||||||
return &v.unknownFields
|
|
||||||
default:
|
|
||||||
return nil
|
|
||||||
}
|
|
||||||
}
|
|
||||||
file_protocol_ganeshagold_ganeshagold_proto_msgTypes[3].Exporter = func(v interface{}, i int) interface{} {
|
|
||||||
switch v := v.(*SCGaneshaGoldOp); i {
|
|
||||||
case 0:
|
|
||||||
return &v.state
|
|
||||||
case 1:
|
|
||||||
return &v.sizeCache
|
|
||||||
case 2:
|
|
||||||
return &v.unknownFields
|
|
||||||
default:
|
|
||||||
return nil
|
|
||||||
}
|
|
||||||
}
|
|
||||||
file_protocol_ganeshagold_ganeshagold_proto_msgTypes[4].Exporter = func(v interface{}, i int) interface{} {
|
|
||||||
switch v := v.(*SCGaneshaGoldRoomState); i {
|
|
||||||
case 0:
|
|
||||||
return &v.state
|
|
||||||
case 1:
|
|
||||||
return &v.sizeCache
|
|
||||||
case 2:
|
|
||||||
return &v.unknownFields
|
|
||||||
default:
|
|
||||||
return nil
|
|
||||||
}
|
|
||||||
}
|
|
||||||
file_protocol_ganeshagold_ganeshagold_proto_msgTypes[5].Exporter = func(v interface{}, i int) interface{} {
|
|
||||||
switch v := v.(*SCGaneshaGoldBilled); i {
|
|
||||||
case 0:
|
|
||||||
return &v.state
|
|
||||||
case 1:
|
|
||||||
return &v.sizeCache
|
|
||||||
case 2:
|
|
||||||
return &v.unknownFields
|
|
||||||
default:
|
|
||||||
return nil
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
type x struct{}
|
|
||||||
out := protoimpl.TypeBuilder{
|
|
||||||
File: protoimpl.DescBuilder{
|
|
||||||
GoPackagePath: reflect.TypeOf(x{}).PkgPath(),
|
|
||||||
RawDescriptor: file_protocol_ganeshagold_ganeshagold_proto_rawDesc,
|
|
||||||
NumEnums: 1,
|
|
||||||
NumMessages: 6,
|
|
||||||
NumExtensions: 0,
|
|
||||||
NumServices: 0,
|
|
||||||
},
|
|
||||||
GoTypes: file_protocol_ganeshagold_ganeshagold_proto_goTypes,
|
|
||||||
DependencyIndexes: file_protocol_ganeshagold_ganeshagold_proto_depIdxs,
|
|
||||||
EnumInfos: file_protocol_ganeshagold_ganeshagold_proto_enumTypes,
|
|
||||||
MessageInfos: file_protocol_ganeshagold_ganeshagold_proto_msgTypes,
|
|
||||||
}.Build()
|
|
||||||
File_protocol_ganeshagold_ganeshagold_proto = out.File
|
|
||||||
file_protocol_ganeshagold_ganeshagold_proto_rawDesc = nil
|
|
||||||
file_protocol_ganeshagold_ganeshagold_proto_goTypes = nil
|
|
||||||
file_protocol_ganeshagold_ganeshagold_proto_depIdxs = nil
|
|
||||||
}
|
|
||||||
|
|
@ -1,68 +0,0 @@
|
||||||
syntax = "proto3";
|
|
||||||
package ganeshagold;
|
|
||||||
option go_package = "mongo.games.com/game/protocol/ganeshagold";
|
|
||||||
|
|
||||||
//ganeshagold
|
|
||||||
//龙
|
|
||||||
enum GaneshaGoldPID {
|
|
||||||
PACKET_GANESHAGOLD_ZERO = 0;// 弃用消息号
|
|
||||||
PACKET_GANESHAGOLD_SCGANESHAGOLDROOMINFO = 5690; //房间信息
|
|
||||||
PACKET_GANESHAGOLD_CSGANESHAGOLDOP = 5691;
|
|
||||||
PACKET_GANESHAGOLD_SCGANESHAGOLDOP = 5692;
|
|
||||||
PACKET_GANESHAGOLD_SCGANESHAGOLDROOMSTATE = 5693;
|
|
||||||
PACKET_GANESHAGOLD_SCGANESHAGOLDBILLED = 5694;
|
|
||||||
}
|
|
||||||
|
|
||||||
message GaneshaGoldPlayerData {
|
|
||||||
string Name = 1; //名字
|
|
||||||
int32 SnId = 2; //账号
|
|
||||||
int32 Head = 3; //头像
|
|
||||||
int32 Sex = 4; //性别
|
|
||||||
int64 Coin = 5; //金币
|
|
||||||
int32 Pos = 6; //座位位置
|
|
||||||
int32 Flag = 7; //二进制标记
|
|
||||||
repeated string Params = 8; //其他数据 如:ip 等
|
|
||||||
string City = 9; //城市
|
|
||||||
int32 HeadOutLine = 10; //头像框
|
|
||||||
int32 VIP = 11;
|
|
||||||
}
|
|
||||||
//房间信息
|
|
||||||
//PACKET_GANESHAGOLD_SCGANESHAGOLDROOMINFO
|
|
||||||
message SCGaneshaGoldRoomInfo {
|
|
||||||
int32 RoomId = 1; //房间id
|
|
||||||
int32 GameFreeId = 2;
|
|
||||||
int32 GameId = 3; //游戏id
|
|
||||||
int32 RoomMode = 4; //游戏模式
|
|
||||||
repeated int32 Params = 5; //规则参数
|
|
||||||
int32 NumOfGames = 6; //当前第几局
|
|
||||||
int32 State = 7; //房间当前状态
|
|
||||||
repeated int64 ParamsEx = 8; //其他参数
|
|
||||||
int32 SceneType = 9; //房间模式
|
|
||||||
GaneshaGoldPlayerData Player = 10; //房间内的玩家信息
|
|
||||||
string PlayerInfo = 11;
|
|
||||||
}
|
|
||||||
//玩家操作
|
|
||||||
//PACKET_GANESHAGOLD_CSGANESHAGOLDOP
|
|
||||||
message CSGaneshaGoldOp {
|
|
||||||
int32 OpCode = 1; //操作码 0.spin
|
|
||||||
repeated int64 Params = 2; //操作参数 下注索引编号
|
|
||||||
}
|
|
||||||
//玩家操作返回
|
|
||||||
//PACKET_GANESHAGOLD_SCGANESHAGOLDOP
|
|
||||||
message SCGaneshaGoldOp {
|
|
||||||
int32 OpCode = 1; //操作码
|
|
||||||
int32 OpRetCode = 2; //操作结果 1.金币不足 2.低于该值不能押注
|
|
||||||
repeated int64 Params = 3; //操作参数
|
|
||||||
}
|
|
||||||
//房间状态
|
|
||||||
//PACKET_GANESHAGOLD_SCGANESHAGOLDROOMSTATE
|
|
||||||
message SCGaneshaGoldRoomState {
|
|
||||||
int32 State = 1; //房间当前状态
|
|
||||||
int32 SubState = 2; //房间当前子状态
|
|
||||||
repeated int32 Params = 3; //状态参数
|
|
||||||
}
|
|
||||||
//PACKET_GANESHAGOLD_SCGANESHAGOLDBILLED
|
|
||||||
message SCGaneshaGoldBilled{
|
|
||||||
int32 OpRetCode = 1;//0.spin成功 1.spin失败
|
|
||||||
string GameEndStr = 2;
|
|
||||||
}
|
|
||||||
|
|
@ -1,799 +0,0 @@
|
||||||
// Code generated by protoc-gen-go. DO NOT EDIT.
|
|
||||||
// versions:
|
|
||||||
// protoc-gen-go v1.27.1-devel
|
|
||||||
// protoc v3.19.4
|
|
||||||
// source: protocol/sugarrush/sugarrush.proto
|
|
||||||
|
|
||||||
package sugarrush
|
|
||||||
|
|
||||||
import (
|
|
||||||
protoreflect "google.golang.org/protobuf/reflect/protoreflect"
|
|
||||||
protoimpl "google.golang.org/protobuf/runtime/protoimpl"
|
|
||||||
reflect "reflect"
|
|
||||||
sync "sync"
|
|
||||||
)
|
|
||||||
|
|
||||||
const (
|
|
||||||
// Verify that this generated code is sufficiently up-to-date.
|
|
||||||
_ = protoimpl.EnforceVersion(20 - protoimpl.MinVersion)
|
|
||||||
// Verify that runtime/protoimpl is sufficiently up-to-date.
|
|
||||||
_ = protoimpl.EnforceVersion(protoimpl.MaxVersion - 20)
|
|
||||||
)
|
|
||||||
|
|
||||||
//sugarrush
|
|
||||||
//龙
|
|
||||||
type SugarRushPID int32
|
|
||||||
|
|
||||||
const (
|
|
||||||
SugarRushPID_PACKET_SUGARRUSH_ZERO SugarRushPID = 0 // 弃用消息号
|
|
||||||
SugarRushPID_PACKET_SUGARRUSH_SCSUGARRUSHROOMINFO SugarRushPID = 5700 //房间信息
|
|
||||||
SugarRushPID_PACKET_SUGARRUSH_CSSUGARRUSHOP SugarRushPID = 5701
|
|
||||||
SugarRushPID_PACKET_SUGARRUSH_SCSUGARRUSHOP SugarRushPID = 5702
|
|
||||||
SugarRushPID_PACKET_SUGARRUSH_SCSUGARRUSHROOMSTATE SugarRushPID = 5703
|
|
||||||
SugarRushPID_PACKET_SUGARRUSH_SCSUGARRUSHBILLED SugarRushPID = 5704
|
|
||||||
)
|
|
||||||
|
|
||||||
// Enum value maps for SugarRushPID.
|
|
||||||
var (
|
|
||||||
SugarRushPID_name = map[int32]string{
|
|
||||||
0: "PACKET_SUGARRUSH_ZERO",
|
|
||||||
5700: "PACKET_SUGARRUSH_SCSUGARRUSHROOMINFO",
|
|
||||||
5701: "PACKET_SUGARRUSH_CSSUGARRUSHOP",
|
|
||||||
5702: "PACKET_SUGARRUSH_SCSUGARRUSHOP",
|
|
||||||
5703: "PACKET_SUGARRUSH_SCSUGARRUSHROOMSTATE",
|
|
||||||
5704: "PACKET_SUGARRUSH_SCSUGARRUSHBILLED",
|
|
||||||
}
|
|
||||||
SugarRushPID_value = map[string]int32{
|
|
||||||
"PACKET_SUGARRUSH_ZERO": 0,
|
|
||||||
"PACKET_SUGARRUSH_SCSUGARRUSHROOMINFO": 5700,
|
|
||||||
"PACKET_SUGARRUSH_CSSUGARRUSHOP": 5701,
|
|
||||||
"PACKET_SUGARRUSH_SCSUGARRUSHOP": 5702,
|
|
||||||
"PACKET_SUGARRUSH_SCSUGARRUSHROOMSTATE": 5703,
|
|
||||||
"PACKET_SUGARRUSH_SCSUGARRUSHBILLED": 5704,
|
|
||||||
}
|
|
||||||
)
|
|
||||||
|
|
||||||
func (x SugarRushPID) Enum() *SugarRushPID {
|
|
||||||
p := new(SugarRushPID)
|
|
||||||
*p = x
|
|
||||||
return p
|
|
||||||
}
|
|
||||||
|
|
||||||
func (x SugarRushPID) String() string {
|
|
||||||
return protoimpl.X.EnumStringOf(x.Descriptor(), protoreflect.EnumNumber(x))
|
|
||||||
}
|
|
||||||
|
|
||||||
func (SugarRushPID) Descriptor() protoreflect.EnumDescriptor {
|
|
||||||
return file_protocol_sugarrush_sugarrush_proto_enumTypes[0].Descriptor()
|
|
||||||
}
|
|
||||||
|
|
||||||
func (SugarRushPID) Type() protoreflect.EnumType {
|
|
||||||
return &file_protocol_sugarrush_sugarrush_proto_enumTypes[0]
|
|
||||||
}
|
|
||||||
|
|
||||||
func (x SugarRushPID) Number() protoreflect.EnumNumber {
|
|
||||||
return protoreflect.EnumNumber(x)
|
|
||||||
}
|
|
||||||
|
|
||||||
// Deprecated: Use SugarRushPID.Descriptor instead.
|
|
||||||
func (SugarRushPID) EnumDescriptor() ([]byte, []int) {
|
|
||||||
return file_protocol_sugarrush_sugarrush_proto_rawDescGZIP(), []int{0}
|
|
||||||
}
|
|
||||||
|
|
||||||
type SugarRushPlayerData struct {
|
|
||||||
state protoimpl.MessageState
|
|
||||||
sizeCache protoimpl.SizeCache
|
|
||||||
unknownFields protoimpl.UnknownFields
|
|
||||||
|
|
||||||
Name string `protobuf:"bytes,1,opt,name=Name,proto3" json:"Name,omitempty"` //名字
|
|
||||||
SnId int32 `protobuf:"varint,2,opt,name=SnId,proto3" json:"SnId,omitempty"` //账号
|
|
||||||
Head int32 `protobuf:"varint,3,opt,name=Head,proto3" json:"Head,omitempty"` //头像
|
|
||||||
Sex int32 `protobuf:"varint,4,opt,name=Sex,proto3" json:"Sex,omitempty"` //性别
|
|
||||||
Coin int64 `protobuf:"varint,5,opt,name=Coin,proto3" json:"Coin,omitempty"` //金币
|
|
||||||
Pos int32 `protobuf:"varint,6,opt,name=Pos,proto3" json:"Pos,omitempty"` //座位位置
|
|
||||||
Flag int32 `protobuf:"varint,7,opt,name=Flag,proto3" json:"Flag,omitempty"` //二进制标记
|
|
||||||
Params []string `protobuf:"bytes,8,rep,name=Params,proto3" json:"Params,omitempty"` //其他数据 如:ip 等
|
|
||||||
City string `protobuf:"bytes,9,opt,name=City,proto3" json:"City,omitempty"` //城市
|
|
||||||
HeadOutLine int32 `protobuf:"varint,10,opt,name=HeadOutLine,proto3" json:"HeadOutLine,omitempty"` //头像框
|
|
||||||
VIP int32 `protobuf:"varint,11,opt,name=VIP,proto3" json:"VIP,omitempty"`
|
|
||||||
}
|
|
||||||
|
|
||||||
func (x *SugarRushPlayerData) Reset() {
|
|
||||||
*x = SugarRushPlayerData{}
|
|
||||||
if protoimpl.UnsafeEnabled {
|
|
||||||
mi := &file_protocol_sugarrush_sugarrush_proto_msgTypes[0]
|
|
||||||
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
|
||||||
ms.StoreMessageInfo(mi)
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
func (x *SugarRushPlayerData) String() string {
|
|
||||||
return protoimpl.X.MessageStringOf(x)
|
|
||||||
}
|
|
||||||
|
|
||||||
func (*SugarRushPlayerData) ProtoMessage() {}
|
|
||||||
|
|
||||||
func (x *SugarRushPlayerData) ProtoReflect() protoreflect.Message {
|
|
||||||
mi := &file_protocol_sugarrush_sugarrush_proto_msgTypes[0]
|
|
||||||
if protoimpl.UnsafeEnabled && x != nil {
|
|
||||||
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
|
||||||
if ms.LoadMessageInfo() == nil {
|
|
||||||
ms.StoreMessageInfo(mi)
|
|
||||||
}
|
|
||||||
return ms
|
|
||||||
}
|
|
||||||
return mi.MessageOf(x)
|
|
||||||
}
|
|
||||||
|
|
||||||
// Deprecated: Use SugarRushPlayerData.ProtoReflect.Descriptor instead.
|
|
||||||
func (*SugarRushPlayerData) Descriptor() ([]byte, []int) {
|
|
||||||
return file_protocol_sugarrush_sugarrush_proto_rawDescGZIP(), []int{0}
|
|
||||||
}
|
|
||||||
|
|
||||||
func (x *SugarRushPlayerData) GetName() string {
|
|
||||||
if x != nil {
|
|
||||||
return x.Name
|
|
||||||
}
|
|
||||||
return ""
|
|
||||||
}
|
|
||||||
|
|
||||||
func (x *SugarRushPlayerData) GetSnId() int32 {
|
|
||||||
if x != nil {
|
|
||||||
return x.SnId
|
|
||||||
}
|
|
||||||
return 0
|
|
||||||
}
|
|
||||||
|
|
||||||
func (x *SugarRushPlayerData) GetHead() int32 {
|
|
||||||
if x != nil {
|
|
||||||
return x.Head
|
|
||||||
}
|
|
||||||
return 0
|
|
||||||
}
|
|
||||||
|
|
||||||
func (x *SugarRushPlayerData) GetSex() int32 {
|
|
||||||
if x != nil {
|
|
||||||
return x.Sex
|
|
||||||
}
|
|
||||||
return 0
|
|
||||||
}
|
|
||||||
|
|
||||||
func (x *SugarRushPlayerData) GetCoin() int64 {
|
|
||||||
if x != nil {
|
|
||||||
return x.Coin
|
|
||||||
}
|
|
||||||
return 0
|
|
||||||
}
|
|
||||||
|
|
||||||
func (x *SugarRushPlayerData) GetPos() int32 {
|
|
||||||
if x != nil {
|
|
||||||
return x.Pos
|
|
||||||
}
|
|
||||||
return 0
|
|
||||||
}
|
|
||||||
|
|
||||||
func (x *SugarRushPlayerData) GetFlag() int32 {
|
|
||||||
if x != nil {
|
|
||||||
return x.Flag
|
|
||||||
}
|
|
||||||
return 0
|
|
||||||
}
|
|
||||||
|
|
||||||
func (x *SugarRushPlayerData) GetParams() []string {
|
|
||||||
if x != nil {
|
|
||||||
return x.Params
|
|
||||||
}
|
|
||||||
return nil
|
|
||||||
}
|
|
||||||
|
|
||||||
func (x *SugarRushPlayerData) GetCity() string {
|
|
||||||
if x != nil {
|
|
||||||
return x.City
|
|
||||||
}
|
|
||||||
return ""
|
|
||||||
}
|
|
||||||
|
|
||||||
func (x *SugarRushPlayerData) GetHeadOutLine() int32 {
|
|
||||||
if x != nil {
|
|
||||||
return x.HeadOutLine
|
|
||||||
}
|
|
||||||
return 0
|
|
||||||
}
|
|
||||||
|
|
||||||
func (x *SugarRushPlayerData) GetVIP() int32 {
|
|
||||||
if x != nil {
|
|
||||||
return x.VIP
|
|
||||||
}
|
|
||||||
return 0
|
|
||||||
}
|
|
||||||
|
|
||||||
//房间信息
|
|
||||||
//PACKET_SUGARRUSH_SCSUGARRUSHROOMINFO
|
|
||||||
type SCSugarRushRoomInfo struct {
|
|
||||||
state protoimpl.MessageState
|
|
||||||
sizeCache protoimpl.SizeCache
|
|
||||||
unknownFields protoimpl.UnknownFields
|
|
||||||
|
|
||||||
RoomId int32 `protobuf:"varint,1,opt,name=RoomId,proto3" json:"RoomId,omitempty"` //房间id
|
|
||||||
GameFreeId int32 `protobuf:"varint,2,opt,name=GameFreeId,proto3" json:"GameFreeId,omitempty"`
|
|
||||||
GameId int32 `protobuf:"varint,3,opt,name=GameId,proto3" json:"GameId,omitempty"` //游戏id
|
|
||||||
RoomMode int32 `protobuf:"varint,4,opt,name=RoomMode,proto3" json:"RoomMode,omitempty"` //游戏模式
|
|
||||||
Params []int32 `protobuf:"varint,5,rep,packed,name=Params,proto3" json:"Params,omitempty"` //规则参数
|
|
||||||
NumOfGames int32 `protobuf:"varint,6,opt,name=NumOfGames,proto3" json:"NumOfGames,omitempty"` //当前第几局
|
|
||||||
State int32 `protobuf:"varint,7,opt,name=State,proto3" json:"State,omitempty"` //房间当前状态
|
|
||||||
ParamsEx []int64 `protobuf:"varint,8,rep,packed,name=ParamsEx,proto3" json:"ParamsEx,omitempty"` //其他参数
|
|
||||||
SceneType int32 `protobuf:"varint,9,opt,name=SceneType,proto3" json:"SceneType,omitempty"` //房间模式
|
|
||||||
Player *SugarRushPlayerData `protobuf:"bytes,10,opt,name=Player,proto3" json:"Player,omitempty"` //房间内的玩家信息
|
|
||||||
PlayerInfo string `protobuf:"bytes,11,opt,name=PlayerInfo,proto3" json:"PlayerInfo,omitempty"`
|
|
||||||
}
|
|
||||||
|
|
||||||
func (x *SCSugarRushRoomInfo) Reset() {
|
|
||||||
*x = SCSugarRushRoomInfo{}
|
|
||||||
if protoimpl.UnsafeEnabled {
|
|
||||||
mi := &file_protocol_sugarrush_sugarrush_proto_msgTypes[1]
|
|
||||||
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
|
||||||
ms.StoreMessageInfo(mi)
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
func (x *SCSugarRushRoomInfo) String() string {
|
|
||||||
return protoimpl.X.MessageStringOf(x)
|
|
||||||
}
|
|
||||||
|
|
||||||
func (*SCSugarRushRoomInfo) ProtoMessage() {}
|
|
||||||
|
|
||||||
func (x *SCSugarRushRoomInfo) ProtoReflect() protoreflect.Message {
|
|
||||||
mi := &file_protocol_sugarrush_sugarrush_proto_msgTypes[1]
|
|
||||||
if protoimpl.UnsafeEnabled && x != nil {
|
|
||||||
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
|
||||||
if ms.LoadMessageInfo() == nil {
|
|
||||||
ms.StoreMessageInfo(mi)
|
|
||||||
}
|
|
||||||
return ms
|
|
||||||
}
|
|
||||||
return mi.MessageOf(x)
|
|
||||||
}
|
|
||||||
|
|
||||||
// Deprecated: Use SCSugarRushRoomInfo.ProtoReflect.Descriptor instead.
|
|
||||||
func (*SCSugarRushRoomInfo) Descriptor() ([]byte, []int) {
|
|
||||||
return file_protocol_sugarrush_sugarrush_proto_rawDescGZIP(), []int{1}
|
|
||||||
}
|
|
||||||
|
|
||||||
func (x *SCSugarRushRoomInfo) GetRoomId() int32 {
|
|
||||||
if x != nil {
|
|
||||||
return x.RoomId
|
|
||||||
}
|
|
||||||
return 0
|
|
||||||
}
|
|
||||||
|
|
||||||
func (x *SCSugarRushRoomInfo) GetGameFreeId() int32 {
|
|
||||||
if x != nil {
|
|
||||||
return x.GameFreeId
|
|
||||||
}
|
|
||||||
return 0
|
|
||||||
}
|
|
||||||
|
|
||||||
func (x *SCSugarRushRoomInfo) GetGameId() int32 {
|
|
||||||
if x != nil {
|
|
||||||
return x.GameId
|
|
||||||
}
|
|
||||||
return 0
|
|
||||||
}
|
|
||||||
|
|
||||||
func (x *SCSugarRushRoomInfo) GetRoomMode() int32 {
|
|
||||||
if x != nil {
|
|
||||||
return x.RoomMode
|
|
||||||
}
|
|
||||||
return 0
|
|
||||||
}
|
|
||||||
|
|
||||||
func (x *SCSugarRushRoomInfo) GetParams() []int32 {
|
|
||||||
if x != nil {
|
|
||||||
return x.Params
|
|
||||||
}
|
|
||||||
return nil
|
|
||||||
}
|
|
||||||
|
|
||||||
func (x *SCSugarRushRoomInfo) GetNumOfGames() int32 {
|
|
||||||
if x != nil {
|
|
||||||
return x.NumOfGames
|
|
||||||
}
|
|
||||||
return 0
|
|
||||||
}
|
|
||||||
|
|
||||||
func (x *SCSugarRushRoomInfo) GetState() int32 {
|
|
||||||
if x != nil {
|
|
||||||
return x.State
|
|
||||||
}
|
|
||||||
return 0
|
|
||||||
}
|
|
||||||
|
|
||||||
func (x *SCSugarRushRoomInfo) GetParamsEx() []int64 {
|
|
||||||
if x != nil {
|
|
||||||
return x.ParamsEx
|
|
||||||
}
|
|
||||||
return nil
|
|
||||||
}
|
|
||||||
|
|
||||||
func (x *SCSugarRushRoomInfo) GetSceneType() int32 {
|
|
||||||
if x != nil {
|
|
||||||
return x.SceneType
|
|
||||||
}
|
|
||||||
return 0
|
|
||||||
}
|
|
||||||
|
|
||||||
func (x *SCSugarRushRoomInfo) GetPlayer() *SugarRushPlayerData {
|
|
||||||
if x != nil {
|
|
||||||
return x.Player
|
|
||||||
}
|
|
||||||
return nil
|
|
||||||
}
|
|
||||||
|
|
||||||
func (x *SCSugarRushRoomInfo) GetPlayerInfo() string {
|
|
||||||
if x != nil {
|
|
||||||
return x.PlayerInfo
|
|
||||||
}
|
|
||||||
return ""
|
|
||||||
}
|
|
||||||
|
|
||||||
//玩家操作
|
|
||||||
//PACKET_SUGARRUSH_CSSUGARRUSHOP
|
|
||||||
type CSSugarRushOp struct {
|
|
||||||
state protoimpl.MessageState
|
|
||||||
sizeCache protoimpl.SizeCache
|
|
||||||
unknownFields protoimpl.UnknownFields
|
|
||||||
|
|
||||||
OpCode int32 `protobuf:"varint,1,opt,name=OpCode,proto3" json:"OpCode,omitempty"` //操作码 0.spin
|
|
||||||
Params []int64 `protobuf:"varint,2,rep,packed,name=Params,proto3" json:"Params,omitempty"` //操作参数 下注索引编号
|
|
||||||
}
|
|
||||||
|
|
||||||
func (x *CSSugarRushOp) Reset() {
|
|
||||||
*x = CSSugarRushOp{}
|
|
||||||
if protoimpl.UnsafeEnabled {
|
|
||||||
mi := &file_protocol_sugarrush_sugarrush_proto_msgTypes[2]
|
|
||||||
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
|
||||||
ms.StoreMessageInfo(mi)
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
func (x *CSSugarRushOp) String() string {
|
|
||||||
return protoimpl.X.MessageStringOf(x)
|
|
||||||
}
|
|
||||||
|
|
||||||
func (*CSSugarRushOp) ProtoMessage() {}
|
|
||||||
|
|
||||||
func (x *CSSugarRushOp) ProtoReflect() protoreflect.Message {
|
|
||||||
mi := &file_protocol_sugarrush_sugarrush_proto_msgTypes[2]
|
|
||||||
if protoimpl.UnsafeEnabled && x != nil {
|
|
||||||
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
|
||||||
if ms.LoadMessageInfo() == nil {
|
|
||||||
ms.StoreMessageInfo(mi)
|
|
||||||
}
|
|
||||||
return ms
|
|
||||||
}
|
|
||||||
return mi.MessageOf(x)
|
|
||||||
}
|
|
||||||
|
|
||||||
// Deprecated: Use CSSugarRushOp.ProtoReflect.Descriptor instead.
|
|
||||||
func (*CSSugarRushOp) Descriptor() ([]byte, []int) {
|
|
||||||
return file_protocol_sugarrush_sugarrush_proto_rawDescGZIP(), []int{2}
|
|
||||||
}
|
|
||||||
|
|
||||||
func (x *CSSugarRushOp) GetOpCode() int32 {
|
|
||||||
if x != nil {
|
|
||||||
return x.OpCode
|
|
||||||
}
|
|
||||||
return 0
|
|
||||||
}
|
|
||||||
|
|
||||||
func (x *CSSugarRushOp) GetParams() []int64 {
|
|
||||||
if x != nil {
|
|
||||||
return x.Params
|
|
||||||
}
|
|
||||||
return nil
|
|
||||||
}
|
|
||||||
|
|
||||||
//玩家操作返回
|
|
||||||
//PACKET_SUGARRUSH_SCSUGARRUSHOP
|
|
||||||
type SCSugarRushOp struct {
|
|
||||||
state protoimpl.MessageState
|
|
||||||
sizeCache protoimpl.SizeCache
|
|
||||||
unknownFields protoimpl.UnknownFields
|
|
||||||
|
|
||||||
OpCode int32 `protobuf:"varint,1,opt,name=OpCode,proto3" json:"OpCode,omitempty"` //操作码
|
|
||||||
OpRetCode int32 `protobuf:"varint,2,opt,name=OpRetCode,proto3" json:"OpRetCode,omitempty"` //操作结果 1.金币不足 2.低于该值不能押注
|
|
||||||
Params []int64 `protobuf:"varint,3,rep,packed,name=Params,proto3" json:"Params,omitempty"` //操作参数
|
|
||||||
}
|
|
||||||
|
|
||||||
func (x *SCSugarRushOp) Reset() {
|
|
||||||
*x = SCSugarRushOp{}
|
|
||||||
if protoimpl.UnsafeEnabled {
|
|
||||||
mi := &file_protocol_sugarrush_sugarrush_proto_msgTypes[3]
|
|
||||||
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
|
||||||
ms.StoreMessageInfo(mi)
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
func (x *SCSugarRushOp) String() string {
|
|
||||||
return protoimpl.X.MessageStringOf(x)
|
|
||||||
}
|
|
||||||
|
|
||||||
func (*SCSugarRushOp) ProtoMessage() {}
|
|
||||||
|
|
||||||
func (x *SCSugarRushOp) ProtoReflect() protoreflect.Message {
|
|
||||||
mi := &file_protocol_sugarrush_sugarrush_proto_msgTypes[3]
|
|
||||||
if protoimpl.UnsafeEnabled && x != nil {
|
|
||||||
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
|
||||||
if ms.LoadMessageInfo() == nil {
|
|
||||||
ms.StoreMessageInfo(mi)
|
|
||||||
}
|
|
||||||
return ms
|
|
||||||
}
|
|
||||||
return mi.MessageOf(x)
|
|
||||||
}
|
|
||||||
|
|
||||||
// Deprecated: Use SCSugarRushOp.ProtoReflect.Descriptor instead.
|
|
||||||
func (*SCSugarRushOp) Descriptor() ([]byte, []int) {
|
|
||||||
return file_protocol_sugarrush_sugarrush_proto_rawDescGZIP(), []int{3}
|
|
||||||
}
|
|
||||||
|
|
||||||
func (x *SCSugarRushOp) GetOpCode() int32 {
|
|
||||||
if x != nil {
|
|
||||||
return x.OpCode
|
|
||||||
}
|
|
||||||
return 0
|
|
||||||
}
|
|
||||||
|
|
||||||
func (x *SCSugarRushOp) GetOpRetCode() int32 {
|
|
||||||
if x != nil {
|
|
||||||
return x.OpRetCode
|
|
||||||
}
|
|
||||||
return 0
|
|
||||||
}
|
|
||||||
|
|
||||||
func (x *SCSugarRushOp) GetParams() []int64 {
|
|
||||||
if x != nil {
|
|
||||||
return x.Params
|
|
||||||
}
|
|
||||||
return nil
|
|
||||||
}
|
|
||||||
|
|
||||||
//房间状态
|
|
||||||
//PACKET_SUGARRUSH_SCSUGARRUSHROOMSTATE
|
|
||||||
type SCSugarRushRoomState struct {
|
|
||||||
state protoimpl.MessageState
|
|
||||||
sizeCache protoimpl.SizeCache
|
|
||||||
unknownFields protoimpl.UnknownFields
|
|
||||||
|
|
||||||
State int32 `protobuf:"varint,1,opt,name=State,proto3" json:"State,omitempty"` //房间当前状态
|
|
||||||
SubState int32 `protobuf:"varint,2,opt,name=SubState,proto3" json:"SubState,omitempty"` //房间当前子状态
|
|
||||||
Params []int32 `protobuf:"varint,3,rep,packed,name=Params,proto3" json:"Params,omitempty"` //状态参数
|
|
||||||
}
|
|
||||||
|
|
||||||
func (x *SCSugarRushRoomState) Reset() {
|
|
||||||
*x = SCSugarRushRoomState{}
|
|
||||||
if protoimpl.UnsafeEnabled {
|
|
||||||
mi := &file_protocol_sugarrush_sugarrush_proto_msgTypes[4]
|
|
||||||
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
|
||||||
ms.StoreMessageInfo(mi)
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
func (x *SCSugarRushRoomState) String() string {
|
|
||||||
return protoimpl.X.MessageStringOf(x)
|
|
||||||
}
|
|
||||||
|
|
||||||
func (*SCSugarRushRoomState) ProtoMessage() {}
|
|
||||||
|
|
||||||
func (x *SCSugarRushRoomState) ProtoReflect() protoreflect.Message {
|
|
||||||
mi := &file_protocol_sugarrush_sugarrush_proto_msgTypes[4]
|
|
||||||
if protoimpl.UnsafeEnabled && x != nil {
|
|
||||||
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
|
||||||
if ms.LoadMessageInfo() == nil {
|
|
||||||
ms.StoreMessageInfo(mi)
|
|
||||||
}
|
|
||||||
return ms
|
|
||||||
}
|
|
||||||
return mi.MessageOf(x)
|
|
||||||
}
|
|
||||||
|
|
||||||
// Deprecated: Use SCSugarRushRoomState.ProtoReflect.Descriptor instead.
|
|
||||||
func (*SCSugarRushRoomState) Descriptor() ([]byte, []int) {
|
|
||||||
return file_protocol_sugarrush_sugarrush_proto_rawDescGZIP(), []int{4}
|
|
||||||
}
|
|
||||||
|
|
||||||
func (x *SCSugarRushRoomState) GetState() int32 {
|
|
||||||
if x != nil {
|
|
||||||
return x.State
|
|
||||||
}
|
|
||||||
return 0
|
|
||||||
}
|
|
||||||
|
|
||||||
func (x *SCSugarRushRoomState) GetSubState() int32 {
|
|
||||||
if x != nil {
|
|
||||||
return x.SubState
|
|
||||||
}
|
|
||||||
return 0
|
|
||||||
}
|
|
||||||
|
|
||||||
func (x *SCSugarRushRoomState) GetParams() []int32 {
|
|
||||||
if x != nil {
|
|
||||||
return x.Params
|
|
||||||
}
|
|
||||||
return nil
|
|
||||||
}
|
|
||||||
|
|
||||||
//PACKET_SUGARRUSH_SCSUGARRUSHBILLED
|
|
||||||
type SCSugarRushBilled struct {
|
|
||||||
state protoimpl.MessageState
|
|
||||||
sizeCache protoimpl.SizeCache
|
|
||||||
unknownFields protoimpl.UnknownFields
|
|
||||||
|
|
||||||
OpRetCode int32 `protobuf:"varint,1,opt,name=OpRetCode,proto3" json:"OpRetCode,omitempty"` //0.spin成功 1.spin失败
|
|
||||||
GameEndStr string `protobuf:"bytes,2,opt,name=GameEndStr,proto3" json:"GameEndStr,omitempty"`
|
|
||||||
}
|
|
||||||
|
|
||||||
func (x *SCSugarRushBilled) Reset() {
|
|
||||||
*x = SCSugarRushBilled{}
|
|
||||||
if protoimpl.UnsafeEnabled {
|
|
||||||
mi := &file_protocol_sugarrush_sugarrush_proto_msgTypes[5]
|
|
||||||
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
|
||||||
ms.StoreMessageInfo(mi)
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
func (x *SCSugarRushBilled) String() string {
|
|
||||||
return protoimpl.X.MessageStringOf(x)
|
|
||||||
}
|
|
||||||
|
|
||||||
func (*SCSugarRushBilled) ProtoMessage() {}
|
|
||||||
|
|
||||||
func (x *SCSugarRushBilled) ProtoReflect() protoreflect.Message {
|
|
||||||
mi := &file_protocol_sugarrush_sugarrush_proto_msgTypes[5]
|
|
||||||
if protoimpl.UnsafeEnabled && x != nil {
|
|
||||||
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
|
||||||
if ms.LoadMessageInfo() == nil {
|
|
||||||
ms.StoreMessageInfo(mi)
|
|
||||||
}
|
|
||||||
return ms
|
|
||||||
}
|
|
||||||
return mi.MessageOf(x)
|
|
||||||
}
|
|
||||||
|
|
||||||
// Deprecated: Use SCSugarRushBilled.ProtoReflect.Descriptor instead.
|
|
||||||
func (*SCSugarRushBilled) Descriptor() ([]byte, []int) {
|
|
||||||
return file_protocol_sugarrush_sugarrush_proto_rawDescGZIP(), []int{5}
|
|
||||||
}
|
|
||||||
|
|
||||||
func (x *SCSugarRushBilled) GetOpRetCode() int32 {
|
|
||||||
if x != nil {
|
|
||||||
return x.OpRetCode
|
|
||||||
}
|
|
||||||
return 0
|
|
||||||
}
|
|
||||||
|
|
||||||
func (x *SCSugarRushBilled) GetGameEndStr() string {
|
|
||||||
if x != nil {
|
|
||||||
return x.GameEndStr
|
|
||||||
}
|
|
||||||
return ""
|
|
||||||
}
|
|
||||||
|
|
||||||
var File_protocol_sugarrush_sugarrush_proto protoreflect.FileDescriptor
|
|
||||||
|
|
||||||
var file_protocol_sugarrush_sugarrush_proto_rawDesc = []byte{
|
|
||||||
0x0a, 0x22, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x63, 0x6f, 0x6c, 0x2f, 0x73, 0x75, 0x67, 0x61, 0x72,
|
|
||||||
0x72, 0x75, 0x73, 0x68, 0x2f, 0x73, 0x75, 0x67, 0x61, 0x72, 0x72, 0x75, 0x73, 0x68, 0x2e, 0x70,
|
|
||||||
0x72, 0x6f, 0x74, 0x6f, 0x12, 0x09, 0x73, 0x75, 0x67, 0x61, 0x72, 0x72, 0x75, 0x73, 0x68, 0x22,
|
|
||||||
0xfd, 0x01, 0x0a, 0x13, 0x53, 0x75, 0x67, 0x61, 0x72, 0x52, 0x75, 0x73, 0x68, 0x50, 0x6c, 0x61,
|
|
||||||
0x79, 0x65, 0x72, 0x44, 0x61, 0x74, 0x61, 0x12, 0x12, 0x0a, 0x04, 0x4e, 0x61, 0x6d, 0x65, 0x18,
|
|
||||||
0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x4e, 0x61, 0x6d, 0x65, 0x12, 0x12, 0x0a, 0x04, 0x53,
|
|
||||||
0x6e, 0x49, 0x64, 0x18, 0x02, 0x20, 0x01, 0x28, 0x05, 0x52, 0x04, 0x53, 0x6e, 0x49, 0x64, 0x12,
|
|
||||||
0x12, 0x0a, 0x04, 0x48, 0x65, 0x61, 0x64, 0x18, 0x03, 0x20, 0x01, 0x28, 0x05, 0x52, 0x04, 0x48,
|
|
||||||
0x65, 0x61, 0x64, 0x12, 0x10, 0x0a, 0x03, 0x53, 0x65, 0x78, 0x18, 0x04, 0x20, 0x01, 0x28, 0x05,
|
|
||||||
0x52, 0x03, 0x53, 0x65, 0x78, 0x12, 0x12, 0x0a, 0x04, 0x43, 0x6f, 0x69, 0x6e, 0x18, 0x05, 0x20,
|
|
||||||
0x01, 0x28, 0x03, 0x52, 0x04, 0x43, 0x6f, 0x69, 0x6e, 0x12, 0x10, 0x0a, 0x03, 0x50, 0x6f, 0x73,
|
|
||||||
0x18, 0x06, 0x20, 0x01, 0x28, 0x05, 0x52, 0x03, 0x50, 0x6f, 0x73, 0x12, 0x12, 0x0a, 0x04, 0x46,
|
|
||||||
0x6c, 0x61, 0x67, 0x18, 0x07, 0x20, 0x01, 0x28, 0x05, 0x52, 0x04, 0x46, 0x6c, 0x61, 0x67, 0x12,
|
|
||||||
0x16, 0x0a, 0x06, 0x50, 0x61, 0x72, 0x61, 0x6d, 0x73, 0x18, 0x08, 0x20, 0x03, 0x28, 0x09, 0x52,
|
|
||||||
0x06, 0x50, 0x61, 0x72, 0x61, 0x6d, 0x73, 0x12, 0x12, 0x0a, 0x04, 0x43, 0x69, 0x74, 0x79, 0x18,
|
|
||||||
0x09, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x43, 0x69, 0x74, 0x79, 0x12, 0x20, 0x0a, 0x0b, 0x48,
|
|
||||||
0x65, 0x61, 0x64, 0x4f, 0x75, 0x74, 0x4c, 0x69, 0x6e, 0x65, 0x18, 0x0a, 0x20, 0x01, 0x28, 0x05,
|
|
||||||
0x52, 0x0b, 0x48, 0x65, 0x61, 0x64, 0x4f, 0x75, 0x74, 0x4c, 0x69, 0x6e, 0x65, 0x12, 0x10, 0x0a,
|
|
||||||
0x03, 0x56, 0x49, 0x50, 0x18, 0x0b, 0x20, 0x01, 0x28, 0x05, 0x52, 0x03, 0x56, 0x49, 0x50, 0x22,
|
|
||||||
0xe1, 0x02, 0x0a, 0x13, 0x53, 0x43, 0x53, 0x75, 0x67, 0x61, 0x72, 0x52, 0x75, 0x73, 0x68, 0x52,
|
|
||||||
0x6f, 0x6f, 0x6d, 0x49, 0x6e, 0x66, 0x6f, 0x12, 0x16, 0x0a, 0x06, 0x52, 0x6f, 0x6f, 0x6d, 0x49,
|
|
||||||
0x64, 0x18, 0x01, 0x20, 0x01, 0x28, 0x05, 0x52, 0x06, 0x52, 0x6f, 0x6f, 0x6d, 0x49, 0x64, 0x12,
|
|
||||||
0x1e, 0x0a, 0x0a, 0x47, 0x61, 0x6d, 0x65, 0x46, 0x72, 0x65, 0x65, 0x49, 0x64, 0x18, 0x02, 0x20,
|
|
||||||
0x01, 0x28, 0x05, 0x52, 0x0a, 0x47, 0x61, 0x6d, 0x65, 0x46, 0x72, 0x65, 0x65, 0x49, 0x64, 0x12,
|
|
||||||
0x16, 0x0a, 0x06, 0x47, 0x61, 0x6d, 0x65, 0x49, 0x64, 0x18, 0x03, 0x20, 0x01, 0x28, 0x05, 0x52,
|
|
||||||
0x06, 0x47, 0x61, 0x6d, 0x65, 0x49, 0x64, 0x12, 0x1a, 0x0a, 0x08, 0x52, 0x6f, 0x6f, 0x6d, 0x4d,
|
|
||||||
0x6f, 0x64, 0x65, 0x18, 0x04, 0x20, 0x01, 0x28, 0x05, 0x52, 0x08, 0x52, 0x6f, 0x6f, 0x6d, 0x4d,
|
|
||||||
0x6f, 0x64, 0x65, 0x12, 0x16, 0x0a, 0x06, 0x50, 0x61, 0x72, 0x61, 0x6d, 0x73, 0x18, 0x05, 0x20,
|
|
||||||
0x03, 0x28, 0x05, 0x52, 0x06, 0x50, 0x61, 0x72, 0x61, 0x6d, 0x73, 0x12, 0x1e, 0x0a, 0x0a, 0x4e,
|
|
||||||
0x75, 0x6d, 0x4f, 0x66, 0x47, 0x61, 0x6d, 0x65, 0x73, 0x18, 0x06, 0x20, 0x01, 0x28, 0x05, 0x52,
|
|
||||||
0x0a, 0x4e, 0x75, 0x6d, 0x4f, 0x66, 0x47, 0x61, 0x6d, 0x65, 0x73, 0x12, 0x14, 0x0a, 0x05, 0x53,
|
|
||||||
0x74, 0x61, 0x74, 0x65, 0x18, 0x07, 0x20, 0x01, 0x28, 0x05, 0x52, 0x05, 0x53, 0x74, 0x61, 0x74,
|
|
||||||
0x65, 0x12, 0x1a, 0x0a, 0x08, 0x50, 0x61, 0x72, 0x61, 0x6d, 0x73, 0x45, 0x78, 0x18, 0x08, 0x20,
|
|
||||||
0x03, 0x28, 0x03, 0x52, 0x08, 0x50, 0x61, 0x72, 0x61, 0x6d, 0x73, 0x45, 0x78, 0x12, 0x1c, 0x0a,
|
|
||||||
0x09, 0x53, 0x63, 0x65, 0x6e, 0x65, 0x54, 0x79, 0x70, 0x65, 0x18, 0x09, 0x20, 0x01, 0x28, 0x05,
|
|
||||||
0x52, 0x09, 0x53, 0x63, 0x65, 0x6e, 0x65, 0x54, 0x79, 0x70, 0x65, 0x12, 0x36, 0x0a, 0x06, 0x50,
|
|
||||||
0x6c, 0x61, 0x79, 0x65, 0x72, 0x18, 0x0a, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1e, 0x2e, 0x73, 0x75,
|
|
||||||
0x67, 0x61, 0x72, 0x72, 0x75, 0x73, 0x68, 0x2e, 0x53, 0x75, 0x67, 0x61, 0x72, 0x52, 0x75, 0x73,
|
|
||||||
0x68, 0x50, 0x6c, 0x61, 0x79, 0x65, 0x72, 0x44, 0x61, 0x74, 0x61, 0x52, 0x06, 0x50, 0x6c, 0x61,
|
|
||||||
0x79, 0x65, 0x72, 0x12, 0x1e, 0x0a, 0x0a, 0x50, 0x6c, 0x61, 0x79, 0x65, 0x72, 0x49, 0x6e, 0x66,
|
|
||||||
0x6f, 0x18, 0x0b, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0a, 0x50, 0x6c, 0x61, 0x79, 0x65, 0x72, 0x49,
|
|
||||||
0x6e, 0x66, 0x6f, 0x22, 0x3f, 0x0a, 0x0d, 0x43, 0x53, 0x53, 0x75, 0x67, 0x61, 0x72, 0x52, 0x75,
|
|
||||||
0x73, 0x68, 0x4f, 0x70, 0x12, 0x16, 0x0a, 0x06, 0x4f, 0x70, 0x43, 0x6f, 0x64, 0x65, 0x18, 0x01,
|
|
||||||
0x20, 0x01, 0x28, 0x05, 0x52, 0x06, 0x4f, 0x70, 0x43, 0x6f, 0x64, 0x65, 0x12, 0x16, 0x0a, 0x06,
|
|
||||||
0x50, 0x61, 0x72, 0x61, 0x6d, 0x73, 0x18, 0x02, 0x20, 0x03, 0x28, 0x03, 0x52, 0x06, 0x50, 0x61,
|
|
||||||
0x72, 0x61, 0x6d, 0x73, 0x22, 0x5d, 0x0a, 0x0d, 0x53, 0x43, 0x53, 0x75, 0x67, 0x61, 0x72, 0x52,
|
|
||||||
0x75, 0x73, 0x68, 0x4f, 0x70, 0x12, 0x16, 0x0a, 0x06, 0x4f, 0x70, 0x43, 0x6f, 0x64, 0x65, 0x18,
|
|
||||||
0x01, 0x20, 0x01, 0x28, 0x05, 0x52, 0x06, 0x4f, 0x70, 0x43, 0x6f, 0x64, 0x65, 0x12, 0x1c, 0x0a,
|
|
||||||
0x09, 0x4f, 0x70, 0x52, 0x65, 0x74, 0x43, 0x6f, 0x64, 0x65, 0x18, 0x02, 0x20, 0x01, 0x28, 0x05,
|
|
||||||
0x52, 0x09, 0x4f, 0x70, 0x52, 0x65, 0x74, 0x43, 0x6f, 0x64, 0x65, 0x12, 0x16, 0x0a, 0x06, 0x50,
|
|
||||||
0x61, 0x72, 0x61, 0x6d, 0x73, 0x18, 0x03, 0x20, 0x03, 0x28, 0x03, 0x52, 0x06, 0x50, 0x61, 0x72,
|
|
||||||
0x61, 0x6d, 0x73, 0x22, 0x60, 0x0a, 0x14, 0x53, 0x43, 0x53, 0x75, 0x67, 0x61, 0x72, 0x52, 0x75,
|
|
||||||
0x73, 0x68, 0x52, 0x6f, 0x6f, 0x6d, 0x53, 0x74, 0x61, 0x74, 0x65, 0x12, 0x14, 0x0a, 0x05, 0x53,
|
|
||||||
0x74, 0x61, 0x74, 0x65, 0x18, 0x01, 0x20, 0x01, 0x28, 0x05, 0x52, 0x05, 0x53, 0x74, 0x61, 0x74,
|
|
||||||
0x65, 0x12, 0x1a, 0x0a, 0x08, 0x53, 0x75, 0x62, 0x53, 0x74, 0x61, 0x74, 0x65, 0x18, 0x02, 0x20,
|
|
||||||
0x01, 0x28, 0x05, 0x52, 0x08, 0x53, 0x75, 0x62, 0x53, 0x74, 0x61, 0x74, 0x65, 0x12, 0x16, 0x0a,
|
|
||||||
0x06, 0x50, 0x61, 0x72, 0x61, 0x6d, 0x73, 0x18, 0x03, 0x20, 0x03, 0x28, 0x05, 0x52, 0x06, 0x50,
|
|
||||||
0x61, 0x72, 0x61, 0x6d, 0x73, 0x22, 0x51, 0x0a, 0x11, 0x53, 0x43, 0x53, 0x75, 0x67, 0x61, 0x72,
|
|
||||||
0x52, 0x75, 0x73, 0x68, 0x42, 0x69, 0x6c, 0x6c, 0x65, 0x64, 0x12, 0x1c, 0x0a, 0x09, 0x4f, 0x70,
|
|
||||||
0x52, 0x65, 0x74, 0x43, 0x6f, 0x64, 0x65, 0x18, 0x01, 0x20, 0x01, 0x28, 0x05, 0x52, 0x09, 0x4f,
|
|
||||||
0x70, 0x52, 0x65, 0x74, 0x43, 0x6f, 0x64, 0x65, 0x12, 0x1e, 0x0a, 0x0a, 0x47, 0x61, 0x6d, 0x65,
|
|
||||||
0x45, 0x6e, 0x64, 0x53, 0x74, 0x72, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0a, 0x47, 0x61,
|
|
||||||
0x6d, 0x65, 0x45, 0x6e, 0x64, 0x53, 0x74, 0x72, 0x2a, 0xf3, 0x01, 0x0a, 0x0c, 0x53, 0x75, 0x67,
|
|
||||||
0x61, 0x72, 0x52, 0x75, 0x73, 0x68, 0x50, 0x49, 0x44, 0x12, 0x19, 0x0a, 0x15, 0x50, 0x41, 0x43,
|
|
||||||
0x4b, 0x45, 0x54, 0x5f, 0x53, 0x55, 0x47, 0x41, 0x52, 0x52, 0x55, 0x53, 0x48, 0x5f, 0x5a, 0x45,
|
|
||||||
0x52, 0x4f, 0x10, 0x00, 0x12, 0x29, 0x0a, 0x24, 0x50, 0x41, 0x43, 0x4b, 0x45, 0x54, 0x5f, 0x53,
|
|
||||||
0x55, 0x47, 0x41, 0x52, 0x52, 0x55, 0x53, 0x48, 0x5f, 0x53, 0x43, 0x53, 0x55, 0x47, 0x41, 0x52,
|
|
||||||
0x52, 0x55, 0x53, 0x48, 0x52, 0x4f, 0x4f, 0x4d, 0x49, 0x4e, 0x46, 0x4f, 0x10, 0xc4, 0x2c, 0x12,
|
|
||||||
0x23, 0x0a, 0x1e, 0x50, 0x41, 0x43, 0x4b, 0x45, 0x54, 0x5f, 0x53, 0x55, 0x47, 0x41, 0x52, 0x52,
|
|
||||||
0x55, 0x53, 0x48, 0x5f, 0x43, 0x53, 0x53, 0x55, 0x47, 0x41, 0x52, 0x52, 0x55, 0x53, 0x48, 0x4f,
|
|
||||||
0x50, 0x10, 0xc5, 0x2c, 0x12, 0x23, 0x0a, 0x1e, 0x50, 0x41, 0x43, 0x4b, 0x45, 0x54, 0x5f, 0x53,
|
|
||||||
0x55, 0x47, 0x41, 0x52, 0x52, 0x55, 0x53, 0x48, 0x5f, 0x53, 0x43, 0x53, 0x55, 0x47, 0x41, 0x52,
|
|
||||||
0x52, 0x55, 0x53, 0x48, 0x4f, 0x50, 0x10, 0xc6, 0x2c, 0x12, 0x2a, 0x0a, 0x25, 0x50, 0x41, 0x43,
|
|
||||||
0x4b, 0x45, 0x54, 0x5f, 0x53, 0x55, 0x47, 0x41, 0x52, 0x52, 0x55, 0x53, 0x48, 0x5f, 0x53, 0x43,
|
|
||||||
0x53, 0x55, 0x47, 0x41, 0x52, 0x52, 0x55, 0x53, 0x48, 0x52, 0x4f, 0x4f, 0x4d, 0x53, 0x54, 0x41,
|
|
||||||
0x54, 0x45, 0x10, 0xc7, 0x2c, 0x12, 0x27, 0x0a, 0x22, 0x50, 0x41, 0x43, 0x4b, 0x45, 0x54, 0x5f,
|
|
||||||
0x53, 0x55, 0x47, 0x41, 0x52, 0x52, 0x55, 0x53, 0x48, 0x5f, 0x53, 0x43, 0x53, 0x55, 0x47, 0x41,
|
|
||||||
0x52, 0x52, 0x55, 0x53, 0x48, 0x42, 0x49, 0x4c, 0x4c, 0x45, 0x44, 0x10, 0xc8, 0x2c, 0x42, 0x29,
|
|
||||||
0x5a, 0x27, 0x6d, 0x6f, 0x6e, 0x67, 0x6f, 0x2e, 0x67, 0x61, 0x6d, 0x65, 0x73, 0x2e, 0x63, 0x6f,
|
|
||||||
0x6d, 0x2f, 0x67, 0x61, 0x6d, 0x65, 0x2f, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x63, 0x6f, 0x6c, 0x2f,
|
|
||||||
0x73, 0x75, 0x67, 0x61, 0x72, 0x72, 0x75, 0x73, 0x68, 0x62, 0x06, 0x70, 0x72, 0x6f, 0x74, 0x6f,
|
|
||||||
0x33,
|
|
||||||
}
|
|
||||||
|
|
||||||
var (
|
|
||||||
file_protocol_sugarrush_sugarrush_proto_rawDescOnce sync.Once
|
|
||||||
file_protocol_sugarrush_sugarrush_proto_rawDescData = file_protocol_sugarrush_sugarrush_proto_rawDesc
|
|
||||||
)
|
|
||||||
|
|
||||||
func file_protocol_sugarrush_sugarrush_proto_rawDescGZIP() []byte {
|
|
||||||
file_protocol_sugarrush_sugarrush_proto_rawDescOnce.Do(func() {
|
|
||||||
file_protocol_sugarrush_sugarrush_proto_rawDescData = protoimpl.X.CompressGZIP(file_protocol_sugarrush_sugarrush_proto_rawDescData)
|
|
||||||
})
|
|
||||||
return file_protocol_sugarrush_sugarrush_proto_rawDescData
|
|
||||||
}
|
|
||||||
|
|
||||||
var file_protocol_sugarrush_sugarrush_proto_enumTypes = make([]protoimpl.EnumInfo, 1)
|
|
||||||
var file_protocol_sugarrush_sugarrush_proto_msgTypes = make([]protoimpl.MessageInfo, 6)
|
|
||||||
var file_protocol_sugarrush_sugarrush_proto_goTypes = []interface{}{
|
|
||||||
(SugarRushPID)(0), // 0: sugarrush.SugarRushPID
|
|
||||||
(*SugarRushPlayerData)(nil), // 1: sugarrush.SugarRushPlayerData
|
|
||||||
(*SCSugarRushRoomInfo)(nil), // 2: sugarrush.SCSugarRushRoomInfo
|
|
||||||
(*CSSugarRushOp)(nil), // 3: sugarrush.CSSugarRushOp
|
|
||||||
(*SCSugarRushOp)(nil), // 4: sugarrush.SCSugarRushOp
|
|
||||||
(*SCSugarRushRoomState)(nil), // 5: sugarrush.SCSugarRushRoomState
|
|
||||||
(*SCSugarRushBilled)(nil), // 6: sugarrush.SCSugarRushBilled
|
|
||||||
}
|
|
||||||
var file_protocol_sugarrush_sugarrush_proto_depIdxs = []int32{
|
|
||||||
1, // 0: sugarrush.SCSugarRushRoomInfo.Player:type_name -> sugarrush.SugarRushPlayerData
|
|
||||||
1, // [1:1] is the sub-list for method output_type
|
|
||||||
1, // [1:1] is the sub-list for method input_type
|
|
||||||
1, // [1:1] is the sub-list for extension type_name
|
|
||||||
1, // [1:1] is the sub-list for extension extendee
|
|
||||||
0, // [0:1] is the sub-list for field type_name
|
|
||||||
}
|
|
||||||
|
|
||||||
func init() { file_protocol_sugarrush_sugarrush_proto_init() }
|
|
||||||
func file_protocol_sugarrush_sugarrush_proto_init() {
|
|
||||||
if File_protocol_sugarrush_sugarrush_proto != nil {
|
|
||||||
return
|
|
||||||
}
|
|
||||||
if !protoimpl.UnsafeEnabled {
|
|
||||||
file_protocol_sugarrush_sugarrush_proto_msgTypes[0].Exporter = func(v interface{}, i int) interface{} {
|
|
||||||
switch v := v.(*SugarRushPlayerData); i {
|
|
||||||
case 0:
|
|
||||||
return &v.state
|
|
||||||
case 1:
|
|
||||||
return &v.sizeCache
|
|
||||||
case 2:
|
|
||||||
return &v.unknownFields
|
|
||||||
default:
|
|
||||||
return nil
|
|
||||||
}
|
|
||||||
}
|
|
||||||
file_protocol_sugarrush_sugarrush_proto_msgTypes[1].Exporter = func(v interface{}, i int) interface{} {
|
|
||||||
switch v := v.(*SCSugarRushRoomInfo); i {
|
|
||||||
case 0:
|
|
||||||
return &v.state
|
|
||||||
case 1:
|
|
||||||
return &v.sizeCache
|
|
||||||
case 2:
|
|
||||||
return &v.unknownFields
|
|
||||||
default:
|
|
||||||
return nil
|
|
||||||
}
|
|
||||||
}
|
|
||||||
file_protocol_sugarrush_sugarrush_proto_msgTypes[2].Exporter = func(v interface{}, i int) interface{} {
|
|
||||||
switch v := v.(*CSSugarRushOp); i {
|
|
||||||
case 0:
|
|
||||||
return &v.state
|
|
||||||
case 1:
|
|
||||||
return &v.sizeCache
|
|
||||||
case 2:
|
|
||||||
return &v.unknownFields
|
|
||||||
default:
|
|
||||||
return nil
|
|
||||||
}
|
|
||||||
}
|
|
||||||
file_protocol_sugarrush_sugarrush_proto_msgTypes[3].Exporter = func(v interface{}, i int) interface{} {
|
|
||||||
switch v := v.(*SCSugarRushOp); i {
|
|
||||||
case 0:
|
|
||||||
return &v.state
|
|
||||||
case 1:
|
|
||||||
return &v.sizeCache
|
|
||||||
case 2:
|
|
||||||
return &v.unknownFields
|
|
||||||
default:
|
|
||||||
return nil
|
|
||||||
}
|
|
||||||
}
|
|
||||||
file_protocol_sugarrush_sugarrush_proto_msgTypes[4].Exporter = func(v interface{}, i int) interface{} {
|
|
||||||
switch v := v.(*SCSugarRushRoomState); i {
|
|
||||||
case 0:
|
|
||||||
return &v.state
|
|
||||||
case 1:
|
|
||||||
return &v.sizeCache
|
|
||||||
case 2:
|
|
||||||
return &v.unknownFields
|
|
||||||
default:
|
|
||||||
return nil
|
|
||||||
}
|
|
||||||
}
|
|
||||||
file_protocol_sugarrush_sugarrush_proto_msgTypes[5].Exporter = func(v interface{}, i int) interface{} {
|
|
||||||
switch v := v.(*SCSugarRushBilled); i {
|
|
||||||
case 0:
|
|
||||||
return &v.state
|
|
||||||
case 1:
|
|
||||||
return &v.sizeCache
|
|
||||||
case 2:
|
|
||||||
return &v.unknownFields
|
|
||||||
default:
|
|
||||||
return nil
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
type x struct{}
|
|
||||||
out := protoimpl.TypeBuilder{
|
|
||||||
File: protoimpl.DescBuilder{
|
|
||||||
GoPackagePath: reflect.TypeOf(x{}).PkgPath(),
|
|
||||||
RawDescriptor: file_protocol_sugarrush_sugarrush_proto_rawDesc,
|
|
||||||
NumEnums: 1,
|
|
||||||
NumMessages: 6,
|
|
||||||
NumExtensions: 0,
|
|
||||||
NumServices: 0,
|
|
||||||
},
|
|
||||||
GoTypes: file_protocol_sugarrush_sugarrush_proto_goTypes,
|
|
||||||
DependencyIndexes: file_protocol_sugarrush_sugarrush_proto_depIdxs,
|
|
||||||
EnumInfos: file_protocol_sugarrush_sugarrush_proto_enumTypes,
|
|
||||||
MessageInfos: file_protocol_sugarrush_sugarrush_proto_msgTypes,
|
|
||||||
}.Build()
|
|
||||||
File_protocol_sugarrush_sugarrush_proto = out.File
|
|
||||||
file_protocol_sugarrush_sugarrush_proto_rawDesc = nil
|
|
||||||
file_protocol_sugarrush_sugarrush_proto_goTypes = nil
|
|
||||||
file_protocol_sugarrush_sugarrush_proto_depIdxs = nil
|
|
||||||
}
|
|
||||||
|
|
@ -1,68 +0,0 @@
|
||||||
syntax = "proto3";
|
|
||||||
package sugarrush;
|
|
||||||
option go_package = "mongo.games.com/game/protocol/sugarrush";
|
|
||||||
|
|
||||||
//sugarrush
|
|
||||||
//龙
|
|
||||||
enum SugarRushPID {
|
|
||||||
PACKET_SUGARRUSH_ZERO = 0;// 弃用消息号
|
|
||||||
PACKET_SUGARRUSH_SCSUGARRUSHROOMINFO = 5700; //房间信息
|
|
||||||
PACKET_SUGARRUSH_CSSUGARRUSHOP = 5701;
|
|
||||||
PACKET_SUGARRUSH_SCSUGARRUSHOP = 5702;
|
|
||||||
PACKET_SUGARRUSH_SCSUGARRUSHROOMSTATE = 5703;
|
|
||||||
PACKET_SUGARRUSH_SCSUGARRUSHBILLED = 5704;
|
|
||||||
}
|
|
||||||
|
|
||||||
message SugarRushPlayerData {
|
|
||||||
string Name = 1; //名字
|
|
||||||
int32 SnId = 2; //账号
|
|
||||||
int32 Head = 3; //头像
|
|
||||||
int32 Sex = 4; //性别
|
|
||||||
int64 Coin = 5; //金币
|
|
||||||
int32 Pos = 6; //座位位置
|
|
||||||
int32 Flag = 7; //二进制标记
|
|
||||||
repeated string Params = 8; //其他数据 如:ip 等
|
|
||||||
string City = 9; //城市
|
|
||||||
int32 HeadOutLine = 10; //头像框
|
|
||||||
int32 VIP = 11;
|
|
||||||
}
|
|
||||||
//房间信息
|
|
||||||
//PACKET_SUGARRUSH_SCSUGARRUSHROOMINFO
|
|
||||||
message SCSugarRushRoomInfo {
|
|
||||||
int32 RoomId = 1; //房间id
|
|
||||||
int32 GameFreeId = 2;
|
|
||||||
int32 GameId = 3; //游戏id
|
|
||||||
int32 RoomMode = 4; //游戏模式
|
|
||||||
repeated int32 Params = 5; //规则参数
|
|
||||||
int32 NumOfGames = 6; //当前第几局
|
|
||||||
int32 State = 7; //房间当前状态
|
|
||||||
repeated int64 ParamsEx = 8; //其他参数
|
|
||||||
int32 SceneType = 9; //房间模式
|
|
||||||
SugarRushPlayerData Player = 10; //房间内的玩家信息
|
|
||||||
string PlayerInfo = 11;
|
|
||||||
}
|
|
||||||
//玩家操作
|
|
||||||
//PACKET_SUGARRUSH_CSSUGARRUSHOP
|
|
||||||
message CSSugarRushOp {
|
|
||||||
int32 OpCode = 1; //操作码 0.spin
|
|
||||||
repeated int64 Params = 2; //操作参数 cval
|
|
||||||
}
|
|
||||||
//玩家操作返回
|
|
||||||
//PACKET_SUGARRUSH_SCSUGARRUSHOP
|
|
||||||
message SCSugarRushOp {
|
|
||||||
int32 OpCode = 1; //操作码
|
|
||||||
int32 OpRetCode = 2; //操作结果 1.金币不足 2.低于该值不能押注
|
|
||||||
repeated int64 Params = 3; //操作参数
|
|
||||||
}
|
|
||||||
//房间状态
|
|
||||||
//PACKET_SUGARRUSH_SCSUGARRUSHROOMSTATE
|
|
||||||
message SCSugarRushRoomState {
|
|
||||||
int32 State = 1; //房间当前状态
|
|
||||||
int32 SubState = 2; //房间当前子状态
|
|
||||||
repeated int32 Params = 3; //状态参数
|
|
||||||
}
|
|
||||||
//PACKET_SUGARRUSH_SCSUGARRUSHBILLED
|
|
||||||
message SCSugarRushBilled{
|
|
||||||
int32 OpRetCode = 1;//0.spin成功 1.spin失败
|
|
||||||
string GameEndStr = 2;
|
|
||||||
}
|
|
||||||
Loading…
Reference in New Issue