Fix Integration Stages
This commit is contained in:
@@ -30,6 +30,12 @@ public class IntegrationNode
|
|||||||
name = n;
|
name = n;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public String toString()
|
||||||
|
{
|
||||||
|
return shortName.name() + ":" + state.name();
|
||||||
|
}
|
||||||
|
|
||||||
void Call(IntegrationStage stage)
|
void Call(IntegrationStage stage)
|
||||||
{
|
{
|
||||||
if ( state != IntegrationStage.FAILED )
|
if ( state != IntegrationStage.FAILED )
|
||||||
@@ -66,12 +72,18 @@ public class IntegrationNode
|
|||||||
else
|
else
|
||||||
throw new ModNotInstalled( modID );
|
throw new ModNotInstalled( modID );
|
||||||
|
|
||||||
|
state = IntegrationStage.INIT;
|
||||||
|
|
||||||
break;
|
break;
|
||||||
case INIT:
|
case INIT:
|
||||||
mod.Init();
|
mod.Init();
|
||||||
|
state = IntegrationStage.POSTINIT;
|
||||||
|
|
||||||
break;
|
break;
|
||||||
case POSTINIT:
|
case POSTINIT:
|
||||||
mod.PostInit();
|
mod.PostInit();
|
||||||
|
state = IntegrationStage.READY;
|
||||||
|
|
||||||
break;
|
break;
|
||||||
case FAILED:
|
case FAILED:
|
||||||
default:
|
default:
|
||||||
|
|||||||
@@ -5,5 +5,6 @@ public enum IntegrationStage
|
|||||||
|
|
||||||
PREINIT, INIT, POSTINIT,
|
PREINIT, INIT, POSTINIT,
|
||||||
|
|
||||||
FAILED
|
FAILED, READY
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user