public MinersWife(int entity_type) : base(entity_type, (int)EntityName.ent_Elsa) { m_Location = location_type.shack; m_bCooking = false; //set up the state machine m_pStateMachine = new StateMachine(this); m_pStateMachine.CurrentState = new DoHouseWork(); m_pStateMachine.GlobalState = new WifesGlobalState(); }
public format_cell(match_item item, log_view parent, int col_idx, info_type col_type, formatted_text text, int row_index, int top_row_index, int sel_index, bool is_bookmark, string prev_text, location_type location) { this.item = item; this.parent = parent; this.col_idx = col_idx; this.col_type = col_type; this.format_text = text; this.row_index = row_index; this.top_row_index = top_row_index; this.prev_text = prev_text; this.location = location; this.sel_index = sel_index; this.is_bookmark = is_bookmark; fg_color = item.fg(parent); bg_color = item.bg(parent); }
public BarFlyJoe(int entity_type) : base(entity_type, (int)EntityName.ent_BarFly) { m_Location = location_type.saloon; m_iDrunkeness = 0; m_iHP = HPFull; m_angered = false; //set up the state machine m_pStateMachine = new StateMachine(this); m_pStateMachine.CurrentState = new JoeDoChillin(); /* NOTE, A GLOBAL STATE HAS NOT BEEN IMPLEMENTED FOR THE BarFly */ }
public Miner(int entity_type) : base(entity_type, (int)EntityName.ent_Miner_Bob) { m_Location = location_type.shack; m_iGoldCarried = 0; m_iMoneyInBank = 0; m_iThirst = 0; m_iFatigue = 0; m_iHP = HPFull; //set up the state machine m_pStateMachine = new StateMachine(this); m_pStateMachine.CurrentState = new GoHomeAndSleepTilRested(); m_pStateMachine.GlobalState = new BobsGlobalState(); }
private void SetBaseValues() { if (rand == null) { rand = new Random(); } m_iGoldCarried = 0; m_iMoneyInBank = 0; m_iThirst = 0; m_iHunger = 0; m_iFatigue = 0; m_Location = location_type.home; m_iGoldCarriedMax = 2 + rand.Next(4); m_iGoldMax = 4 + rand.Next(10); m_iThirstMax = 7 + rand.Next(5); m_iHungerMax = 9 + rand.Next(4); //setting up state machine m_pStateMachine = new StateMachine <Miner>(this); m_pStateMachine.SetCurrentState(GoHomeAndSleepTilRested.Instance()); }
public void ChangeLocation(location_type loc) { location = loc; }
public void ChangeLocation(location_type newLocation) { m_Location = newLocation; }