blob: 7bccadf47f0fc0a3e6b54ae354be1a9110993071 (
plain) (
blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
|
/*
* To change this template, choose Tools | Templates
* and open the template in the editor.
*/
package com.fourisland.fourpuzzle.gamestate.mapview.event.precondition;
import com.fourisland.fourpuzzle.Game;
/**
*
* @author hatkirby
*/
public class SwitchPrecondition implements Precondition {
private String switchID;
public SwitchPrecondition(String switchID)
{
this.switchID = switchID;
}
public boolean match()
{
return (Game.getSaveFile().getSwitches().containsKey(switchID) && Game.getSaveFile().getSwitches().get(switchID));
}
}
|