-
Notifications
You must be signed in to change notification settings - Fork 3
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
fix(ecs-gestalt): Migrate Components to gestalt's Components. #12
Conversation
@Override | ||
public void copy(KallistiComputerComponent other) { | ||
this.on = other.on; | ||
this.machine = other.machine; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I have no clue whether this is okay for Machine
🤷
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I've added a FIXME
here as I don't want to look into creating a deep copy of Machine
and all it's members right now ... 🙈
src/main/java/org/terasology/kcomputers/components/KallistiConnectableComponent.java
Outdated
Show resolved
Hide resolved
src/main/java/org/terasology/kcomputers/components/KallistiDisplayCandidateComponent.java
Show resolved
Hide resolved
this.texture = other.texture; | ||
this.pw = other.pw; | ||
this.ph = other.ph; | ||
this.entityManager = other.entityManager; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I'm not going to ask why this component holds the entity manager 🙈
src/main/java/org/terasology/kcomputers/components/KallistiDisplayComponent.java
Outdated
Show resolved
Hide resolved
src/main/java/org/terasology/kcomputers/components/KallistiInventoryWithContainerComponent.java
Outdated
Show resolved
Hide resolved
src/main/java/org/terasology/kcomputers/components/machines/KallistiTransposerComponent.java
Outdated
Show resolved
Hide resolved
Nesting components directly is an anti-pattern afaik, but since we already do it we can at least use their 'copyFrom' method to create a deep copy.
Ref: MovingBlocks/Terasology#4753