Ejemplo n.º 1
0
 public GameHandler(Manager manager, Network network, GameMain game, ContentManager content, GraphicsDeviceManager graphics, SpriteBatch spriteBatch, GameModelBank modelBank, GameItemBank itemBank, Dictionary <short, GameClassConfig> classConfigs, GameCamera camera, AudioSystem audioSystem, ParticlePreset particleManager)
 {
     this.manager     = manager;
     this.game        = game;
     this.content     = content;
     this.graphics    = graphics;
     this.spriteBatch = spriteBatch;
     // Bank & Config
     this.modelBank    = modelBank;
     this.itemBank     = itemBank;
     this.classConfigs = classConfigs;
     // System handler
     this.camera  = camera;
     this.network = network;
     // Entities
     this.monstersEntity = new Dictionary <String, UnitEntity>();
     this.npcsEntity     = new Dictionary <String, UnitEntity>();
     this.playersEntity  = new Dictionary <String, UnitEntity>();
     this.warpsEntity    = new Dictionary <String, WarpEntity>();
     this.itemsEntity    = new Dictionary <String, ItemEntity>();
     this.playerEntity   = null;
     // Effects
     this.audioSystem     = audioSystem;
     this.particleManager = particleManager;
     // Load font
     entityNameFont   = content.Load <SpriteFont>("Fonts/EntityName");
     entityDamageFont = content.Load <SpriteFont>("Fonts/EntityDamage");
     // White rect
     whiteRect = new Texture2D(graphics.GraphicsDevice, 1, 1);
     whiteRect.SetData(new[] { Color.White });
 }