Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Sign in / Register
Toggle navigation
N
Neos
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Locked Files
Issues
0
Issues
0
List
Boards
Labels
Service Desk
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Security & Compliance
Security & Compliance
Dependency List
License Compliance
Packages
Packages
List
Container Registry
Analytics
Analytics
CI / CD
Code Review
Insights
Issues
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
baichixing
Neos
Commits
b87313f2
Commit
b87313f2
authored
Jan 02, 2023
by
Chunchi Che
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
sync neos-protobuf
parent
236be9ff
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
184 additions
and
4 deletions
+184
-4
neos-protobuf
neos-protobuf
+1
-1
src/api/ocgcore/idl/ocgcore.ts
src/api/ocgcore/idl/ocgcore.ts
+183
-3
No files found.
neos-protobuf
@
ce0785c4
Subproject commit
edc9a6499522f229017e28d97d7a8d07cffdbb1e
Subproject commit
ce0785c4d31475d9ecf6a400f45b114b66f40b4f
src/api/ocgcore/idl/ocgcore.ts
View file @
b87313f2
...
@@ -2412,7 +2412,7 @@ export namespace ygopro {
...
@@ -2412,7 +2412,7 @@ export namespace ygopro {
}
}
}
}
export
class
CtosGameMsgResponse
extends
pb_1
.
Message
{
export
class
CtosGameMsgResponse
extends
pb_1
.
Message
{
#
one_of_decls
:
number
[][]
=
[[
1
,
2
]];
#
one_of_decls
:
number
[][]
=
[[
1
,
2
,
3
]];
constructor
(
constructor
(
data
?:
data
?:
|
any
[]
|
any
[]
...
@@ -2420,10 +2420,17 @@ export namespace ygopro {
...
@@ -2420,10 +2420,17 @@ export namespace ygopro {
|
{
|
{
select_idle_cmd
?:
CtosGameMsgResponse
.
SelectIdleCmdResponse
;
select_idle_cmd
?:
CtosGameMsgResponse
.
SelectIdleCmdResponse
;
select_place
?:
never
;
select_place
?:
never
;
select_card
?:
never
;
}
}
|
{
|
{
select_idle_cmd
?:
never
;
select_idle_cmd
?:
never
;
select_place
?:
CtosGameMsgResponse
.
SelectPlaceResponse
;
select_place
?:
CtosGameMsgResponse
.
SelectPlaceResponse
;
select_card
?:
never
;
}
|
{
select_idle_cmd
?:
never
;
select_place
?:
never
;
select_card
?:
CtosGameMsgResponse
.
SelectCardResponse
;
}
}
))
))
)
{
)
{
...
@@ -2443,6 +2450,9 @@ export namespace ygopro {
...
@@ -2443,6 +2450,9 @@ export namespace ygopro {
if
(
"
select_place
"
in
data
&&
data
.
select_place
!=
undefined
)
{
if
(
"
select_place
"
in
data
&&
data
.
select_place
!=
undefined
)
{
this
.
select_place
=
data
.
select_place
;
this
.
select_place
=
data
.
select_place
;
}
}
if
(
"
select_card
"
in
data
&&
data
.
select_card
!=
undefined
)
{
this
.
select_card
=
data
.
select_card
;
}
}
}
}
}
get
select_idle_cmd
()
{
get
select_idle_cmd
()
{
...
@@ -2471,15 +2481,33 @@ export namespace ygopro {
...
@@ -2471,15 +2481,33 @@ export namespace ygopro {
get
has_select_place
()
{
get
has_select_place
()
{
return
pb_1
.
Message
.
getField
(
this
,
2
)
!=
null
;
return
pb_1
.
Message
.
getField
(
this
,
2
)
!=
null
;
}
}
get
select_card
()
{
return
pb_1
.
Message
.
getWrapperField
(
this
,
CtosGameMsgResponse
.
SelectCardResponse
,
3
)
as
CtosGameMsgResponse
.
SelectCardResponse
;
}
set
select_card
(
value
:
CtosGameMsgResponse
.
SelectCardResponse
)
{
pb_1
.
Message
.
setOneofWrapperField
(
this
,
3
,
this
.
#
one_of_decls
[
0
],
value
);
}
get
has_select_card
()
{
return
pb_1
.
Message
.
getField
(
this
,
3
)
!=
null
;
}
get
gameMsgResponse
()
{
get
gameMsgResponse
()
{
const
cases
:
{
const
cases
:
{
[
index
:
number
]:
"
none
"
|
"
select_idle_cmd
"
|
"
select_place
"
;
[
index
:
number
]:
|
"
none
"
|
"
select_idle_cmd
"
|
"
select_place
"
|
"
select_card
"
;
}
=
{
}
=
{
0
:
"
none
"
,
0
:
"
none
"
,
1
:
"
select_idle_cmd
"
,
1
:
"
select_idle_cmd
"
,
2
:
"
select_place
"
,
2
:
"
select_place
"
,
3
:
"
select_card
"
,
};
};
return
cases
[
pb_1
.
Message
.
computeOneofCase
(
this
,
[
1
,
2
])];
return
cases
[
pb_1
.
Message
.
computeOneofCase
(
this
,
[
1
,
2
,
3
])];
}
}
static
fromObject
(
data
:
{
static
fromObject
(
data
:
{
select_idle_cmd
?:
ReturnType
<
select_idle_cmd
?:
ReturnType
<
...
@@ -2488,6 +2516,9 @@ export namespace ygopro {
...
@@ -2488,6 +2516,9 @@ export namespace ygopro {
select_place
?:
ReturnType
<
select_place
?:
ReturnType
<
typeof
CtosGameMsgResponse
.
SelectPlaceResponse
.
prototype
.
toObject
typeof
CtosGameMsgResponse
.
SelectPlaceResponse
.
prototype
.
toObject
>
;
>
;
select_card
?:
ReturnType
<
typeof
CtosGameMsgResponse
.
SelectCardResponse
.
prototype
.
toObject
>
;
}):
CtosGameMsgResponse
{
}):
CtosGameMsgResponse
{
const
message
=
new
CtosGameMsgResponse
({});
const
message
=
new
CtosGameMsgResponse
({});
if
(
data
.
select_idle_cmd
!=
null
)
{
if
(
data
.
select_idle_cmd
!=
null
)
{
...
@@ -2500,6 +2531,11 @@ export namespace ygopro {
...
@@ -2500,6 +2531,11 @@ export namespace ygopro {
message
.
select_place
=
message
.
select_place
=
CtosGameMsgResponse
.
SelectPlaceResponse
.
fromObject
(
data
.
select_place
);
CtosGameMsgResponse
.
SelectPlaceResponse
.
fromObject
(
data
.
select_place
);
}
}
if
(
data
.
select_card
!=
null
)
{
message
.
select_card
=
CtosGameMsgResponse
.
SelectCardResponse
.
fromObject
(
data
.
select_card
);
}
return
message
;
return
message
;
}
}
toObject
()
{
toObject
()
{
...
@@ -2510,6 +2546,9 @@ export namespace ygopro {
...
@@ -2510,6 +2546,9 @@ export namespace ygopro {
select_place
?:
ReturnType
<
select_place
?:
ReturnType
<
typeof
CtosGameMsgResponse
.
SelectPlaceResponse
.
prototype
.
toObject
typeof
CtosGameMsgResponse
.
SelectPlaceResponse
.
prototype
.
toObject
>
;
>
;
select_card
?:
ReturnType
<
typeof
CtosGameMsgResponse
.
SelectCardResponse
.
prototype
.
toObject
>
;
}
=
{};
}
=
{};
if
(
this
.
select_idle_cmd
!=
null
)
{
if
(
this
.
select_idle_cmd
!=
null
)
{
data
.
select_idle_cmd
=
this
.
select_idle_cmd
.
toObject
();
data
.
select_idle_cmd
=
this
.
select_idle_cmd
.
toObject
();
...
@@ -2517,6 +2556,9 @@ export namespace ygopro {
...
@@ -2517,6 +2556,9 @@ export namespace ygopro {
if
(
this
.
select_place
!=
null
)
{
if
(
this
.
select_place
!=
null
)
{
data
.
select_place
=
this
.
select_place
.
toObject
();
data
.
select_place
=
this
.
select_place
.
toObject
();
}
}
if
(
this
.
select_card
!=
null
)
{
data
.
select_card
=
this
.
select_card
.
toObject
();
}
return
data
;
return
data
;
}
}
serialize
():
Uint8Array
;
serialize
():
Uint8Array
;
...
@@ -2531,6 +2573,10 @@ export namespace ygopro {
...
@@ -2531,6 +2573,10 @@ export namespace ygopro {
writer
.
writeMessage
(
2
,
this
.
select_place
,
()
=>
writer
.
writeMessage
(
2
,
this
.
select_place
,
()
=>
this
.
select_place
.
serialize
(
writer
)
this
.
select_place
.
serialize
(
writer
)
);
);
if
(
this
.
has_select_card
)
writer
.
writeMessage
(
3
,
this
.
select_card
,
()
=>
this
.
select_card
.
serialize
(
writer
)
);
if
(
!
w
)
return
writer
.
getResultBuffer
();
if
(
!
w
)
return
writer
.
getResultBuffer
();
}
}
static
deserialize
(
static
deserialize
(
...
@@ -2560,6 +2606,14 @@ export namespace ygopro {
...
@@ -2560,6 +2606,14 @@ export namespace ygopro {
CtosGameMsgResponse
.
SelectPlaceResponse
.
deserialize
(
reader
))
CtosGameMsgResponse
.
SelectPlaceResponse
.
deserialize
(
reader
))
);
);
break
;
break
;
case
3
:
reader
.
readMessage
(
message
.
select_card
,
()
=>
(
message
.
select_card
=
CtosGameMsgResponse
.
SelectCardResponse
.
deserialize
(
reader
))
);
break
;
default
:
default
:
reader
.
skipField
();
reader
.
skipField
();
}
}
...
@@ -2784,6 +2838,110 @@ export namespace ygopro {
...
@@ -2784,6 +2838,110 @@ export namespace ygopro {
return
SelectPlaceResponse
.
deserialize
(
bytes
);
return
SelectPlaceResponse
.
deserialize
(
bytes
);
}
}
}
}
export
class
SelectCardResponse
extends
pb_1
.
Message
{
#
one_of_decls
:
number
[][]
=
[];
constructor
(
data
?:
|
any
[]
|
{
count
?:
number
;
select_ptr
?:
number
[];
}
)
{
super
();
pb_1
.
Message
.
initialize
(
this
,
Array
.
isArray
(
data
)
?
data
:
[],
0
,
-
1
,
[
2
],
this
.
#
one_of_decls
);
if
(
!
Array
.
isArray
(
data
)
&&
typeof
data
==
"
object
"
)
{
if
(
"
count
"
in
data
&&
data
.
count
!=
undefined
)
{
this
.
count
=
data
.
count
;
}
if
(
"
select_ptr
"
in
data
&&
data
.
select_ptr
!=
undefined
)
{
this
.
select_ptr
=
data
.
select_ptr
;
}
}
}
get
count
()
{
return
pb_1
.
Message
.
getFieldWithDefault
(
this
,
1
,
0
)
as
number
;
}
set
count
(
value
:
number
)
{
pb_1
.
Message
.
setField
(
this
,
1
,
value
);
}
get
select_ptr
()
{
return
pb_1
.
Message
.
getFieldWithDefault
(
this
,
2
,
[])
as
number
[];
}
set
select_ptr
(
value
:
number
[])
{
pb_1
.
Message
.
setField
(
this
,
2
,
value
);
}
static
fromObject
(
data
:
{
count
?:
number
;
select_ptr
?:
number
[];
}):
SelectCardResponse
{
const
message
=
new
SelectCardResponse
({});
if
(
data
.
count
!=
null
)
{
message
.
count
=
data
.
count
;
}
if
(
data
.
select_ptr
!=
null
)
{
message
.
select_ptr
=
data
.
select_ptr
;
}
return
message
;
}
toObject
()
{
const
data
:
{
count
?:
number
;
select_ptr
?:
number
[];
}
=
{};
if
(
this
.
count
!=
null
)
{
data
.
count
=
this
.
count
;
}
if
(
this
.
select_ptr
!=
null
)
{
data
.
select_ptr
=
this
.
select_ptr
;
}
return
data
;
}
serialize
():
Uint8Array
;
serialize
(
w
:
pb_1
.
BinaryWriter
):
void
;
serialize
(
w
?:
pb_1
.
BinaryWriter
):
Uint8Array
|
void
{
const
writer
=
w
||
new
pb_1
.
BinaryWriter
();
if
(
this
.
count
!=
0
)
writer
.
writeInt32
(
1
,
this
.
count
);
if
(
this
.
select_ptr
.
length
)
writer
.
writePackedInt32
(
2
,
this
.
select_ptr
);
if
(
!
w
)
return
writer
.
getResultBuffer
();
}
static
deserialize
(
bytes
:
Uint8Array
|
pb_1
.
BinaryReader
):
SelectCardResponse
{
const
reader
=
bytes
instanceof
pb_1
.
BinaryReader
?
bytes
:
new
pb_1
.
BinaryReader
(
bytes
),
message
=
new
SelectCardResponse
();
while
(
reader
.
nextField
())
{
if
(
reader
.
isEndGroup
())
break
;
switch
(
reader
.
getFieldNumber
())
{
case
1
:
message
.
count
=
reader
.
readInt32
();
break
;
case
2
:
message
.
select_ptr
=
reader
.
readPackedInt32
();
break
;
default
:
reader
.
skipField
();
}
}
return
message
;
}
serializeBinary
():
Uint8Array
{
return
this
.
serialize
();
}
static
deserializeBinary
(
bytes
:
Uint8Array
):
SelectCardResponse
{
return
SelectCardResponse
.
deserialize
(
bytes
);
}
}
}
}
export
class
StocJoinGame
extends
pb_1
.
Message
{
export
class
StocJoinGame
extends
pb_1
.
Message
{
#
one_of_decls
:
number
[][]
=
[];
#
one_of_decls
:
number
[][]
=
[];
...
@@ -6508,6 +6666,7 @@ export namespace ygopro {
...
@@ -6508,6 +6666,7 @@ export namespace ygopro {
|
{
|
{
code
?:
number
;
code
?:
number
;
location
?:
CardLocation
;
location
?:
CardLocation
;
response
?:
number
;
}
}
)
{
)
{
super
();
super
();
...
@@ -6526,6 +6685,9 @@ export namespace ygopro {
...
@@ -6526,6 +6685,9 @@ export namespace ygopro {
if
(
"
location
"
in
data
&&
data
.
location
!=
undefined
)
{
if
(
"
location
"
in
data
&&
data
.
location
!=
undefined
)
{
this
.
location
=
data
.
location
;
this
.
location
=
data
.
location
;
}
}
if
(
"
response
"
in
data
&&
data
.
response
!=
undefined
)
{
this
.
response
=
data
.
response
;
}
}
}
}
}
get
code
()
{
get
code
()
{
...
@@ -6547,9 +6709,16 @@ export namespace ygopro {
...
@@ -6547,9 +6709,16 @@ export namespace ygopro {
get
has_location
()
{
get
has_location
()
{
return
pb_1
.
Message
.
getField
(
this
,
2
)
!=
null
;
return
pb_1
.
Message
.
getField
(
this
,
2
)
!=
null
;
}
}
get
response
()
{
return
pb_1
.
Message
.
getFieldWithDefault
(
this
,
3
,
0
)
as
number
;
}
set
response
(
value
:
number
)
{
pb_1
.
Message
.
setField
(
this
,
3
,
value
);
}
static
fromObject
(
data
:
{
static
fromObject
(
data
:
{
code
?:
number
;
code
?:
number
;
location
?:
ReturnType
<
typeof
CardLocation
.
prototype
.
toObject
>
;
location
?:
ReturnType
<
typeof
CardLocation
.
prototype
.
toObject
>
;
response
?:
number
;
}):
SelectAbleCard
{
}):
SelectAbleCard
{
const
message
=
new
SelectAbleCard
({});
const
message
=
new
SelectAbleCard
({});
if
(
data
.
code
!=
null
)
{
if
(
data
.
code
!=
null
)
{
...
@@ -6558,12 +6727,16 @@ export namespace ygopro {
...
@@ -6558,12 +6727,16 @@ export namespace ygopro {
if
(
data
.
location
!=
null
)
{
if
(
data
.
location
!=
null
)
{
message
.
location
=
CardLocation
.
fromObject
(
data
.
location
);
message
.
location
=
CardLocation
.
fromObject
(
data
.
location
);
}
}
if
(
data
.
response
!=
null
)
{
message
.
response
=
data
.
response
;
}
return
message
;
return
message
;
}
}
toObject
()
{
toObject
()
{
const
data
:
{
const
data
:
{
code
?:
number
;
code
?:
number
;
location
?:
ReturnType
<
typeof
CardLocation
.
prototype
.
toObject
>
;
location
?:
ReturnType
<
typeof
CardLocation
.
prototype
.
toObject
>
;
response
?:
number
;
}
=
{};
}
=
{};
if
(
this
.
code
!=
null
)
{
if
(
this
.
code
!=
null
)
{
data
.
code
=
this
.
code
;
data
.
code
=
this
.
code
;
...
@@ -6571,6 +6744,9 @@ export namespace ygopro {
...
@@ -6571,6 +6744,9 @@ export namespace ygopro {
if
(
this
.
location
!=
null
)
{
if
(
this
.
location
!=
null
)
{
data
.
location
=
this
.
location
.
toObject
();
data
.
location
=
this
.
location
.
toObject
();
}
}
if
(
this
.
response
!=
null
)
{
data
.
response
=
this
.
response
;
}
return
data
;
return
data
;
}
}
serialize
():
Uint8Array
;
serialize
():
Uint8Array
;
...
@@ -6582,6 +6758,7 @@ export namespace ygopro {
...
@@ -6582,6 +6758,7 @@ export namespace ygopro {
writer
.
writeMessage
(
2
,
this
.
location
,
()
=>
writer
.
writeMessage
(
2
,
this
.
location
,
()
=>
this
.
location
.
serialize
(
writer
)
this
.
location
.
serialize
(
writer
)
);
);
if
(
this
.
response
!=
0
)
writer
.
writeInt32
(
3
,
this
.
response
);
if
(
!
w
)
return
writer
.
getResultBuffer
();
if
(
!
w
)
return
writer
.
getResultBuffer
();
}
}
static
deserialize
(
static
deserialize
(
...
@@ -6604,6 +6781,9 @@ export namespace ygopro {
...
@@ -6604,6 +6781,9 @@ export namespace ygopro {
()
=>
(
message
.
location
=
CardLocation
.
deserialize
(
reader
))
()
=>
(
message
.
location
=
CardLocation
.
deserialize
(
reader
))
);
);
break
;
break
;
case
3
:
message
.
response
=
reader
.
readInt32
();
break
;
default
:
default
:
reader
.
skipField
();
reader
.
skipField
();
}
}
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment