撤回修改
This commit is contained in:
parent
79e3484101
commit
a5a05bb382
@ -99,7 +99,6 @@ public abstract class BaseRunContext {
|
|||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
int result = ContextStateEnum.HAPPY_ENDING.getCode();
|
int result = ContextStateEnum.HAPPY_ENDING.getCode();
|
||||||
int fail = ContextStateEnum.BAD_ENDING.getCode();
|
|
||||||
for (Map.Entry<String, BaseRunContext> entry : childContext.entrySet()) {
|
for (Map.Entry<String, BaseRunContext> entry : childContext.entrySet()) {
|
||||||
BaseRunContext child = entry.getValue();
|
BaseRunContext child = entry.getValue();
|
||||||
int state = child.getState().get();
|
int state = child.getState().get();
|
||||||
@ -107,7 +106,6 @@ public abstract class BaseRunContext {
|
|||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
result&=state;
|
result&=state;
|
||||||
fail&=state;
|
|
||||||
}
|
}
|
||||||
boolean end = false;
|
boolean end = false;
|
||||||
if (ContextStateEnum.HAPPY_ENDING.getCode()==result) {
|
if (ContextStateEnum.HAPPY_ENDING.getCode()==result) {
|
||||||
@ -115,7 +113,7 @@ public abstract class BaseRunContext {
|
|||||||
this.changeContextState(ContextStateEnum.HAPPY_ENDING);
|
this.changeContextState(ContextStateEnum.HAPPY_ENDING);
|
||||||
end = true;
|
end = true;
|
||||||
}
|
}
|
||||||
} else if (ContextStateEnum.BAD_ENDING.getCode()==fail){
|
} else {
|
||||||
if (ContextStateEnum.canGoto(ContextStateEnum.getByCode(state.get()),ContextStateEnum.BAD_ENDING)) {
|
if (ContextStateEnum.canGoto(ContextStateEnum.getByCode(state.get()),ContextStateEnum.BAD_ENDING)) {
|
||||||
this.changeContextState(ContextStateEnum.BAD_ENDING);
|
this.changeContextState(ContextStateEnum.BAD_ENDING);
|
||||||
end = true;
|
end = true;
|
||||||
|
Loading…
x
Reference in New Issue
Block a user