public override void Start(ICoreAPI api) { base.Start(api); api.RegisterEntity("EntityFallingMeteor", typeof(EntityFallingMeteor)); api.RegisterEntity("EntityShowerMeteor", typeof(EntityShowerMeteor)); }
public override void Start(ICoreAPI api) { base.Start(api); api.RegisterItemClass("ItemSnowball", Type.GetType(MOD_SPACE + ".ItemSnowball")); api.RegisterEntity("EntityThrownSnowball", Type.GetType(MOD_SPACE + ".EntityThrownSnowball")); api.RegisterBlockBehaviorClass("CollectSnowball", Type.GetType(MOD_SPACE + ".BlockBehaviorCollectSnowball")); }
public override void Start(ICoreAPI api) { //api.RegisterBlockBehaviorClass(InstaTNTBehavior.NAME, typeof(InstaTNTBehavior)); api.RegisterItemClass("ItemRangedWeapon", typeof(ItemRangedWeapon)); api.RegisterItemClass("ItemPoisonArrow", typeof(ItemPoisonArrow)); api.RegisterEntity("EntityPoisonProjectile", typeof(EntityPoisonProjectile)); api.RegisterEntityBehaviorClass("poisonable", typeof(Poisonable)); }
private void RegisterDefaultEntities() { api.RegisterEntity("EntityNpc", typeof(EntityPlayerNpc)); api.RegisterEntity("EntityProjectile", typeof(EntityProjectile)); api.RegisterEntity("EntityThrownStone", typeof(EntityThrownStone)); api.RegisterEntity("EntityBeeMob", typeof(EntityBeeMob)); api.RegisterEntity("EntityButterfly", typeof(EntityButterfly)); api.RegisterEntity("EntityThrownBeenade", typeof(EntityThrownBeenade)); api.RegisterEntity("EntityTrader", typeof(EntityTrader)); api.RegisterEntity("EntityStrawDummy", typeof(EntityStrawDummy)); }
} // Interact ring public override void Start(ICoreAPI api) { Config.Current = api.LoadOrCreateConfig <Config>(ConstantsCore.ModId + ".json"); if (Config.Current.CreateWaypoint.Val == "auto") { Config.Current.CreateWaypoint.Val = api.ModLoader.IsModEnabled("streamdc") ? "none" : "always"; } api.RegisterEntityBehaviorClass("playercorpseondeath", typeof(EntityBehaviorPlayerCorpseOnDeath)); api.RegisterEntity("EntityPlayerCorpse", typeof(EntityPlayerCorpse)); }
public override void Start(ICoreAPI api) { Config.Current = api.LoadOrCreateConfig <Config>(Mod.Info.ModID + ".json"); api.World.Config.SetBool(Mod.Info.ModID + ":CorpseCompassEnabled", Config.Current.CorpseCompassEnabled.Value); api.RegisterEntityBehaviorClass("playercorpseondeath", typeof(EntityBehaviorPlayerCorpseOnDeath)); api.RegisterEntity("EntityPlayerCorpse", typeof(EntityPlayerCorpse)); api.RegisterItemClass("ItemCorpseCompass", typeof(ItemCorpseCompass)); }
public override void Start(ICoreAPI api) { base.Start(api); api.RegisterItemClass("ProgCard", typeof(ItemProgCard)); api.RegisterItemClass("ItemDeployBot", typeof(ItemDeployBot)); api.RegisterEntityBehaviorClass("program", typeof(EntityBehaviorProgram)); api.RegisterEntity("EntityReprogLocust", typeof(EntityReprogLocust)); AiTaskRegistry.Register <AiTaskHarvest>("harvest"); AiTaskRegistry.Register <AiTaskSeekItem>("seekitem"); AiTaskRegistry.Register <AiTaskToChest>("tochest"); AiTaskRegistry.Register <AiTaskFromChest>("fromchest"); AiTaskRegistry.Register <AiTaskPlant>("plant"); AiTaskRegistry.Register <AiTaskSqueezeHoney>("squeezehoney"); AiTaskRegistry.Register <AiTaskMilk>("milk"); AiTaskRegistry.Register <AiTaskToBarrel>("tobarrel"); AiTaskRegistry.Register <AiTaskGetSeed>("getseed"); AiTaskRegistry.Register <AiTaskSeekItemAny>("seekanyitem"); AiTaskRegistry.Register <AiTaskGetFuel>("getfuel"); AiTaskRegistry.Register <AiTaskRefuel>("refuel"); AiTaskRegistry.Register <AiTaskRepair>("repair"); AiTaskRegistry.Register <AiTaskProgSeekEntity>("progseekentity"); AiTaskRegistry.Register <AiTaskProgMeleeAttack>("progmeleeattack"); AiTaskRegistry.Register <AiTaskQuarry>("quarry"); AiTaskRegistry.Register <AiTaskStayCloseToOwner>("stayclosetoowner"); AiTaskRegistry.Register <AiTaskPathBuilder>("pathbuilder"); AiTaskRegistry.Register <AiTaskToAltChest>("toaltchest"); AiTaskRegistry.Register <AiTaskProgRangedAttack>("prograngedattack"); AiTaskRegistry.Register <AiTaskForm>("form"); AiTaskRegistry.Register <AiTaskToPoint>("topoint"); AiTaskRegistry.Register <AiTaskGetItem>("getitem"); AiTaskRegistry.Register <AiTaskAnyFromChest>("anyfromchest"); AiTaskRegistry.Register <AiTaskGetTool>("gettool"); try { TemporalHackerConfig FromDisk; if ((FromDisk = api.LoadModConfig <TemporalHackerConfig>("TemporalHackerConfig.json")) == null) { api.StoreModConfig <TemporalHackerConfig>(TemporalHackerConfig.Loaded, "TemporalHackerConfig.json"); } else { TemporalHackerConfig.Loaded = FromDisk; } } catch { api.StoreModConfig <TemporalHackerConfig>(TemporalHackerConfig.Loaded, "TemporalHackerConfig.json"); } }
public override void StartPre(ICoreAPI api) { api.RegisterItemClass("ItemCage", typeof(ItemCage)); api.RegisterEntity("EntityThrownCage", typeof(EntityThrownCage)); if (api.Side == EnumAppSide.Client) { (api as ICoreClientAPI).Network .RegisterChannel(ConstantsCore.ModId) .RegisterMessageType <Dictionary <AssetLocation, List <CaptureEntity> > >() .SetMessageHandler <Dictionary <AssetLocation, List <CaptureEntity> > >(OnReceiveAllBaits); } else { serverChannel = (api as ICoreServerAPI).Network .RegisterChannel(ConstantsCore.ModId) .RegisterMessageType <Dictionary <AssetLocation, List <CaptureEntity> > >(); } }
private void RegisterDefaultEntities() { api.RegisterEntity("EntityPlayerBot", typeof(EntityPlayerBot)); api.RegisterEntity("EntityAnimalBot", typeof(EntityAnimalBot)); api.RegisterEntity("EntityProjectile", typeof(EntityProjectile)); api.RegisterEntity("EntityThrownStone", typeof(EntityThrownStone)); api.RegisterEntity("EntityBeeMob", typeof(EntityBeeMob)); api.RegisterEntity("EntityButterfly", typeof(EntityButterfly)); api.RegisterEntity("EntityThrownBeenade", typeof(EntityThrownBeenade)); api.RegisterEntity("EntityTrader", typeof(EntityTrader)); api.RegisterEntity("EntityStrawDummy", typeof(EntityStrawDummy)); api.RegisterEntity("EntityGlowingAgent", typeof(EntityGlowingAgent)); api.RegisterEntity("EntityLocust", typeof(EntityLocust)); api.RegisterEntity("EntityArmorStand", typeof(EntityArmorStand)); api.RegisterEntity("EntityBell", typeof(EntityBell)); api.RegisterEntity("EntityFish", typeof(EntityFish)); }
private void RegisterDefaultEntities() { api.RegisterEntity("EntityBlockfalling", typeof(EntityBlockFalling)); }