SplineCurve.fromJson constructor

SplineCurve.fromJson(
  1. Map<String, dynamic> json
)

Implementation

SplineCurve.fromJson(Map<String, dynamic> json) : super.fromJson(json) {
  points = [];

  for (int i = 0, l = json["points"].length; i < l; i++) {
    final point = json["points"][i];
    points.add(Vector2().copyFromArray(point));
  }

  isSplineCurve = true;
}