|
|
@ -7,8 +7,12 @@ import (
|
|
|
|
|
|
|
|
|
|
|
|
var atom_types = map[string]typeFn{
|
|
|
|
var atom_types = map[string]typeFn{
|
|
|
|
"uint16": func(r bit.Reader) (value, error) {
|
|
|
|
"uint16": func(r bit.Reader) (value, error) {
|
|
|
|
|
|
|
|
// TODO: bounds check here
|
|
|
|
return uint16(bit.ReadVarInt(r)), r.Err()
|
|
|
|
return uint16(bit.ReadVarInt(r)), r.Err()
|
|
|
|
},
|
|
|
|
},
|
|
|
|
|
|
|
|
"int32": func(r bit.Reader) (value, error) {
|
|
|
|
|
|
|
|
return int32(bit.ReadZigZag32(r)), r.Err()
|
|
|
|
|
|
|
|
},
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
func atomType(flat *dota.ProtoFlattenedSerializerFieldT, env *Env) tÿpe {
|
|
|
|
func atomType(flat *dota.ProtoFlattenedSerializerFieldT, env *Env) tÿpe {
|
|
|
|