toJSON method
Transforms this instance into a JSON object.
Implementation
@override
Map<String,dynamic> toJSON() {
final json = super.toJSON();
json['velocity'] = velocity.storage;
json['maxSpeed'] = maxSpeed;
json['updateOrientation'] = updateOrientation;
return json;
}