That's one heck of a commit you've got there...
I may have got a bit behind with version control. A lot behind, in fact. Maybe I'll go back and split this sometime - then again, I probably won't. But hey, at least it's here!
This commit is contained in:
@@ -0,0 +1,25 @@
|
||||
package electroblob.wizardry.data;
|
||||
|
||||
/** Enum which defines the circumstances in which an {@link IVariable} persists, i.e. whether its value is carried over. */
|
||||
public enum Persistence {
|
||||
|
||||
NEVER(false, false),
|
||||
DIMENSION_CHANGE(false, true),
|
||||
RESPAWN(true, false),
|
||||
ALWAYS(true, true);
|
||||
|
||||
private boolean persistsOnRespawn, persistsOnDimensionChange;
|
||||
|
||||
Persistence(boolean persistsOnRespawn, boolean persistsOnDimensionChange){
|
||||
this.persistsOnRespawn = persistsOnRespawn;
|
||||
this.persistsOnDimensionChange = persistsOnDimensionChange;
|
||||
}
|
||||
|
||||
public boolean persistsOnRespawn(){
|
||||
return persistsOnRespawn;
|
||||
}
|
||||
|
||||
public boolean persistsOnDimensionChange(){
|
||||
return persistsOnDimensionChange;
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user