public override eJOB_STATUT Interact(eINPUT_INTERACT inputTriggered) { eJOB_STATUT statut = base.Interact(inputTriggered); switch (statut) { case eJOB_STATUT.SUCCEEDED: if (spawnIfSucceed) { if (items.Count < maxItems) { SpawnItem(); } } else { if (items.Count > 0) { DestroyItem(); } } break; } return(statut); }
public override eJOB_STATUT Interact(eINPUT_INTERACT inputTriggered) { eJOB_STATUT statut = base.Interact(inputTriggered); switch (statut) { case eJOB_STATUT.SUCCEEDED: if (efficiency < 1) { efficiency += (valuePerSuccess > 1 - efficiency) ? 1 - efficiency : valuePerSuccess; } break; } return(statut); }
public override eJOB_STATUT Interact(eINPUT_INTERACT inputTriggered) { eJOB_STATUT statut = base.Interact(inputTriggered); switch (statut) { case eJOB_STATUT.SUCCEEDED: if (nbSpawnPermitted > 0) { AiManager.instance.SpawnAI(); --nbSpawnPermitted; } break; } return(statut); }