Skip to content

Commit

Permalink
Fix warnings
Browse files Browse the repository at this point in the history
  • Loading branch information
RblSb committed Feb 14, 2024
1 parent 8da415e commit 5f78de7
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 5 deletions.
7 changes: 4 additions & 3 deletions echo/Body.hx
Original file line number Diff line number Diff line change
Expand Up @@ -241,12 +241,13 @@ class Body implements Disposable #if cog implements cog.IComponent #end {
scale_y = options.scale_y;
kinematic = options.kinematic;

final noWarnOptions:Dynamic = options;
if (options.material != null) material = options.material;
else if (options.gravity_scale != null || options.elasticity != null) {
else if (noWarnOptions.gravity_scale != null || noWarnOptions.elasticity != null) {
// Temp: Support deprecated values
material = {
elasticity: options.elasticity,
gravity_scale: options.gravity_scale
elasticity: noWarnOptions.elasticity,
gravity_scale: noWarnOptions.gravity_scale
}
}
else material = Material.global;
Expand Down
3 changes: 1 addition & 2 deletions echo/data/Data.hx
Original file line number Diff line number Diff line change
Expand Up @@ -244,7 +244,6 @@ class QuadTreeData {
public var flag = false;
}

@:enum
abstract Direction(Int) from Int to Int {
enum abstract Direction(Int) from Int to Int {
var TOP = 0;
}

0 comments on commit 5f78de7

Please sign in to comment.