We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 037a8b2 commit 8a3cc30Copy full SHA for 8a3cc30
engine/modules/entities/src/main/java/com/codingame/gameengine/module/entities/Entity.java
@@ -516,4 +516,11 @@ protected static void requireValidColor(int color) {
516
throw new IllegalArgumentException(color + "is not a valid RGB integer.");
517
}
518
519
+
520
+ /**
521
+ * @return the Group or BufferedGroup which contains this entity
522
+ */
523
+ public Optional<ContainerBasedEntity<?>> getParent() {
524
+ return Optional.ofNullable(parent);
525
+ }
526
0 commit comments