Skip to content

Commit

Permalink
Draw bounds of P3Container children, and their children
Browse files Browse the repository at this point in the history
  • Loading branch information
rexrainbow committed Oct 8, 2024
1 parent cb88cc3 commit 21fa9cc
Show file tree
Hide file tree
Showing 159 changed files with 1,503 additions and 318 deletions.
32 changes: 28 additions & 4 deletions dist/rexbadgelabel.js
Original file line number Diff line number Diff line change
Expand Up @@ -1612,7 +1612,7 @@
}
};

var P3Container = {
var P3Container$2 = {
addToContainer(p3Container) {
if (!IsContainerGameObject(p3Container)) {
return this;
Expand Down Expand Up @@ -1847,6 +1847,7 @@
const Rectangle$3 = Phaser.Geom.Rectangle;
const Vector2 = Phaser.Math.Vector2;
const RotateAround$2 = Phaser.Math.RotateAround;
const P3Container$1 = Phaser.GameObjects.Container;

var GetBounds = function (gameObject, output) {
if (output === undefined) {
Expand All @@ -1858,7 +1859,7 @@
output = GlobRect$2;
}

if (gameObject.getBounds) {
if (gameObject.getBounds && !(gameObject instanceof P3Container$1)) {
return gameObject.getBounds(output);
}

Expand Down Expand Up @@ -2379,7 +2380,7 @@
Depth,
Children,
Tween,
P3Container,
P3Container$2,
RenderLayer,
RenderTexture,
);
Expand Down Expand Up @@ -3084,6 +3085,7 @@

const GetValue$D = Phaser.Utils.Objects.GetValue;
const Group = Phaser.GameObjects.Group;
const P3Container = Phaser.GameObjects.Container;

var DrawBounds = function (graphics, config) {
var scene = graphics.scene;
Expand Down Expand Up @@ -3126,7 +3128,10 @@
};
}

var children = this.getAllShownChildren([this]), child;
var children = this.getAllShownChildren([this]);
children.push(...GetP3ContainerChildren(children));

var child;
var nameText;
for (var i = 0, cnt = children.length; i < cnt; i++) {
child = children[i];
Expand Down Expand Up @@ -3165,6 +3170,25 @@
return scene.add.text(0, 0, '');
};

var GetP3ContainerChildren = function (gameObjects, output) {
if (!Array.isArray(gameObjects)) {
gameObjects = [gameObjects];
}
if (output === undefined) {
output = [];
}

for (var i = 0, cnt = gameObjects.length; i < cnt; i++) {
var gameObject = gameObjects[i];
if (gameObject instanceof P3Container) {
output.push(...gameObject.list);
GetP3ContainerChildren(gameObject.list, output);
}
}

return output;
};

var GlobRect = undefined;

const GetValue$C = Phaser.Utils.Objects.GetValue;
Expand Down
2 changes: 1 addition & 1 deletion dist/rexbadgelabel.min.js

Large diffs are not rendered by default.

3 changes: 2 additions & 1 deletion dist/rexboardplugin.js
Original file line number Diff line number Diff line change
Expand Up @@ -7164,6 +7164,7 @@
const Rectangle$1 = Phaser.Geom.Rectangle;
const Vector2 = Phaser.Math.Vector2;
const RotateAround$1 = Phaser.Math.RotateAround;
const P3Container$1 = Phaser.GameObjects.Container;

var GetBounds$1 = function (gameObject, output) {
if (output === undefined) {
Expand All @@ -7175,7 +7176,7 @@
output = GlobRect$1;
}

if (gameObject.getBounds) {
if (gameObject.getBounds && !(gameObject instanceof P3Container$1)) {
return gameObject.getBounds(output);
}

Expand Down
2 changes: 1 addition & 1 deletion dist/rexboardplugin.min.js

Large diffs are not rendered by default.

3 changes: 2 additions & 1 deletion dist/rexboundsplugin.js
Original file line number Diff line number Diff line change
Expand Up @@ -399,6 +399,7 @@
const Rectangle$1 = Phaser.Geom.Rectangle;
const Vector2 = Phaser.Math.Vector2;
const RotateAround = Phaser.Math.RotateAround;
const P3Container = Phaser.GameObjects.Container;

var GetBounds = function (gameObject, output) {
if (output === undefined) {
Expand All @@ -410,7 +411,7 @@
output = GlobRect;
}

if (gameObject.getBounds) {
if (gameObject.getBounds && !(gameObject instanceof P3Container)) {
return gameObject.getBounds(output);
}

Expand Down
2 changes: 1 addition & 1 deletion dist/rexboundsplugin.min.js

Large diffs are not rendered by default.

32 changes: 28 additions & 4 deletions dist/rexbuttons.js
Original file line number Diff line number Diff line change
Expand Up @@ -1612,7 +1612,7 @@
}
};

var P3Container = {
var P3Container$2 = {
addToContainer(p3Container) {
if (!IsContainerGameObject(p3Container)) {
return this;
Expand Down Expand Up @@ -1847,6 +1847,7 @@
const Rectangle$3 = Phaser.Geom.Rectangle;
const Vector2 = Phaser.Math.Vector2;
const RotateAround$2 = Phaser.Math.RotateAround;
const P3Container$1 = Phaser.GameObjects.Container;

var GetBounds = function (gameObject, output) {
if (output === undefined) {
Expand All @@ -1858,7 +1859,7 @@
output = GlobRect$2;
}

if (gameObject.getBounds) {
if (gameObject.getBounds && !(gameObject instanceof P3Container$1)) {
return gameObject.getBounds(output);
}

Expand Down Expand Up @@ -2379,7 +2380,7 @@
Depth,
Children,
Tween,
P3Container,
P3Container$2,
RenderLayer,
RenderTexture,
);
Expand Down Expand Up @@ -3084,6 +3085,7 @@

const GetValue$E = Phaser.Utils.Objects.GetValue;
const Group = Phaser.GameObjects.Group;
const P3Container = Phaser.GameObjects.Container;

var DrawBounds = function (graphics, config) {
var scene = graphics.scene;
Expand Down Expand Up @@ -3126,7 +3128,10 @@
};
}

var children = this.getAllShownChildren([this]), child;
var children = this.getAllShownChildren([this]);
children.push(...GetP3ContainerChildren(children));

var child;
var nameText;
for (var i = 0, cnt = children.length; i < cnt; i++) {
child = children[i];
Expand Down Expand Up @@ -3165,6 +3170,25 @@
return scene.add.text(0, 0, '');
};

var GetP3ContainerChildren = function (gameObjects, output) {
if (!Array.isArray(gameObjects)) {
gameObjects = [gameObjects];
}
if (output === undefined) {
output = [];
}

for (var i = 0, cnt = gameObjects.length; i < cnt; i++) {
var gameObject = gameObjects[i];
if (gameObject instanceof P3Container) {
output.push(...gameObject.list);
GetP3ContainerChildren(gameObject.list, output);
}
}

return output;
};

var GlobRect = undefined;

const GetValue$D = Phaser.Utils.Objects.GetValue;
Expand Down
2 changes: 1 addition & 1 deletion dist/rexbuttons.min.js

Large diffs are not rendered by default.

3 changes: 2 additions & 1 deletion dist/rexcameracontrollerplugin.js
Original file line number Diff line number Diff line change
Expand Up @@ -352,6 +352,7 @@
const Rectangle$1 = Phaser.Geom.Rectangle;
const Vector2 = Phaser.Math.Vector2;
const RotateAround$1 = Phaser.Math.RotateAround;
const P3Container = Phaser.GameObjects.Container;

var GetBounds = function (gameObject, output) {
if (output === undefined) {
Expand All @@ -363,7 +364,7 @@
output = GlobRect;
}

if (gameObject.getBounds) {
if (gameObject.getBounds && !(gameObject instanceof P3Container)) {
return gameObject.getBounds(output);
}

Expand Down
2 changes: 1 addition & 1 deletion dist/rexcameracontrollerplugin.min.js

Large diffs are not rendered by default.

3 changes: 2 additions & 1 deletion dist/rexclickoutsideplugin.js
Original file line number Diff line number Diff line change
Expand Up @@ -304,6 +304,7 @@
const Rectangle = Phaser.Geom.Rectangle;
const Vector2 = Phaser.Math.Vector2;
const RotateAround = Phaser.Math.RotateAround;
const P3Container = Phaser.GameObjects.Container;

var GetBounds = function (gameObject, output) {
if (output === undefined) {
Expand All @@ -315,7 +316,7 @@
output = GlobRect;
}

if (gameObject.getBounds) {
if (gameObject.getBounds && !(gameObject instanceof P3Container)) {
return gameObject.getBounds(output);
}

Expand Down
2 changes: 1 addition & 1 deletion dist/rexclickoutsideplugin.min.js

Large diffs are not rendered by default.

32 changes: 28 additions & 4 deletions dist/rexcolorcomponents.js
Original file line number Diff line number Diff line change
Expand Up @@ -1612,7 +1612,7 @@
}
};

var P3Container = {
var P3Container$2 = {
addToContainer(p3Container) {
if (!IsContainerGameObject(p3Container)) {
return this;
Expand Down Expand Up @@ -1847,6 +1847,7 @@
const Rectangle$5 = Phaser.Geom.Rectangle;
const Vector2 = Phaser.Math.Vector2;
const RotateAround$5 = Phaser.Math.RotateAround;
const P3Container$1 = Phaser.GameObjects.Container;

var GetBounds = function (gameObject, output) {
if (output === undefined) {
Expand All @@ -1858,7 +1859,7 @@
output = GlobRect$2;
}

if (gameObject.getBounds) {
if (gameObject.getBounds && !(gameObject instanceof P3Container$1)) {
return gameObject.getBounds(output);
}

Expand Down Expand Up @@ -2379,7 +2380,7 @@
Depth,
Children,
Tween,
P3Container,
P3Container$2,
RenderLayer,
RenderTexture$1,
);
Expand Down Expand Up @@ -3084,6 +3085,7 @@

const GetValue$1p = Phaser.Utils.Objects.GetValue;
const Group = Phaser.GameObjects.Group;
const P3Container = Phaser.GameObjects.Container;

var DrawBounds = function (graphics, config) {
var scene = graphics.scene;
Expand Down Expand Up @@ -3126,7 +3128,10 @@
};
}

var children = this.getAllShownChildren([this]), child;
var children = this.getAllShownChildren([this]);
children.push(...GetP3ContainerChildren(children));

var child;
var nameText;
for (var i = 0, cnt = children.length; i < cnt; i++) {
child = children[i];
Expand Down Expand Up @@ -3165,6 +3170,25 @@
return scene.add.text(0, 0, '');
};

var GetP3ContainerChildren = function (gameObjects, output) {
if (!Array.isArray(gameObjects)) {
gameObjects = [gameObjects];
}
if (output === undefined) {
output = [];
}

for (var i = 0, cnt = gameObjects.length; i < cnt; i++) {
var gameObject = gameObjects[i];
if (gameObject instanceof P3Container) {
output.push(...gameObject.list);
GetP3ContainerChildren(gameObject.list, output);
}
}

return output;
};

var GlobRect = undefined;

const GetValue$1o = Phaser.Utils.Objects.GetValue;
Expand Down
4 changes: 2 additions & 2 deletions dist/rexcolorcomponents.min.js

Large diffs are not rendered by default.

32 changes: 28 additions & 4 deletions dist/rexcolorinput.js
Original file line number Diff line number Diff line change
Expand Up @@ -1612,7 +1612,7 @@
}
};

var P3Container = {
var P3Container$2 = {
addToContainer(p3Container) {
if (!IsContainerGameObject(p3Container)) {
return this;
Expand Down Expand Up @@ -1847,6 +1847,7 @@
const Rectangle$5 = Phaser.Geom.Rectangle;
const Vector2 = Phaser.Math.Vector2;
const RotateAround$6 = Phaser.Math.RotateAround;
const P3Container$1 = Phaser.GameObjects.Container;

var GetBounds = function (gameObject, output) {
if (output === undefined) {
Expand All @@ -1858,7 +1859,7 @@
output = GlobRect$2;
}

if (gameObject.getBounds) {
if (gameObject.getBounds && !(gameObject instanceof P3Container$1)) {
return gameObject.getBounds(output);
}

Expand Down Expand Up @@ -2379,7 +2380,7 @@
Depth,
Children,
Tween,
P3Container,
P3Container$2,
RenderLayer,
RenderTexture$1,
);
Expand Down Expand Up @@ -3084,6 +3085,7 @@

const GetValue$1x = Phaser.Utils.Objects.GetValue;
const Group = Phaser.GameObjects.Group;
const P3Container = Phaser.GameObjects.Container;

var DrawBounds = function (graphics, config) {
var scene = graphics.scene;
Expand Down Expand Up @@ -3126,7 +3128,10 @@
};
}

var children = this.getAllShownChildren([this]), child;
var children = this.getAllShownChildren([this]);
children.push(...GetP3ContainerChildren(children));

var child;
var nameText;
for (var i = 0, cnt = children.length; i < cnt; i++) {
child = children[i];
Expand Down Expand Up @@ -3165,6 +3170,25 @@
return scene.add.text(0, 0, '');
};

var GetP3ContainerChildren = function (gameObjects, output) {
if (!Array.isArray(gameObjects)) {
gameObjects = [gameObjects];
}
if (output === undefined) {
output = [];
}

for (var i = 0, cnt = gameObjects.length; i < cnt; i++) {
var gameObject = gameObjects[i];
if (gameObject instanceof P3Container) {
output.push(...gameObject.list);
GetP3ContainerChildren(gameObject.list, output);
}
}

return output;
};

var GlobRect = undefined;

const GetValue$1w = Phaser.Utils.Objects.GetValue;
Expand Down
4 changes: 2 additions & 2 deletions dist/rexcolorinput.min.js

Large diffs are not rendered by default.

Loading

0 comments on commit 21fa9cc

Please sign in to comment.