public MonsterController(IMonsterRepository repo, IMonsterProf profRepo, IMonsterSense senseRepo, IAbilityRepository abilityRepo) { _repo = repo; _profRepo = profRepo; _senseRepo = senseRepo; _abilityRepo = abilityRepo; }
public AbilityAuthorizationService(IUserRepository userRepository, IRoleRepository roleRepository, IAbilityRepository abilityRepository) { _userRepository = userRepository; _roleRepository = roleRepository; _abilityRepository = abilityRepository; }
public HomeController(IImageRepository imageRepo, ISiteSettingRepository siteSettingRepo, IPersonalSettingRepository personalSettingRepo, IPostRepository postRepo, ISocialRepository socialRepo, IAbilityRepository abilityRepo, IProjectRepository projectRepo) { _socialRepository = socialRepo; _abilityRepository = abilityRepo; _projectRepository = projectRepo; _postRepository = postRepo; _personalSettingRepository = personalSettingRepo; _siteSettingRepository = siteSettingRepo; _imageRepository = imageRepo; }
public PlayerPeer(Socket socket, IAccountRepository accountRepository, IPlayerRepository playerRepository, IAbilityRepository abilityRepository, Dictionary <int, Zone> zones) : base(socket) { m_accountRepository = accountRepository; m_playerRepository = playerRepository; m_abilityRepository = abilityRepository; m_zones = zones; InitialiseRoutes(); Fiber.Enqueue(Update); }
public BlogController(ICommentRepository commentRepo, IImageRepository imageRepo, ICategoryRepository categoryRepo, ISiteSettingRepository siteSettingRepo, IPersonalSettingRepository personalSettingRepo, IPostRepository postRepo, ISocialRepository socialRepo, IAbilityRepository abilityRepo, IProjectRepository projectRepo) { _categoryRepository = categoryRepo; _socialRepository = socialRepo; _abilityRepository = abilityRepo; _projectRepository = projectRepo; _postRepository = postRepo; _personalSettingRepository = personalSettingRepo; _siteSettingRepository = siteSettingRepo; _imageRepository = imageRepo; _commentRepository = commentRepo; }
public LevelEnemyUnitSetupProcessor(AgentFactory agentFactory, IItemTemplateRepository itemTemplateRepository, IRandomizer randomizer, IUnitIdPool unitIdPool, UnitBuilder unitBuilder, IAbilityRepository abilityRepository, ISpellRepository spellRepository, ICardEffectsRepository cardEffectsRepository) { AgentFactory = agentFactory; ItemTemplateRepository = itemTemplateRepository; Randomizer = randomizer; UnitIdPool = unitIdPool; UnitBuilder = unitBuilder; AbilityRepository = abilityRepository; SpellRepository = spellRepository; CardEffectsRepository = cardEffectsRepository; GlobalLootTable = GenerateLootTable(); }
protected override void ResolveApplicationDependencies() { base.ResolveApplicationDependencies(); Level = Container.Resolve <Level>(); GameConfiguration = Container.Resolve <GameConfiguration>(); GameState = Container.Resolve <GameState>(); UnitBuilder = Container.Resolve <UnitBuilder>(); ItemTemplateRepository = Container.Resolve <IItemTemplateRepository>(); CardEffectsRepository = Container.Resolve <ICardEffectsRepository>(); SpellRepository = Container.Resolve <ISpellRepository>(); UnitIdPool = Container.Resolve <IUnitIdPool>(); AbilityRepository = Container.Resolve <IAbilityRepository>(); }
/// IModules can take any number of these in the constructor and in any order. /// It is all handled using Dependency Injection. public FullModule(ILogger log, IIntelManager intelManager, ICombatManager combatManager, IProductionManager productionManager, IRawManager rawManager, IAbilityRepository abilityRepository, IUnitTypeRepository unitTypeRepository, IUpgradeRepository upgradeRepository, IBuffRepository buffRepository, ISquadRepository squadRepository, IGameMap gameMap, ITechTree techTree, GameSettings gameSettings) { this.log = log; this.intelManager = intelManager; this.combatManager = combatManager; this.productionManager = productionManager; this.rawManager = rawManager; this.abilityRepository = abilityRepository; this.unitTypeRepository = unitTypeRepository; this.upgradeRepository = upgradeRepository; this.buffRepository = buffRepository; this.squadRepository = squadRepository; this.gameMap = gameMap; this.techTree = techTree; }
public World(IAccountRepository accountRepository, INPCRepository npcRepository, IPlayerRepository playerRepository, IServerStatsRepository statsRepository, IAbilityRepository abilityRepository) { m_accountRepository = accountRepository; m_npcRepository = npcRepository; m_playerRepository = playerRepository; m_statsRepository = statsRepository; m_abilityRepository = abilityRepository; m_npcFactory = new NPCFactory(npcRepository); m_zones = BuildZones(m_npcRepository); m_cpuCounter.CategoryName = "Processor"; m_cpuCounter.CounterName = "% Processor Time"; m_cpuCounter.InstanceName = "_Total"; m_fiber.Enqueue(Update, false); //m_fiber.Enqueue(StatsUpdate, false); }
public GameMap(IAbilityRepository abilityRepository, IUnitTypeRepository unitTypeRepository, IRawManager rawManager) { this.abilityRepository = abilityRepository; this.unitTypeRepository = unitTypeRepository; this.rawManager = rawManager; }
public AbilityController(IAbilityRepository repository) { abilityRepository = repository; }
public AbilityController(IAbilityRepository abilityRepository) { _abilityRepository = abilityRepository; }
public AbilityAuthorizationService() { _userRepository = new UserRepository(); _roleRepository = new RoleRepository(); _abilityRepository = new AbilityRepository(); }
public AbilityService(IAbilityRepository abilityRepository, IStatusRepository statusRepository) { this.abilityRepository = abilityRepository; this.statusRepository = statusRepository; }
public AbilityService(IMapper mapper, IRaceAbilityRepository raceAbilityRepository, IAbilityRepository abilityRepository) : base(mapper) { _raceAbilityRepository = raceAbilityRepository; _abilityRepository = abilityRepository; }
private static void Main(string[] args) { GCSettings.LatencyMode = GCLatencyMode.SustainedLowLatency; ServerConfiguration config = (ServerConfiguration)ConfigurationManager.GetSection("server"); s_log.Info("Creating repositories..."); UnityContainer repositoryResolver = new UnityContainer(); repositoryResolver.LoadConfiguration(); IAccountRepository accountRepository = repositoryResolver.Resolve <IAccountRepository>(); INPCRepository npcRepository = repositoryResolver.Resolve <INPCRepository>(); IPlayerRepository playerRepository = repositoryResolver.Resolve <IPlayerRepository>(); IAbilityRepository abilityRepository = repositoryResolver.Resolve <IAbilityRepository>(); IServerStatsRepository statsRepository = new NullServerStatsRepository(); try { statsRepository = repositoryResolver.Resolve <IServerStatsRepository>(); } catch { s_log.Warn("Failed to create stats repository. Stats will be disabled."); } s_log.Info("Precaching NPCs..."); var npcs = npcRepository.GetNPCs(); s_log.Info("Precaching NPC Spawns..."); npcRepository.GetNPCSpawns(); s_log.Info("Precaching NPC Behaviours..."); var npcBehaviours = npcRepository.GetNPCBehaviours(); foreach (NPCModel npc in npcs) { npcRepository.GetNPCBehavioursByNPCID(npc.NPCID); } s_log.Info("Precaching NPC Behaviour Vars..."); npcRepository.GetNPCBehaviourVars(); foreach (NPCBehaviourModel npcBehaviour in npcBehaviours) { npcRepository.GetNPCBehaviourVarsByNPCBehaviourID(npcBehaviour.NPCBehaviourID); } s_log.Info("Precaching NPC Stats..."); npcRepository.GetNPCStats(); foreach (NPCModel npc in npcs) { npcRepository.GetNPCStatsByNPCID(npc.NPCID); } s_log.Info("Precaching abilities..."); abilityRepository.GetAbilities(); s_log.Info("Initialising serializer..."); ProtocolUtility.InitialiseSerializer(); s_log.Info("Creating world..."); using (World world = new World(accountRepository, npcRepository, playerRepository, statsRepository, abilityRepository)) { TcpListener listener = new TcpListener(IPAddress.Any, config.Port); listener.Start(); s_log.Info("Listening for connections on " + listener.LocalEndpoint.ToString()); while (true) { Socket socket = listener.AcceptSocket(); world.AcceptSocket(socket); } } }
public AbilityMenuViewComponent(IAbilityRepository repo) { repository = repo; }