Jump to content
View in the app

A better way to browse. Learn more.

Forge Forums

A full-screen app on your home screen with push notifications, badges and more.

To install this app on iOS and iPadOS
  1. Tap the Share icon in Safari
  2. Scroll the menu and tap Add to Home Screen.
  3. Tap Add in the top-right corner.
To install this app on Android
  1. Tap the 3-dot menu (⋮) in the top-right corner of the browser.
  2. Tap Add to Home screen or Install app.
  3. Confirm by tapping Install.

Would like to increase the damage of the weapon. Help!!!

Featured Replies

Posted

Would like to increase the damage of the weapon.

 

I typed source...

 

mod_CloudItem.java --

 

package net.minecraft.src.CloudOnlineItem;

 

import javax.swing.text.html.parser.Entity;

 

import net.minecraft.src.forge.NetworkMod;

import net.minecraft.src.Block;

import net.minecraft.src.DamageSource;

import net.minecraft.src.Item;

import net.minecraft.src.ItemStack;

import net.minecraft.src.Material;

import net.minecraft.src.ModLoader;

import net.minecraft.src.Block;

import net.minecraft.src.Item;

import net.minecraft.src.ItemStack;

import cpw.mods.fml.common.Mod;

import cpw.mods.fml.common.Mod.Init;

import cpw.mods.fml.common.Mod.PostInit;

import cpw.mods.fml.common.Mod.PreInit;

 

public class mod_CloudItem extends NetworkMod

{

private static final ModLoader GameRegistry = null;

public Block BlockCloud;

public Item ItemCloudSword;

 

        @Override

        public String getVersion()

        {

                return "CloudItem Mod 1.0.0";

 

        }

 

        @Override

        public void load()

        {

        ItemCloudSword=new ItemCloudSword(200);

 

        BlockCloud = new BlockCloud(160);

 

        // Register Blocks

        ModLoader.registerBlock(BlockCloud);

 

       

        // Add Recipes

        ModLoader.addRecipe(new ItemStack(BlockCloud, 1), new Object[]

        {

                "OXO", "XOX", "OXO", 'X', Item.diamond,'O', Item.coal

               

        });

        ModLoader.addRecipe(new ItemStack(ItemCloudSword, 1), new Object[]

        {

            "X", "X", "X", 'X',BlockCloud

               

               

               

        });

 

        // Add Names

        ModLoader.addName(BlockCloud, "Cloud"); 

       

        ModLoader.addName(ItemCloudSword, "ItemCloudSword"); 

        }

       

}

 

 

------------------------------------------

 

BlockCloud.java----------------------

 

package net.minecraft.src.CloudOnlineItem;

 

import java.io.File;

import java.util.*;

import net.minecraft.client.Minecraft;

import net.minecraft.src.forge.*;

 

import net.minecraft.src.Block;

import net.minecraft.src.Material;

import net.minecraft.src.Block;

import net.minecraft.src.Item;

import net.minecraft.src.ItemStack;

import cpw.mods.fml.common.Mod;

import cpw.mods.fml.common.Mod.Init;

import cpw.mods.fml.common.Mod.PostInit;

import cpw.mods.fml.common.Mod.PreInit;

 

public class BlockCloud extends Block

{

 

    public BlockCloud(int blockID)

    {

                super(blockID, Material.wood);

               

                blockIndexInTexture = 0;

        setHardness(2.0f);

        setResistance(5.0f);

        setStepSound(soundWoodFootstep);

       

        setBlockName("Cloud");

    }

       

        @Override

        public int getBlockTextureFromSide(int side)

        {

                switch(side)

                {

                case 0:

                        return 0;

                case 1:

                        return 0;

                }

                return blockIndexInTexture;

        }

       

        @Override

        public String getTextureFile()

        {

            return "/ItemDot.png";

        }

}

----------------------------------------------

ItemCloudSword.java----------------------<< SetDamage??

 

package net.minecraft.src.CloudOnlineItem;

 

import net.minecraft.src.EnumToolMaterial;

import net.minecraft.src.Item;

 

public class ItemCloudSword extends Item {

 

 

public ItemCloudSword(int id) {

super(id);

    maxStackSize = 64;

    setMaxDamage(100);

   

    setIconIndex(0);

    setItemName("ItemCloudSword");

// Constructor Configuration

 

}

    @Override

    public String getTextureFile()

    {

        return "/ItemDot.png";

    }

}

 

 

 

 

 

 

 

 

 

 

Help Please..

 

 

And

 

At that can use on the server?

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Unfortunately, your content contains terms that we do not allow. Please edit your content to remove the highlighted words below.
Reply to this topic...

Important Information

By using this site, you agree to our Terms of Use.

Configure browser push notifications

Chrome (Android)
  1. Tap the lock icon next to the address bar.
  2. Tap Permissions → Notifications.
  3. Adjust your preference.
Chrome (Desktop)
  1. Click the padlock icon in the address bar.
  2. Select Site settings.
  3. Find Notifications and adjust your preference.