public LocalToolDescription(PaintGunMod main) : base(main) { if (Main.IsDedicatedServer) { throw new Exception($"Why's this called in DS?"); } }
public UIEdit(PaintGunMod main) : base(main) { if (ENABLED && MyAPIGateway.Session.OnlineMode == MyOnlineModeEnum.OFFLINE && Utils.IsLocalMod()) { uiEdit = new UIEdit(); } }
public TextAPI(PaintGunMod main) : base(main) { if (Main.IsDedicatedServer) { throw new Exception($"Why is {GetType().Name} initialized for DS?!"); } }
public DrawUtils(PaintGunMod main) : base(main) { if (Main.IsDedicatedServer) { throw new Exception($"Why is {GetType().Name} initialized for DS?!"); } UpdateMethods = UpdateFlags.UPDATE_DRAW; }
public PlayerHandler(PaintGunMod main) : base(main) { int maxPlayers = MyAPIGateway.Session.SessionSettings.MaxPlayers; OnlinePlayers = new List <IMyPlayer>(maxPlayers); MyVisualScriptLogicProvider.PlayerConnected += ViScPlayerConnected; MyVisualScriptLogicProvider.PlayerDisconnected += ViScPlayerDisconnected; }
public ToolHandler(PaintGunMod main) : base(main) { if (Main.IsDedicatedServer) { throw new Exception($"Why's this called in DS?"); } MyAPIGateway.Entities.OnEntityAdd += EntityAdded; }
public Caches(PaintGunMod main) : base(main) { Players = new MyConcurrentPool <List <IMyPlayer> >( clear: (l) => l.Clear(), activator: () => new List <IMyPlayer>(MyAPIGateway.Session.SessionSettings.MaxPlayers), expectedAllocations: 5, defaultCapacity: 1); AlreadyMirrored = new List <Vector3I>(8); PackedColors = new List <uint>(Constants.COLOR_PALETTE_SIZE); }
public PaintGunItem() { Main = PaintGunMod.Instance; if (Main.IsDedicatedServer) { throw new ArgumentException($"{GetType().Name} got created on DS side, not designed for that."); } SoundEmitter = new SpraySoundEmitter(GetSpraySoundPosition, IsHoldingPaintGun); }
public NetworkLibHandler(PaintGunMod main) : base(main) { Lib = new Network(Constants.NETWORK_CHANNEL, PaintGunMod.MOD_NAME, true, (e) => Log.Error(e, Log.PRINT_MESSAGE)); // needed here because they call an API method on creation PacketPaint = new PacketPaint(); PacketReplacePaint = new PacketReplacePaint(); PacketConsumeAmmo = new PacketConsumeAmmo(); PacketPaletteUpdate = new PacketPaletteUpdate(); PacketPaletteSetColor = new PacketPaletteSetColor(); PacketJoinSharePalette = new PacketJoinSharePalette(); PacketToolSpraying = new PacketToolSpraying(); PacketWarningMessage = new PacketWarningMessage(); }
public TestComp(PaintGunMod main) : base(main) { //UpdateMethods |= UpdateFlags.UPDATE_DRAW; }
public HUDSounds(PaintGunMod main) : base(main) { }
const int COOLDOWN_UNTIL_RESYNC = Constants.TICKS_PER_SECOND / 2; // this cooldown starts after the sync is done and blocks future re-syncs. public PaletteScheduledSync(PaintGunMod main) : base(main) { }
public LocalToolHandler(PaintGunMod main) : base(main) { UpdateMethods = UpdateFlags.UPDATE_INPUT; }
public PaletteInputHandler(PaintGunMod main) : base(main) { }
public CheckPlayerField(PaintGunMod main) : base(main) { UpdateMethods = UpdateFlags.UPDATE_AFTER_SIM; }
public Painting(PaintGunMod main) : base(main) { }
public ConfigMenuHandler(PaintGunMod main) : base(main) { }
public ColorPickerGUIWarning(PaintGunMod main) : base(main) { }
public Notifications(PaintGunMod main) : base(main) { }
public PaletteHUD(PaintGunMod main) : base(main) { }
bool LogDLCInstalledEvent = false; // need to skip early events as it triggers for every single DLC and gets spammy public Palette(PaintGunMod main) : base(main) { MyAPIGateway.DLC.DLCInstalled += DLCInstalled; InitBlockSkins(); }
public Settings(PaintGunMod main) : base(main) { }
public ChatCommands(PaintGunMod main) : base(main) { }
public GameConfig(PaintGunMod main) : base(main) { UpdateMethods = UpdateFlags.UPDATE_AFTER_SIM | UpdateFlags.UPDATE_INPUT; }
public SelectionGUI(PaintGunMod main) : base(main) { UpdateMethods = UpdateFlags.UPDATE_DRAW; }