the great renaming
This commit is contained in:
42
src/app/logic/chibi-behaviour/brains/aperio.brain.ts
Normal file
42
src/app/logic/chibi-behaviour/brains/aperio.brain.ts
Normal file
@@ -0,0 +1,42 @@
|
||||
import { EChibiInteraction } from "../../../types/chibi/chibi-interaction";
|
||||
import { EChibiStateName } from "../../../types/chibi/chibi-state-name";
|
||||
import { IBrain } from "../brain";
|
||||
|
||||
export class Aperio implements IBrain {
|
||||
resolveInteraction(state: EChibiStateName, interaction: EChibiInteraction): EChibiStateName {
|
||||
switch (state) {
|
||||
case EChibiStateName.Sleeping: return this.resolveSleepingInteraction(interaction);
|
||||
default: return EChibiStateName.Sleeping;
|
||||
}
|
||||
}
|
||||
|
||||
/*
|
||||
pear mostly sleeps
|
||||
1/128 chance of waking her
|
||||
12/128 chance of her doing a grumble and going back to sleep
|
||||
visiting caethya will wake her up and go into lovey-dovey mode
|
||||
she has a 1/2048 chance of waking up on her own
|
||||
pears happyness goes up when she sleeps
|
||||
|
||||
pear never gets hungry
|
||||
but she accepts foods she likes, which raise her happyness
|
||||
as long as the same food is not offered thrice in a row (except banana split)
|
||||
|
||||
pears energy never goes down
|
||||
pear will accept fights and enjoys them
|
||||
pear will accept walks and enjoys them
|
||||
|
||||
pear will get sad if she is awake and you do not interact with her
|
||||
|
||||
pear gets offended if you suggest she go to sleep
|
||||
|
||||
after any interaction she has a 1/4 chance of going to sleep
|
||||
*/
|
||||
|
||||
private resolveSleepingInteraction(interaction: EChibiInteraction): EChibiStateName {
|
||||
if (EChibiInteraction.WakeUp) {
|
||||
return EChibiStateName.Awake;
|
||||
}
|
||||
return EChibiStateName.Sleeping;
|
||||
}
|
||||
};
|
||||
Reference in New Issue
Block a user