Skip to content

Commit

Permalink
Rename SendTowerActivationRequest to ActivateTowerRequest
Browse files Browse the repository at this point in the history
  • Loading branch information
darshan3 committed Aug 5, 2019
1 parent d9573e2 commit a5157ed
Show file tree
Hide file tree
Showing 3 changed files with 6 additions and 6 deletions.
Expand Up @@ -20,14 +20,14 @@
import org.terasology.network.ServerEvent;

@ServerEvent
public class SendTowerActivationRequest implements Event {
public class ActivateTowerRequest implements Event {
public EntityRef towerEntity;
public boolean isActivated;

public SendTowerActivationRequest() {
public ActivateTowerRequest() {
}

public SendTowerActivationRequest(EntityRef towerEntity, boolean isActivated) {
public ActivateTowerRequest(EntityRef towerEntity, boolean isActivated) {
this.towerEntity = towerEntity;
this.isActivated = isActivated;
}
Expand Down
Expand Up @@ -47,7 +47,7 @@ public class TowerAuthoritySystem extends BaseComponentSystem {
private DelayManager delayManager;

@ReceiveEvent
public void onSettingsChanged(SendTowerActivationRequest event, EntityRef player) {
public void onSettingsChanged(ActivateTowerRequest event, EntityRef player) {
EntityRef towerEntity = event.towerEntity;
TowerComponent towerComponent = towerEntity.getComponent(TowerComponent.class);
towerComponent.isActivated = event.isActivated;
Expand Down
Expand Up @@ -16,7 +16,7 @@
package org.terasology.rendering.nui.towers;

import org.terasology.entitySystem.entity.EntityRef;
import org.terasology.logic.ingame.towers.SendTowerActivationRequest;
import org.terasology.logic.ingame.towers.ActivateTowerRequest;
import org.terasology.logic.ingame.towers.TowerComponent;
import org.terasology.logic.location.LocationComponent;
import org.terasology.logic.players.LocalPlayer;
Expand Down Expand Up @@ -64,7 +64,7 @@ protected void initializeWithInteractionTarget(EntityRef interactionTarget) {
}

private void onSaveButton(UIWidget button) {
localPlayer.getClientEntity().send(new SendTowerActivationRequest(towerRoot, isActivated.isChecked()));
localPlayer.getClientEntity().send(new ActivateTowerRequest(towerRoot, isActivated.isChecked()));
getManager().popScreen();
}

Expand Down

0 comments on commit a5157ed

Please sign in to comment.