Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

update #8

Merged
merged 1 commit into from
Dec 5, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Binary file removed Build mods folder.lnk
Binary file not shown.
8 changes: 5 additions & 3 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -20,12 +20,11 @@ This mod provides an additional item for the user to craft and utilize in their

[*Curseforge*](https://www.curseforge.com/minecraft/mc-mods/catsmod)

TODO :
TODO :

* add a music
* add a culture
* add a keyboard touch
* add a way to modify drops of vanilla blocks
* add completly custom entity
* make cat structure worldgen
* make a gun/ammunation
Expand All @@ -34,14 +33,17 @@ TODO :
* make a villager/personalized trades
* make a config file
* add achievement/achievement tab
* add dimension/a way to tp to this dimension
* add dimension/a way to tp to this dimension (WIP)
* add a enchant
* make a 3d block using TESR render/add custom chest/crafting table
* make a 3d block using ISBRH render
* make catBlocks in catDimension and for it's own brother named catBiome

* switching Global entity id to mod entity id

* fix the entity CatAgressiveEntity/CatPassiveEntity run has lower tick/run no fast
* fix the tnt model doesn't work

* remake textures

Some of these description is by SkyDash #4150
28 changes: 24 additions & 4 deletions src/main/java/fr/iamacat/catmod/Catmod.java
Original file line number Diff line number Diff line change
Expand Up @@ -9,10 +9,10 @@
import cpw.mods.fml.common.event.FMLPostInitializationEvent;
import cpw.mods.fml.common.event.FMLPreInitializationEvent;
import cpw.mods.fml.common.registry.GameRegistry;
import fr.iamacat.catmod.init.RegisterBiomes;
import fr.iamacat.catmod.init.RegisterBlocks;
import fr.iamacat.catmod.init.RegisterFuel;
import fr.iamacat.catmod.init.RegisterItems;
import fr.iamacat.catmod.entities.CatAgressiveEntity;
import fr.iamacat.catmod.entities.CatPassiveEntity;
import fr.iamacat.catmod.init.*;
import fr.iamacat.catmod.items.CatSpawnEgg;
import fr.iamacat.catmod.proxy.CommonProxy;
import fr.iamacat.catmod.utils.*;
import fr.iamacat.catmod.worldgen.oregen.CatOreGen;
Expand All @@ -23,6 +23,7 @@
version = Reference.MOD_VERSION,
acceptedMinecraftVersions = Reference.MC_VERSION)
public class Catmod {

// todo fix tooltips for blocks
@Mod.Instance(Reference.MOD_ID)
public static Catmod instance;
Expand All @@ -40,6 +41,9 @@ public class Catmod {

public static CatTabIngots catTab7 = new CatTabIngots("catTab7");

public static Item CatAgressiveEntitySpawnEgg;
public static Item CatPassiveEntitySpawnEgg;

@Mod.EventHandler
public static void preInit(FMLPreInitializationEvent event) {
RegisterItems.init();
Expand All @@ -48,6 +52,22 @@ public static void preInit(FMLPreInitializationEvent event) {
RegisterBlocks.register();
GameRegistry.registerWorldGenerator(new CatOreGen(), 0);
RegisterBiomes.init();
RegisterDimension.init();

// Custom Spawn Eggs
CatSpawnEgg catAgressiveEntitySpawnEgg = new CatSpawnEgg(CatAgressiveEntity.class);
catAgressiveEntitySpawnEgg.setUnlocalizedName("cat_agressive_spawn_egg")
.setCreativeTab(Catmod.catTab4)
.setTextureName(Reference.MOD_ID + ":eggcatagressiveentity.png");
CatAgressiveEntitySpawnEgg = catAgressiveEntitySpawnEgg;
GameRegistry.registerItem(CatAgressiveEntitySpawnEgg, "Cat Agressive Spawn Egg");

CatSpawnEgg catPassiveEntitySpawnEgg = new CatSpawnEgg(CatPassiveEntity.class);
catPassiveEntitySpawnEgg.setUnlocalizedName("cat_passive_spawn_egg")
.setCreativeTab(Catmod.catTab4)
.setTextureName(Reference.MOD_ID + ":eggcatpassiveentity.png");
CatPassiveEntitySpawnEgg = catPassiveEntitySpawnEgg;
GameRegistry.registerItem(CatPassiveEntitySpawnEgg, "Cat Passive Spawn Egg");
}

public static class WorldLoadHandler {
Expand Down
33 changes: 10 additions & 23 deletions src/main/java/fr/iamacat/catmod/biomes/catbiome/CatBiome.java
Original file line number Diff line number Diff line change
@@ -1,33 +1,20 @@
package fr.iamacat.catmod.biomes.catbiome;

import java.util.Random;

import net.minecraft.init.Blocks;
import net.minecraft.world.World;
import net.minecraft.world.biome.BiomeGenBase;

import fr.iamacat.catmod.init.RegisterBlocks;
import net.minecraft.world.biome.BiomeGenForest;

// its really a basic biome
public class CatBiome extends BiomeGenBase {
public class CatBiome extends BiomeGenForest {

public static final CatBiome INSTANCE = new CatBiome(100); // declare the biome instance as a static variable
public static final CatBiome INSTANCE = new CatBiome(100);

public CatBiome(int p_i1971_1_) {
super(p_i1971_1_);
this.topBlock = RegisterBlocks.catBlock;
public CatBiome(int p_i45377_1_) {
super(p_i45377_1_, 0);
this.topBlock = Blocks.grass;
this.fillerBlock = Blocks.stone;
this.setBiomeName("Cat Biome"); // set the name of the biome
this.enableRain = true;
this.setBiomeName("Cat Biome");
this.enableRain = false;
this.enableSnow = false;
this.waterColorMultiplier = 8336128;// color of water in hexadecimal to decimal :
// https://fr.calcuworld.com/calculs-mathematiques/calculatrice-hexadecimal/
// fact : the watercolormultiplier is only work if the enablerain = false
// this.addDefaultFlowers();

}

public void decorate(World p_76728_1_, Random p_76728_2_, int p_76728_3_, int p_76728_4_) {
// mean normally no flowers /no trees etc....
this.waterColorMultiplier = 8336128;
this.addDefaultFlowers();
}
}
3 changes: 1 addition & 2 deletions src/main/java/fr/iamacat/catmod/blocks/CatBlock.java
Original file line number Diff line number Diff line change
Expand Up @@ -7,11 +7,10 @@ public class CatBlock extends Block {

public CatBlock(Material rock) {
super(rock);

this.setHardness(2.0F);// resistance to pickaxe
this.setResistance(15.0F);// resistance to tnt
this.setHarvestLevel("pickaxe", 3);
// this.setLightLevel(14); how much the block will make light
// this.setBlockUnbreakable();//make the block unbreakable
// this.setBlockUnbreakable();
}
}
Loading
Loading