package electrosphere.game.server.terrain.models;

/**
 *
 * @author amaterasu
 */
public class TerrainModification {
    int worldX;
    int worldY;
    int locationX;
    int locationY;
    float value;

    public TerrainModification(int worldX, int worldY, int locationX, int locationY, float value) {
        this.worldX = worldX;
        this.worldY = worldY;
        this.locationX = locationX;
        this.locationY = locationY;
        this.value = value;
    }

    public int getWorldX() {
        return worldX;
    }

    public int getWorldY() {
        return worldY;
    }

    public int getLocationX() {
        return locationX;
    }

    public int getLocationY() {
        return locationY;
    }

    public float getValue() {
        return value;
    }
    
    public float[][] applyToHeightfield(float[][] heightfield){
        heightfield[locationX][locationY] = value;
        return heightfield;
    }
    
    
}
