OUps, j'ai fait les commits à l'envers
26
.gitignore
vendored
@ -1,9 +1,25 @@
|
|||||||
|
# eclipse
|
||||||
|
bin
|
||||||
|
*.launch
|
||||||
|
.settings
|
||||||
|
.metadata
|
||||||
.classpath
|
.classpath
|
||||||
.gradle/
|
|
||||||
.project
|
.project
|
||||||
.settings/
|
|
||||||
bin/
|
# idea
|
||||||
eclipse/
|
out
|
||||||
gradle/
|
*.ipr
|
||||||
|
*.iws
|
||||||
|
*.iml
|
||||||
|
.idea
|
||||||
|
|
||||||
|
# gradle
|
||||||
|
build
|
||||||
|
.gradle
|
||||||
|
gradle
|
||||||
gradlew
|
gradlew
|
||||||
gradlew.bat
|
gradlew.bat
|
||||||
|
|
||||||
|
# other
|
||||||
|
eclipse
|
||||||
|
run
|
||||||
|
|||||||
152
build.gradle
@ -1,70 +1,82 @@
|
|||||||
buildscript {
|
/*
|
||||||
repositories {
|
// For those who want the bleeding edge
|
||||||
mavenCentral()
|
buildscript {
|
||||||
maven {
|
repositories {
|
||||||
name = "forge"
|
jcenter()
|
||||||
url = "http://files.minecraftforge.net/maven"
|
maven {
|
||||||
}
|
name = "forge"
|
||||||
maven {
|
url = "http://files.minecraftforge.net/maven"
|
||||||
name = "sonatype"
|
}
|
||||||
url = "https://oss.sonatype.org/content/repositories/snapshots/"
|
}
|
||||||
}
|
dependencies {
|
||||||
}
|
classpath 'net.minecraftforge.gradle:ForgeGradle:2.0-SNAPSHOT'
|
||||||
dependencies {
|
}
|
||||||
classpath 'net.minecraftforge.gradle:ForgeGradle:1.2-SNAPSHOT'
|
}
|
||||||
}
|
apply plugin: 'net.minecraftforge.gradle.forge'
|
||||||
}
|
*/
|
||||||
|
|
||||||
apply plugin: 'forge'
|
// for people who want stable
|
||||||
|
plugins {
|
||||||
version = "1.0"
|
id "net.minecraftforge.gradle.forge" version "2.0.2"
|
||||||
group= "com.yourname.modid" // http://maven.apache.org/guides/mini/guide-naming-conventions.html
|
}
|
||||||
archivesBaseName = "modid"
|
|
||||||
|
version = "1.0"
|
||||||
minecraft {
|
group= "com.yourname.modid" // http://maven.apache.org/guides/mini/guide-naming-conventions.html
|
||||||
version = "1.8-11.14.3.1450"
|
archivesBaseName = "modid"
|
||||||
runDir = "eclipse"
|
|
||||||
|
minecraft {
|
||||||
// the mappings can be changed at any time, and must be in the following format.
|
version = "1.8-11.14.4.1563"
|
||||||
// snapshot_YYYYMMDD snapshot are built nightly.
|
runDir = "run"
|
||||||
// stable_# stables are built at the discretion of the MCP team.
|
|
||||||
// Use non-default mappings at your own risk. they may not allways work.
|
// the mappings can be changed at any time, and must be in the following format.
|
||||||
// simply re-run your setup task after changing the mappings to update your workspace.
|
// snapshot_YYYYMMDD snapshot are built nightly.
|
||||||
mappings = "snapshot_20141130"
|
// stable_# stables are built at the discretion of the MCP team.
|
||||||
}
|
// Use non-default mappings at your own risk. they may not allways work.
|
||||||
|
// simply re-run your setup task after changing the mappings to update your workspace.
|
||||||
dependencies {
|
mappings = "snapshot_20141130"
|
||||||
// you may put jars on which you depend on in ./libs
|
// makeObfSourceJar = false // an Srg named sources jar is made by default. uncomment this to disable.
|
||||||
// or you may define them like so..
|
}
|
||||||
//compile "some.group:artifact:version:classifier"
|
|
||||||
//compile "some.group:artifact:version"
|
dependencies {
|
||||||
|
// you may put jars on which you depend on in ./libs
|
||||||
// real examples
|
// or you may define them like so..
|
||||||
//compile 'com.mod-buildcraft:buildcraft:6.0.8:dev' // adds buildcraft to the dev env
|
//compile "some.group:artifact:version:classifier"
|
||||||
//compile 'com.googlecode.efficient-java-matrix-library:ejml:0.24' // adds ejml to the dev env
|
//compile "some.group:artifact:version"
|
||||||
|
|
||||||
// for more info...
|
// real examples
|
||||||
// http://www.gradle.org/docs/current/userguide/artifact_dependencies_tutorial.html
|
//compile 'com.mod-buildcraft:buildcraft:6.0.8:dev' // adds buildcraft to the dev env
|
||||||
// http://www.gradle.org/docs/current/userguide/dependency_management.html
|
//compile 'com.googlecode.efficient-java-matrix-library:ejml:0.24' // adds ejml to the dev env
|
||||||
|
|
||||||
}
|
// the 'provided' configuration is for optional dependencies that exist at compile-time but might not at runtime.
|
||||||
|
//provided 'com.mod-buildcraft:buildcraft:6.0.8:dev'
|
||||||
processResources
|
|
||||||
{
|
// the deobf configurations: 'deobfCompile' and 'deobfProvided' are the same as the normal compile and provided,
|
||||||
// this will ensure that this task is redone when the versions change.
|
// except that these dependencies get remapped to your current MCP mappings
|
||||||
inputs.property "version", project.version
|
//deobfCompile 'com.mod-buildcraft:buildcraft:6.0.8:dev'
|
||||||
inputs.property "mcversion", project.minecraft.version
|
//deobfProvided 'com.mod-buildcraft:buildcraft:6.0.8:dev'
|
||||||
|
|
||||||
// replace stuff in mcmod.info, nothing else
|
// for more info...
|
||||||
from(sourceSets.main.resources.srcDirs) {
|
// http://www.gradle.org/docs/current/userguide/artifact_dependencies_tutorial.html
|
||||||
include 'mcmod.info'
|
// http://www.gradle.org/docs/current/userguide/dependency_management.html
|
||||||
|
|
||||||
// replace version and mcversion
|
}
|
||||||
expand 'version':project.version, 'mcversion':project.minecraft.version
|
|
||||||
}
|
processResources
|
||||||
|
{
|
||||||
// copy everything else, thats not the mcmod.info
|
// this will ensure that this task is redone when the versions change.
|
||||||
from(sourceSets.main.resources.srcDirs) {
|
inputs.property "version", project.version
|
||||||
exclude 'mcmod.info'
|
inputs.property "mcversion", project.minecraft.version
|
||||||
}
|
|
||||||
}
|
// replace stuff in mcmod.info, nothing else
|
||||||
|
from(sourceSets.main.resources.srcDirs) {
|
||||||
|
include 'mcmod.info'
|
||||||
|
|
||||||
|
// replace version and mcversion
|
||||||
|
expand 'version':project.version, 'mcversion':project.minecraft.version
|
||||||
|
}
|
||||||
|
|
||||||
|
// copy everything else, thats not the mcmod.info
|
||||||
|
from(sourceSets.main.resources.srcDirs) {
|
||||||
|
exclude 'mcmod.info'
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|||||||
@ -1,9 +1,5 @@
|
|||||||
package com.samsoule63.luckyWaking;
|
package com.samsoule63.luckyWaking;
|
||||||
|
|
||||||
import com.samsoule63.luckyWaking.init.LuckyWakingBlocks;
|
|
||||||
import com.samsoule63.luckyWaking.init.LuckyWakingItems;
|
|
||||||
import com.samsoule63.luckyWaking.proxy.ProxyCommon;
|
|
||||||
|
|
||||||
import net.minecraftforge.fml.common.Mod;
|
import net.minecraftforge.fml.common.Mod;
|
||||||
import net.minecraftforge.fml.common.Mod.EventHandler;
|
import net.minecraftforge.fml.common.Mod.EventHandler;
|
||||||
import net.minecraftforge.fml.common.SidedProxy;
|
import net.minecraftforge.fml.common.SidedProxy;
|
||||||
@ -11,31 +7,34 @@ import net.minecraftforge.fml.common.event.FMLInitializationEvent;
|
|||||||
import net.minecraftforge.fml.common.event.FMLPostInitializationEvent;
|
import net.minecraftforge.fml.common.event.FMLPostInitializationEvent;
|
||||||
import net.minecraftforge.fml.common.event.FMLPreInitializationEvent;
|
import net.minecraftforge.fml.common.event.FMLPreInitializationEvent;
|
||||||
|
|
||||||
@Mod(modid = References.MODID, name = References.MODNAME, version = References.VERSION)
|
import com.samsoule63.luckyWaking.init.LuckyWakingBlocks;
|
||||||
public class LuckyWakingMod
|
import com.samsoule63.luckyWaking.init.LuckyWakingItems;
|
||||||
{
|
import com.samsoule63.luckyWaking.init.LuckyWakingRecipies;
|
||||||
@SidedProxy(clientSide = References.CLIENT_PROXY, serverSide = References.COMMON_PROXY)
|
import com.samsoule63.luckyWaking.proxy.CommonProxy;
|
||||||
public static ProxyCommon proxy;
|
|
||||||
|
|
||||||
@EventHandler
|
|
||||||
public void preInit(FMLPreInitializationEvent event)
|
|
||||||
{
|
|
||||||
LuckyWakingItems.init();
|
|
||||||
LuckyWakingItems.register();
|
|
||||||
LuckyWakingBlocks.init();
|
|
||||||
LuckyWakingBlocks.register();
|
|
||||||
}
|
|
||||||
|
|
||||||
@EventHandler
|
@Mod(modid=References.MOD_ID,name = References.MOD_NAME,version = References.VERSION)
|
||||||
public void init(FMLInitializationEvent event)
|
public class LuckyWakingMod {
|
||||||
{
|
|
||||||
proxy.registerRenders();
|
|
||||||
}
|
|
||||||
|
|
||||||
@EventHandler
|
|
||||||
public void postInit(FMLPostInitializationEvent event)
|
|
||||||
{
|
|
||||||
|
|
||||||
}
|
|
||||||
|
|
||||||
|
@SidedProxy(clientSide = References.CLIENT_PROXY , serverSide = References.COMMON_PROXY)
|
||||||
|
public static CommonProxy proxy;
|
||||||
|
|
||||||
|
@EventHandler
|
||||||
|
public void preInit(FMLPreInitializationEvent event){
|
||||||
|
LuckyWakingItems.init();
|
||||||
|
LuckyWakingItems.register();
|
||||||
|
LuckyWakingBlocks.init();
|
||||||
|
LuckyWakingBlocks.register();
|
||||||
|
LuckyWakingRecipies.registerCrafts();
|
||||||
|
}
|
||||||
|
@EventHandler
|
||||||
|
public void init(FMLInitializationEvent event){
|
||||||
|
|
||||||
|
proxy.registerRenders();
|
||||||
|
|
||||||
|
}
|
||||||
|
@EventHandler
|
||||||
|
public void postInit(FMLPostInitializationEvent event){
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|||||||
@ -1,10 +1,11 @@
|
|||||||
package com.samsoule63.luckyWaking;
|
package com.samsoule63.luckyWaking;
|
||||||
|
|
||||||
public class References
|
public class References {
|
||||||
{
|
|
||||||
public static final String MODID = "luckyW";
|
public static final String MOD_ID = "luckywaking";
|
||||||
public static final String MODNAME = "Lucky Waking";
|
public static final String MOD_NAME = "Lucky Waking ?";
|
||||||
public static final String VERSION = "1.0";
|
public static final String VERSION = "1.0";
|
||||||
public static final String CLIENT_PROXY = "com.samsoule63.luckyWaking.proxy.ProxyClient";
|
public static final String CLIENT_PROXY = "com.samsoule63.luckyWaking.proxy.ClientProxy";
|
||||||
public static final String COMMON_PROXY = "com.samsoule63.luckyWaking.proxy.ProxyCommon";
|
public static final String COMMON_PROXY = "com.samsoule63.luckyWaking.proxy.CommonProxy";
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|||||||
@ -3,13 +3,10 @@ package com.samsoule63.luckyWaking.blocks;
|
|||||||
import net.minecraft.block.Block;
|
import net.minecraft.block.Block;
|
||||||
import net.minecraft.block.material.Material;
|
import net.minecraft.block.material.Material;
|
||||||
|
|
||||||
public class StarBlock extends Block
|
public class StarBlock extends Block{
|
||||||
{
|
|
||||||
|
|
||||||
public StarBlock(Material materialIn)
|
public StarBlock(Material materialIn) {
|
||||||
{
|
super(materialIn);
|
||||||
super(materialIn);
|
}
|
||||||
// TODO Auto-generated constructor stub
|
|
||||||
}
|
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|||||||
@ -1,11 +0,0 @@
|
|||||||
package com.samsoule63.luckyWaking.event;
|
|
||||||
|
|
||||||
import net.minecraft.entity.player.EntityPlayer;
|
|
||||||
import net.minecraft.util.BlockPos;
|
|
||||||
|
|
||||||
public class OnPlayerSleep
|
|
||||||
{
|
|
||||||
public static void onPlayerSleep(EntityPlayer player, BlockPos pos){
|
|
||||||
System.out.println("!!!!****µµµµ$$$$££££"+player.toString()+"sleep in "+pos.toString());
|
|
||||||
}
|
|
||||||
}
|
|
||||||
@ -1,29 +0,0 @@
|
|||||||
package com.samsoule63.luckyWaking.event;
|
|
||||||
|
|
||||||
import tv.twitch.chat.ChatMessageToken;
|
|
||||||
import net.minecraft.entity.player.EntityPlayer;
|
|
||||||
import net.minecraft.util.ChatComponentText;
|
|
||||||
import net.minecraft.util.IChatComponent;
|
|
||||||
|
|
||||||
public class OnPlayerWakeUp
|
|
||||||
{
|
|
||||||
public static void playerWakeUp(EntityPlayer player, boolean wakeImmediatly, boolean updateWorld, boolean setSpawn)
|
|
||||||
{
|
|
||||||
int z = (int)(Math.random() * 2);
|
|
||||||
switch(z)
|
|
||||||
{
|
|
||||||
case 0:
|
|
||||||
player.addChatComponentMessage(new ChatComponentText("Ca te dit une barre de vie en plus ?"));;
|
|
||||||
player.setAbsorptionAmount(player.getAbsorptionAmount() + 20);
|
|
||||||
break;
|
|
||||||
case 1:
|
|
||||||
player.addChatComponentMessage(new ChatComponentText("Ca te dit 100 niveaux en plus ?"));;
|
|
||||||
player.addExperienceLevel(100);
|
|
||||||
break;
|
|
||||||
default:
|
|
||||||
player.addChatComponentMessage(new ChatComponentText("Rien aujourdhui ..."));;
|
|
||||||
|
|
||||||
break;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
@ -1,8 +1,5 @@
|
|||||||
package com.samsoule63.luckyWaking.init;
|
package com.samsoule63.luckyWaking.init;
|
||||||
|
|
||||||
import com.samsoule63.luckyWaking.References;
|
|
||||||
import com.samsoule63.luckyWaking.blocks.StarBlock;
|
|
||||||
|
|
||||||
import net.minecraft.block.Block;
|
import net.minecraft.block.Block;
|
||||||
import net.minecraft.block.material.Material;
|
import net.minecraft.block.material.Material;
|
||||||
import net.minecraft.client.Minecraft;
|
import net.minecraft.client.Minecraft;
|
||||||
@ -11,28 +8,27 @@ import net.minecraft.creativetab.CreativeTabs;
|
|||||||
import net.minecraft.item.Item;
|
import net.minecraft.item.Item;
|
||||||
import net.minecraftforge.fml.common.registry.GameRegistry;
|
import net.minecraftforge.fml.common.registry.GameRegistry;
|
||||||
|
|
||||||
public class LuckyWakingBlocks
|
import com.samsoule63.luckyWaking.References;
|
||||||
{
|
import com.samsoule63.luckyWaking.blocks.StarBlock;
|
||||||
public static Block starBlock;
|
|
||||||
|
|
||||||
public static void init()
|
public class LuckyWakingBlocks {
|
||||||
{
|
|
||||||
starBlock = new StarBlock(Material.ground).setUnlocalizedName("starBlock").setCreativeTab(CreativeTabs.tabBlock);
|
|
||||||
}
|
|
||||||
|
|
||||||
public static void register()
|
public static Block starBlock;
|
||||||
{
|
|
||||||
GameRegistry.registerBlock(starBlock,starBlock.getUnlocalizedName().substring(5));
|
|
||||||
}
|
|
||||||
|
|
||||||
public static void registerRenders()
|
public static void init() {
|
||||||
{
|
starBlock = new StarBlock(Material.ice).setUnlocalizedName("starBlock").setCreativeTab(CreativeTabs.tabBlock);
|
||||||
registerRender(starBlock);
|
}
|
||||||
}
|
|
||||||
|
|
||||||
public static void registerRender(Block block)
|
public static void register() {
|
||||||
{
|
GameRegistry.registerBlock(starBlock, starBlock.getUnlocalizedName().substring(5));
|
||||||
Item item = Item.getItemFromBlock(block);
|
}
|
||||||
Minecraft.getMinecraft().getRenderItem().getItemModelMesher().register(item, 0, new ModelResourceLocation(References.MODID + ":" + item.getUnlocalizedName().substring(5), "inventory"));
|
|
||||||
}
|
public static void registerRenders() {
|
||||||
|
registerRender(starBlock);
|
||||||
|
}
|
||||||
|
|
||||||
|
public static void registerRender(Block block) {
|
||||||
|
Item item = Item.getItemFromBlock(block);
|
||||||
|
Minecraft.getMinecraft().getRenderItem().getItemModelMesher().register(item, 0, new ModelResourceLocation(References.MOD_ID + ":" + item.getUnlocalizedName().substring(5), "inventory"));
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@ -1,34 +1,60 @@
|
|||||||
package com.samsoule63.luckyWaking.init;
|
package com.samsoule63.luckyWaking.init;
|
||||||
|
|
||||||
import com.samsoule63.luckyWaking.References;
|
|
||||||
|
|
||||||
import net.minecraft.client.Minecraft;
|
import net.minecraft.client.Minecraft;
|
||||||
import net.minecraft.client.resources.model.ModelResourceLocation;
|
import net.minecraft.client.resources.model.ModelResourceLocation;
|
||||||
import net.minecraft.creativetab.CreativeTabs;
|
import net.minecraft.creativetab.CreativeTabs;
|
||||||
import net.minecraft.item.Item;
|
import net.minecraft.item.Item;
|
||||||
import net.minecraftforge.fml.common.registry.GameRegistry;
|
import net.minecraftforge.fml.common.registry.GameRegistry;
|
||||||
|
|
||||||
public class LuckyWakingItems
|
import com.samsoule63.luckyWaking.References;
|
||||||
{
|
import com.samsoule63.luckyWaking.items.armors.UselessArmor;
|
||||||
public static Item itemBasic;
|
import com.samsoule63.luckyWaking.items.tools.LuckyWakingToolsMaterials;
|
||||||
|
import com.samsoule63.luckyWaking.items.tools.UselessPickaxe;
|
||||||
|
import com.samsoule63.luckyWaking.items.tools.UselessSword;
|
||||||
|
|
||||||
public static void init()
|
public class LuckyWakingItems {
|
||||||
{
|
|
||||||
itemBasic = new Item().setUnlocalizedName("itemBasic").setCreativeTab(CreativeTabs.tabMisc);
|
|
||||||
}
|
|
||||||
|
|
||||||
public static void register()
|
public static Item theUselessItem;
|
||||||
{
|
public static Item uselessPickaxe;
|
||||||
GameRegistry.registerItem(itemBasic, "itemBasic");
|
public static Item uselessSword;
|
||||||
}
|
public static Item uselessHelmet;
|
||||||
|
public static Item uselessChestplate;
|
||||||
|
public static Item uselessLeggins;
|
||||||
|
public static Item uselessBoots;
|
||||||
|
|
||||||
public static void registerRenders()
|
public static void init() {
|
||||||
{
|
theUselessItem = new Item().setUnlocalizedName("theUselessItem").setCreativeTab(CreativeTabs.tabMisc);
|
||||||
registerRender(itemBasic);
|
uselessPickaxe = new UselessPickaxe(LuckyWakingToolsMaterials.uselessTool).setUnlocalizedName("uselessPickaxe").setCreativeTab(CreativeTabs.tabTools);
|
||||||
}
|
uselessSword = new UselessSword(LuckyWakingToolsMaterials.uselessTool).setUnlocalizedName("uselessSword").setCreativeTab(CreativeTabs.tabCombat);
|
||||||
|
uselessHelmet = new UselessArmor(UselessArmor.uselessArmor,0).setUnlocalizedName("uselessHelmet");
|
||||||
|
uselessChestplate = new UselessArmor(UselessArmor.uselessArmor, 1).setUnlocalizedName("uselessChestplate");
|
||||||
|
uselessLeggins = new UselessArmor(UselessArmor.uselessArmor, 2).setUnlocalizedName("uselessLeggins");
|
||||||
|
uselessBoots = new UselessArmor(UselessArmor.uselessArmor, 3).setUnlocalizedName("uselessBoots");
|
||||||
|
}
|
||||||
|
|
||||||
|
public static void register() {
|
||||||
|
GameRegistry.registerItem(theUselessItem, theUselessItem.getUnlocalizedName().substring(5));
|
||||||
|
GameRegistry.registerItem(uselessPickaxe, uselessPickaxe.getUnlocalizedName().substring(5));
|
||||||
|
GameRegistry.registerItem(uselessSword, uselessSword.getUnlocalizedName().substring(5));
|
||||||
|
GameRegistry.registerItem(uselessHelmet, uselessHelmet.getUnlocalizedName().substring(5));
|
||||||
|
GameRegistry.registerItem(uselessChestplate, uselessChestplate.getUnlocalizedName().substring(5));
|
||||||
|
GameRegistry.registerItem(uselessLeggins, uselessLeggins.getUnlocalizedName().substring(5));
|
||||||
|
GameRegistry.registerItem(uselessBoots, uselessBoots.getUnlocalizedName().substring(5));
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
public static void registerRenders() {
|
||||||
|
registerRender(theUselessItem);
|
||||||
|
registerRender(uselessPickaxe);
|
||||||
|
registerRender(uselessSword);
|
||||||
|
registerRender(uselessHelmet);
|
||||||
|
registerRender(uselessChestplate);
|
||||||
|
registerRender(uselessLeggins);
|
||||||
|
registerRender(uselessBoots);
|
||||||
|
}
|
||||||
|
|
||||||
|
public static void registerRender(Item item) {
|
||||||
|
Minecraft.getMinecraft().getRenderItem().getItemModelMesher().register(item, 0, new ModelResourceLocation(References.MOD_ID + ":" + item.getUnlocalizedName().substring(5), "inventory"));
|
||||||
|
}
|
||||||
|
|
||||||
public static void registerRender(Item item)
|
|
||||||
{
|
|
||||||
Minecraft.getMinecraft().getRenderItem().getItemModelMesher().register(item, 0, new ModelResourceLocation(References.MODID + ":" + item.getUnlocalizedName().substring(5), "inventory"));
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
|||||||
@ -0,0 +1,24 @@
|
|||||||
|
package com.samsoule63.luckyWaking.init;
|
||||||
|
|
||||||
|
import net.minecraft.block.Block;
|
||||||
|
import net.minecraft.init.Blocks;
|
||||||
|
import net.minecraft.init.Items;
|
||||||
|
import net.minecraft.item.ItemStack;
|
||||||
|
import net.minecraftforge.fml.common.registry.GameRegistry;
|
||||||
|
|
||||||
|
public class LuckyWakingRecipies {
|
||||||
|
|
||||||
|
public static void registerCrafts() {
|
||||||
|
GameRegistry.addRecipe(new ItemStack(LuckyWakingItems.theUselessItem, 4), new Object[]{"FFR", "S R", "SPP", 'S', Items.flint, 'P', Items.feather, 'R', Items.dye, 'F', Blocks.leaves});
|
||||||
|
GameRegistry.addSmelting(Blocks.carpet, new ItemStack(LuckyWakingItems.theUselessItem, 16), 2f);
|
||||||
|
|
||||||
|
GameRegistry.addRecipe(new ItemStack(LuckyWakingBlocks.starBlock,4),new Object[]{
|
||||||
|
" S ",
|
||||||
|
"SWS",
|
||||||
|
" S ",
|
||||||
|
'S',Items.snowball,
|
||||||
|
'W',new ItemStack(Blocks.wool, 4, 15)
|
||||||
|
});
|
||||||
|
}
|
||||||
|
|
||||||
|
}
|
||||||
@ -0,0 +1,29 @@
|
|||||||
|
package com.samsoule63.luckyWaking.items.armors;
|
||||||
|
|
||||||
|
import com.samsoule63.luckyWaking.References;
|
||||||
|
import com.samsoule63.luckyWaking.init.LuckyWakingItems;
|
||||||
|
|
||||||
|
import net.minecraft.entity.Entity;
|
||||||
|
import net.minecraft.item.ItemArmor;
|
||||||
|
import net.minecraft.item.ItemStack;
|
||||||
|
import net.minecraftforge.common.util.EnumHelper;
|
||||||
|
|
||||||
|
public class UselessArmor extends ItemArmor {
|
||||||
|
|
||||||
|
public static ArmorMaterial uselessArmor = EnumHelper.addArmorMaterial("uselessArmor", "uselessArmor", 2, new int[]{1, 2, 1, 1}, 100);
|
||||||
|
|
||||||
|
public UselessArmor(ArmorMaterial material, int armorType) {
|
||||||
|
super(material, 0, armorType);
|
||||||
|
}
|
||||||
|
public String getRenderTexture(ItemStack stack, Entity entity, int slot, String type) {
|
||||||
|
if (stack.getItem() == LuckyWakingItems.uselessLeggins) {
|
||||||
|
return References.MOD_ID + ":textures/models/armor/uselessArmor_layer_2.png";
|
||||||
|
} else if (stack.getItem() == LuckyWakingItems.uselessHelmet
|
||||||
|
|| stack.getItem() == LuckyWakingItems.uselessChestplate
|
||||||
|
|| stack.getItem() == LuckyWakingItems.uselessBoots) {
|
||||||
|
return References.MOD_ID+":textures/models/armor/uselessArmor_layer_1.png";
|
||||||
|
} else {
|
||||||
|
return null;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
@ -0,0 +1,9 @@
|
|||||||
|
package com.samsoule63.luckyWaking.items.tools;
|
||||||
|
|
||||||
|
import net.minecraft.item.Item.ToolMaterial;
|
||||||
|
import net.minecraftforge.common.util.EnumHelper;
|
||||||
|
|
||||||
|
public class LuckyWakingToolsMaterials {
|
||||||
|
public static ToolMaterial uselessTool = EnumHelper.addToolMaterial("useless",3, 10, 24.0F, 1.0F,100);
|
||||||
|
|
||||||
|
}
|
||||||
@ -0,0 +1,14 @@
|
|||||||
|
package com.samsoule63.luckyWaking.items.tools;
|
||||||
|
|
||||||
|
import net.minecraft.item.ItemPickaxe;
|
||||||
|
import net.minecraftforge.common.util.EnumHelper;
|
||||||
|
|
||||||
|
public class UselessPickaxe extends ItemPickaxe{
|
||||||
|
|
||||||
|
|
||||||
|
public UselessPickaxe(ToolMaterial material) {
|
||||||
|
super(material);
|
||||||
|
// TODO Auto-generated constructor stub
|
||||||
|
}
|
||||||
|
|
||||||
|
}
|
||||||
@ -0,0 +1,12 @@
|
|||||||
|
package com.samsoule63.luckyWaking.items.tools;
|
||||||
|
|
||||||
|
import net.minecraft.item.ItemSword;
|
||||||
|
|
||||||
|
public class UselessSword extends ItemSword{
|
||||||
|
|
||||||
|
public UselessSword(ToolMaterial material) {
|
||||||
|
super(material);
|
||||||
|
// TODO Auto-generated constructor stub
|
||||||
|
}
|
||||||
|
|
||||||
|
}
|
||||||
@ -0,0 +1,13 @@
|
|||||||
|
package com.samsoule63.luckyWaking.proxy;
|
||||||
|
|
||||||
|
import com.samsoule63.luckyWaking.init.LuckyWakingBlocks;
|
||||||
|
import com.samsoule63.luckyWaking.init.LuckyWakingItems;
|
||||||
|
|
||||||
|
public class ClientProxy extends CommonProxy{
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public void registerRenders(){
|
||||||
|
LuckyWakingItems.registerRenders();
|
||||||
|
LuckyWakingBlocks.registerRenders();
|
||||||
|
}
|
||||||
|
}
|
||||||
@ -0,0 +1,9 @@
|
|||||||
|
package com.samsoule63.luckyWaking.proxy;
|
||||||
|
|
||||||
|
public class CommonProxy {
|
||||||
|
|
||||||
|
public void registerRenders() {
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
}
|
||||||
@ -1,15 +0,0 @@
|
|||||||
package com.samsoule63.luckyWaking.proxy;
|
|
||||||
|
|
||||||
import com.samsoule63.luckyWaking.init.LuckyWakingBlocks;
|
|
||||||
import com.samsoule63.luckyWaking.init.LuckyWakingItems;
|
|
||||||
|
|
||||||
public class ProxyClient extends ProxyCommon
|
|
||||||
{
|
|
||||||
@Override
|
|
||||||
public void registerRenders()
|
|
||||||
{
|
|
||||||
LuckyWakingItems.registerRenders();
|
|
||||||
LuckyWakingBlocks.registerRenders();
|
|
||||||
}
|
|
||||||
|
|
||||||
}
|
|
||||||
@ -1,11 +0,0 @@
|
|||||||
package com.samsoule63.luckyWaking.proxy;
|
|
||||||
|
|
||||||
public class ProxyCommon
|
|
||||||
{
|
|
||||||
|
|
||||||
public void registerRenders()
|
|
||||||
{
|
|
||||||
|
|
||||||
}
|
|
||||||
|
|
||||||
}
|
|
||||||
@ -1,35 +0,0 @@
|
|||||||
package net.minecraftforge.event.entity.player;
|
|
||||||
|
|
||||||
import com.samsoule63.luckyWaking.event.OnPlayerSleep;
|
|
||||||
|
|
||||||
import net.minecraft.entity.player.EntityPlayer;
|
|
||||||
import net.minecraft.entity.player.EntityPlayer.EnumStatus;
|
|
||||||
import net.minecraft.util.BlockPos;
|
|
||||||
import net.minecraft.entity.player.EntityPlayer.EnumStatus;
|
|
||||||
/**
|
|
||||||
* PlayerSleepInBedEvent is fired when a player sleeps in a bed.
|
|
||||||
* <br>
|
|
||||||
* This event is fired whenever a player sleeps in a bed in
|
|
||||||
* EntityPlayer#sleepInBedAt(BlockPos).<br>
|
|
||||||
* <br>
|
|
||||||
* {@link #result} contains whether the player is able to sleep. <br>
|
|
||||||
* <br>
|
|
||||||
* This event is not {@link Cancelable}.
|
|
||||||
* <br>
|
|
||||||
* This event does not have a result. {@link HasResult}
|
|
||||||
* <br>
|
|
||||||
* This event is fired on the {@link MinecraftForge#EVENT_BUS}.
|
|
||||||
**/
|
|
||||||
public class PlayerSleepInBedEvent extends PlayerEvent
|
|
||||||
{
|
|
||||||
public EnumStatus result = null;
|
|
||||||
public final BlockPos pos;
|
|
||||||
|
|
||||||
public PlayerSleepInBedEvent(EntityPlayer player, BlockPos pos)
|
|
||||||
{
|
|
||||||
super(player);
|
|
||||||
OnPlayerSleep.onPlayerSleep(player, pos);
|
|
||||||
this.pos = pos;
|
|
||||||
}
|
|
||||||
|
|
||||||
}
|
|
||||||
@ -1,40 +0,0 @@
|
|||||||
package net.minecraftforge.event.entity.player;
|
|
||||||
|
|
||||||
import com.samsoule63.luckyWaking.event.OnPlayerWakeUp;
|
|
||||||
|
|
||||||
import net.minecraft.entity.player.EntityPlayer;
|
|
||||||
|
|
||||||
/**
|
|
||||||
* This event is fired when the player is waking up.<br/>
|
|
||||||
* This is merely for purposes of listening for this to happen.<br/>
|
|
||||||
* There is nothing that can be manipulated with this event.
|
|
||||||
*/
|
|
||||||
public class PlayerWakeUpEvent extends PlayerEvent
|
|
||||||
{
|
|
||||||
/**
|
|
||||||
* Used for the 'wake up animation'.
|
|
||||||
* This is false if the player is considered 'sleepy' and the overlay should slowly fade away.
|
|
||||||
*/
|
|
||||||
public final boolean wakeImmediatly;
|
|
||||||
|
|
||||||
/**
|
|
||||||
* Indicates if the server should be notified of sleeping changes.
|
|
||||||
* This will only be false if the server is considered 'up to date' already, because, for example, it initiated the call.
|
|
||||||
*/
|
|
||||||
public final boolean updateWorld;
|
|
||||||
|
|
||||||
/**
|
|
||||||
* Indicates if the player's sleep was considered successful.
|
|
||||||
* In vanilla, this is used to determine if the spawn chunk is to be set to the bed's position.
|
|
||||||
*/
|
|
||||||
public final boolean setSpawn;
|
|
||||||
|
|
||||||
public PlayerWakeUpEvent(EntityPlayer player, boolean wakeImmediatly, boolean updateWorld, boolean setSpawn)
|
|
||||||
{
|
|
||||||
super(player);
|
|
||||||
this.wakeImmediatly = wakeImmediatly;
|
|
||||||
this.updateWorld = updateWorld;
|
|
||||||
this.setSpawn = setSpawn;
|
|
||||||
OnPlayerWakeUp.playerWakeUp(player, wakeImmediatly, updateWorld, setSpawn);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
@ -1,7 +0,0 @@
|
|||||||
{
|
|
||||||
"variants": {
|
|
||||||
"normal": [
|
|
||||||
{ "model": "luckyW:starBlock" },
|
|
||||||
]
|
|
||||||
}
|
|
||||||
}
|
|
||||||
@ -1,3 +0,0 @@
|
|||||||
item.itemBasic.name=Item Basique
|
|
||||||
|
|
||||||
tile.starBlock.name=Bloc étoile
|
|
||||||
|
Before Width: | Height: | Size: 1.2 KiB |
@ -0,0 +1,5 @@
|
|||||||
|
{
|
||||||
|
"variants": {
|
||||||
|
"normal": { "model": "luckywaking:starBlock" }
|
||||||
|
}
|
||||||
|
}
|
||||||
5
src/main/resources/assets/luckywaking/lang/fr_FR.lang
Normal file
@ -0,0 +1,5 @@
|
|||||||
|
item.theUselessItem.name=The Useless Item
|
||||||
|
item.uselessPickaxe.name=La pioche de l'inutilit?
|
||||||
|
item.uselessSword.name=L'?p?e de l'inutilit?
|
||||||
|
|
||||||
|
tile.starBlock.name=§8Star block !!!
|
||||||
@ -1,6 +1,6 @@
|
|||||||
{
|
{
|
||||||
"parent": "block/cube_all",
|
"parent": "block/cube_all",
|
||||||
"textures": {
|
"textures": {
|
||||||
"all": "luckyw:item/starBlock"
|
"all": "luckywaking:blocks/starBlock"
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@ -1,5 +1,5 @@
|
|||||||
{
|
{
|
||||||
"parent": "luckyW:block/starBlock",
|
"parent": "luckywaking:block/starBlock",
|
||||||
"display": {
|
"display": {
|
||||||
"thirdperson": {
|
"thirdperson": {
|
||||||
"rotation": [ 10, -45, 170 ],
|
"rotation": [ 10, -45, 170 ],
|
||||||
@ -1,7 +1,7 @@
|
|||||||
{
|
{
|
||||||
"parent": "builtin/generated",
|
"parent": "builtin/generated",
|
||||||
"textures": {
|
"textures": {
|
||||||
"layer0": "luckyW:items/itemBasic"
|
"layer0": "luckywaking:items/theUselessItem"
|
||||||
},
|
},
|
||||||
"display": {
|
"display": {
|
||||||
"thirdperson": {
|
"thirdperson": {
|
||||||
@ -0,0 +1,18 @@
|
|||||||
|
{
|
||||||
|
"parent": "builtin/generated",
|
||||||
|
"textures": {
|
||||||
|
"layer0": "luckyWaking:items/uselessBoots"
|
||||||
|
},
|
||||||
|
"display": {
|
||||||
|
"thirdperson": {
|
||||||
|
"rotation": [ -90, 0, 0 ],
|
||||||
|
"translation": [ 0, 1, -2.5 ],
|
||||||
|
"scale": [ 0.55, 0.55, 0.55 ]
|
||||||
|
},
|
||||||
|
"firstperson": {
|
||||||
|
"rotation": [ 0, -135, 25 ],
|
||||||
|
"translation": [ 0, 4, 2 ],
|
||||||
|
"scale": [ 1.7, 1.7, 1.7 ]
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
@ -0,0 +1,18 @@
|
|||||||
|
{
|
||||||
|
"parent": "builtin/generated",
|
||||||
|
"textures": {
|
||||||
|
"layer0": "luckyWaking:items/uselessChestplate"
|
||||||
|
},
|
||||||
|
"display": {
|
||||||
|
"thirdperson": {
|
||||||
|
"rotation": [ -90, 0, 0 ],
|
||||||
|
"translation": [ 0, 1, -3 ],
|
||||||
|
"scale": [ 0.55, 0.55, 0.55 ]
|
||||||
|
},
|
||||||
|
"firstperson": {
|
||||||
|
"rotation": [ 0, -135, 25 ],
|
||||||
|
"translation": [ 0, 4, 2 ],
|
||||||
|
"scale": [ 1.7, 1.7, 1.7 ]
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
@ -0,0 +1,18 @@
|
|||||||
|
{
|
||||||
|
"parent": "builtin/generated",
|
||||||
|
"textures": {
|
||||||
|
"layer0": "luckyWaking:items/uselessHelmet"
|
||||||
|
},
|
||||||
|
"display": {
|
||||||
|
"thirdperson": {
|
||||||
|
"rotation": [ -90, 0, 0 ],
|
||||||
|
"translation": [ 0, 1, -2.25 ],
|
||||||
|
"scale": [ 0.55, 0.55, 0.55 ]
|
||||||
|
},
|
||||||
|
"firstperson": {
|
||||||
|
"rotation": [ 0, -135, 25 ],
|
||||||
|
"translation": [ 0, 4, 2 ],
|
||||||
|
"scale": [ 1.7, 1.7, 1.7 ]
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
@ -0,0 +1,18 @@
|
|||||||
|
{
|
||||||
|
"parent": "builtin/generated",
|
||||||
|
"textures": {
|
||||||
|
"layer0": "luckyWaking:items/uselessLeggins"
|
||||||
|
},
|
||||||
|
"display": {
|
||||||
|
"thirdperson": {
|
||||||
|
"rotation": [ -90, 0, 0 ],
|
||||||
|
"translation": [ 0, 1, -3 ],
|
||||||
|
"scale": [ 0.55, 0.55, 0.55 ]
|
||||||
|
},
|
||||||
|
"firstperson": {
|
||||||
|
"rotation": [ 0, -135, 25 ],
|
||||||
|
"translation": [ 0, 4, 2 ],
|
||||||
|
"scale": [ 1.7, 1.7, 1.7 ]
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
@ -0,0 +1,18 @@
|
|||||||
|
{
|
||||||
|
"parent": "builtin/generated",
|
||||||
|
"textures": {
|
||||||
|
"layer0": "luckyWaking:items/uselessPickaxe"
|
||||||
|
},
|
||||||
|
"display": {
|
||||||
|
"thirdperson": {
|
||||||
|
"rotation": [ 0, 90, -35 ],
|
||||||
|
"translation": [ 0, 1.25, -3.5 ],
|
||||||
|
"scale": [ 0.85, 0.85, 0.85 ]
|
||||||
|
},
|
||||||
|
"firstperson": {
|
||||||
|
"rotation": [ 0, -135, 25 ],
|
||||||
|
"translation": [ 0, 4, 2 ],
|
||||||
|
"scale": [ 1.7, 1.7, 1.7 ]
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
@ -0,0 +1,18 @@
|
|||||||
|
{
|
||||||
|
"parent": "builtin/generated",
|
||||||
|
"textures": {
|
||||||
|
"layer0": "luckyWaking:items/uselessSword"
|
||||||
|
},
|
||||||
|
"display": {
|
||||||
|
"thirdperson": {
|
||||||
|
"rotation": [ 0, 90, -35 ],
|
||||||
|
"translation": [ 0, 1.25, -3.5 ],
|
||||||
|
"scale": [ 0.85, 0.85, 0.85 ]
|
||||||
|
},
|
||||||
|
"firstperson": {
|
||||||
|
"rotation": [ 0, -135, 25 ],
|
||||||
|
"translation": [ 0, 4, 2 ],
|
||||||
|
"scale": [ 1.7, 1.7, 1.7 ]
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
Before Width: | Height: | Size: 524 B After Width: | Height: | Size: 524 B |
|
After Width: | Height: | Size: 1.2 KiB |
|
After Width: | Height: | Size: 216 B |
|
After Width: | Height: | Size: 226 B |
|
After Width: | Height: | Size: 204 B |
|
After Width: | Height: | Size: 197 B |
|
After Width: | Height: | Size: 320 B |
|
After Width: | Height: | Size: 355 B |
|
After Width: | Height: | Size: 479 B |
|
After Width: | Height: | Size: 253 B |
@ -1,14 +1,14 @@
|
|||||||
[
|
[
|
||||||
{
|
{
|
||||||
"modid": "luckyW",
|
"modid": "luckyWaking",
|
||||||
"name": "Lucky Waking",
|
"name": "Lucky waking ?",
|
||||||
"description": "Ton réveil sera-t-il chanceux ?",
|
"description": "I wish you a good waking ... or not.",
|
||||||
"version": "${version}",
|
"version": "${version}",
|
||||||
"mcversion": "${mcversion}",
|
"mcversion": "${mcversion}",
|
||||||
"url": "",
|
"url": "www.samsite.olympe.in",
|
||||||
"updateUrl": "",
|
"updateUrl": "",
|
||||||
"authorList": ["Samsoule63"],
|
"authorList": ["Samsoule63"],
|
||||||
"credits": "... I don't know",
|
"credits": "Thanks for ... everybody who has download my mod !",
|
||||||
"logoFile": "",
|
"logoFile": "",
|
||||||
"screenshots": [],
|
"screenshots": [],
|
||||||
"dependencies": []
|
"dependencies": []
|
||||||
|
|||||||