Compare commits

...
92 Commits
Author SHA1 Message Date
fewizz 38d769e384 1.2.6.2 2016-10-13 23:29:42 +02:00
Dream-Master be9af968b9 bump Version 2016-10-13 17:55:34 +02:00
Dream-Master 30d0534377 duct tape solution.
Tested if i jump with no Armor i died.
Featherwings 2,5 Hearts left = 25% damage reduction
Thaumium Wings 5 Hearts left = 50% damage reduction
Nano Wings 7,5 Hearts left = 75% damage reduction
Quantum Wings 10 Hearts left = 100% damage reduction
2016-10-13 17:55:15 +02:00
fewizz 9c4f0034fb Whoops 2016-10-13 16:36:08 +02:00
fewizz b97d3e1d27 Closes #30 , now no fall damage only have quantum/nano wings ( Closes #29 ) 2016-10-13 16:35:57 +02:00
Dream-Master 21ce8e85c6 update 2016-10-12 23:34:18 +02:00
Martin Robertz 501360c92b Added localizer for Energy Ball Focus 2016-10-12 23:32:13 +02:00
fewizz 022137be62 Fix serverside. Closes #28 2016-09-24 14:29:33 +03:00
fewizz 4d98a5691a Release 2016-09-23 21:24:20 +03:00
fewizz 3fcf1a13f4 Changes... 2016-09-23 19:42:25 +03:00
fewizz 5cc45ee0cb Using TC LBolt renderer(very nice). 2016-07-30 21:11:53 +03:00
fewizz a37234c719 Fix incorrect Laser rotation on client, cleanup. 2016-05-29 19:06:08 +03:00
fewizz bc0f99cd33 Solar panels and buildscript cleanup 2016-05-25 17:22:04 +03:00
fewizz 0166b8b26c Closes #25 2016-05-23 17:34:01 +03:00
fewizz 2c7c28bbc3 Now mobs can't see you, if you equipped ONE RING 2016-05-23 16:58:12 +03:00
fewizz 8ee577a958 cleanup 2016-04-10 15:04:55 +03:00
fewizz c2dee6e1c1 texture 2016-04-10 13:45:07 +03:00
fewizz 3aef354b3a cleanup 2016-04-05 13:41:09 +03:00
fewizz 0b8b56a74b now works =) 2016-04-04 19:54:02 +03:00
fewizz 58e387e761 progress... 2016-04-04 14:49:42 +03:00
fewizz 3fdaf92d12 deleted duplicated check, using callList for rendering shield, cleanup. 2016-04-03 20:23:55 +03:00
fewizz f2fb61feb0 Chainsaws now can shear ( Closes #23 ), fixed chainsaws sounds. 2016-03-24 11:47:16 +03:00
fewizz 381896031b EN localisation, new focus(WIP). 2016-03-18 18:56:45 +03:00
fewizz 6a5fc496df renames, new logo, some changes 2016-03-17 18:25:51 +03:00
fewizz 7b6ec78cd7 Cleanup and some changes... 2016-03-16 17:49:28 +03:00
fewizz a39ac3bd74 nothing... 2016-02-04 17:12:00 +03:00
fewizz ba138b6eb2 changes 2016-02-04 17:10:07 +03:00
fewizz 17dc565ece Electrical Cloud 2016-02-03 19:55:40 +03:00
fewizz 93d5267079 small cleanup 2016-02-02 19:20:27 +03:00
fewizz eacb287f6b Merge branch 'master' of https://github.com/fewizz/Electro-Magic-Tools 2016-01-09 11:47:22 +03:00
fewizz a0eb5802bd fixed chestplate, tweaked generators 2016-01-09 11:46:30 +03:00
Anton 296c45f510 Merge pull request #19 from gonglinyuan/master
updated zh_CN.lang
2016-01-05 10:33:37 +03:00
gonglinyuan 427c2ce5d1 updated zh_CN.lang 2016-01-05 15:19:16 +08:00
fewizz 797bde4868 fixes #17 2016-01-01 23:26:52 +03:00
fewizz bb33f0b7d2 1.2.5 2015-12-28 18:31:36 +03:00
fewizz bcc6623337 some changes... 2015-12-26 22:50:59 +03:00
fewizz 3dcd5c43b6 fixes 2015-12-16 14:47:38 +03:00
fewizz 8a0861589b changes 2015-12-15 20:26:18 +03:00
fewizz 170a499cab cleanup 2015-12-15 16:02:36 +03:00
fewizz 68c9653932 Merge pull request #16 from Schevv/master
Some fixes
2015-12-15 15:09:46 +03:00
Jens Bauer 7c36996fe3 Merged 2015-12-14 23:35:58 +01:00
Jens Bauer 38e1e81049 Wand Recharger now needs Wrench to remove 2015-12-14 23:30:39 +01:00
Jens Bauer c80a774da7 Missing File Update for Focus Upgrades 2015-12-14 23:30:00 +01:00
Jens Bauer 2b38ed2f2b Added Toggle to Speed of BoT 2015-12-14 23:28:49 +01:00
Jens Bauer 42340fde1c Added 3 Focus Enchants 2015-12-14 23:28:19 +01:00
Jens Bauer 9bdb607fb4 Fixed Right-Click for Industrial Wand Recharger 2015-12-14 23:27:20 +01:00
fewizz e34b5adec6 renames, fixes, additions. 2015-12-14 21:29:29 +03:00
fewizz 3f8d860b95 who faster? 2015-12-14 19:56:55 +03:00
fewizz 4cbc62afb0 optimisation 2015-12-14 19:32:25 +03:00
fewizz e5d1f1637c Shield focus rewrite. 2015-12-13 21:24:42 +03:00
fewizz a499a47d9f lightning summoner rewrite 2015-12-11 17:45:33 +03:00
fewizz bcc09e1a0e Say no to radiation! 2015-12-08 22:17:42 +03:00
fewizz 051b799fe8 changes 2015-12-07 20:21:36 +03:00
fewizz a5fe149a4c oops xD 2015-12-07 18:13:53 +03:00
fewizz 5dedb54b26 one ring rewrite 2015-12-07 17:58:48 +03:00
fewizz 0f669ce9fd ic2 api update, fix recipes. 2015-12-06 20:46:22 +03:00
fewizz b5349fccbe changes 2015-12-06 19:47:41 +03:00
fewizz 084d48e1a4 Merge pull request #14 from DSLM/patch-1
a bit fix
2015-12-02 07:37:19 +03:00
DSLM e4930a84b7 a bit fix 2015-12-01 16:59:28 -05:00
Anton 48176bc708 Update Gradle wrapper 2015-11-27 18:10:26 +03:00
fewizz 5e20f177f1 fixes 2015-11-12 20:05:55 +03:00
fewizz 25e64459bb some changes 2015-11-09 21:57:44 +03:00
fewizz 7d8c08bf72 Update 2015-10-04 21:43:02 +03:00
fewizz a402869c01 Added background, Added aspects to few IC2 blocks, Cleanup research code. 2015-10-04 21:37:48 +03:00
fewizz 2fd7805c10 Hotfix 2015-10-04 17:24:26 +03:00
fewizz e9e8ef2455 Cleanup, fixed sounds, curse. 2015-10-04 16:41:52 +03:00
fewizz 9868d18c75 Cleanup (again -_-) 2015-10-03 21:26:45 +03:00
fewizz 9e39c63627 Cleanup, libs. 2015-10-02 14:19:04 +03:00
fewizz 277677837e Cleanup, sounds for Chainsaws. 2015-10-01 21:07:47 +03:00
fewizz 04b332bd07 fixed laser, drops 2015-09-13 21:24:58 +03:00
Anton d51d4aa2c4 Use oredict here 2015-09-13 16:10:17 +03:00
Anton ece4c4dd4d Fix my mess 2015-09-13 16:03:31 +03:00
Anton 34b6134c4c Hopefully fix logo displaying 2015-09-13 15:58:26 +03:00
Anton fe5478af8b Hardcoded console logging, readme.md 2015-09-13 15:55:57 +03:00
Anton bab27d6189 Fixed possible problems with Turkish locale 2015-09-13 15:33:13 +03:00
fewizz ba22dbb69b Fixed hoe, chainsaw of the stream. Cleanup. 2015-09-09 23:32:58 +03:00
TheSilentium 3e46e3df5c 1.2.0-UnOffBeta 2015-09-05 23:03:28 +03:00
fewizz be2e78d2e0 Merge pull request #4 from InfinityStudio/master
Compared with EN_US and fix all
2015-08-01 15:50:05 +03:00
PatchouliHina eda4cb5f59 Compared with EN_US and fix all 2015-08-01 20:38:55 +08:00
PatchouliHina e737d8d212 Merge pull request #2 from fewizz/master
Update
2015-08-01 19:24:46 +08:00
fewizz 9a17e25da6 TehNut. 2015-07-25 01:14:43 +03:00
fewizz 0fd5269d7b some new textures, cleanup. 2015-07-25 01:12:33 +03:00
fewizz 96ebbf9d05 fixed hoe, solars. Added new item. 2015-07-22 21:08:23 +03:00
fewizz 5419892c90 Merge pull request #2 from InfinityStudio/master
Chinese Translation
2015-07-19 10:46:10 +03:00
PatchouliHina 48d007250b Merge pull request #1 from InfinityStudio/ChineseLangFix
修正与全文统一
2015-07-19 15:44:24 +08:00
PatchouliHina e418bbe173 修正与全文统一 2015-07-19 15:37:28 +08:00
PatchouliHina 5443c00f58 Translated using Weblate (Chinese (China))
Currently translated at 100.0% (307 of 307 strings)
2015-07-19 06:09:05 +00:00
PatchouliHina 013408588e Translated using Weblate (Chinese (China))
Currently translated at 100.0% (307 of 307 strings)
2015-07-18 01:26:59 +00:00
Epix 5a279266e1 Translated using Weblate (Chinese (China))
Currently translated at 99.0% (304 of 307 strings)
2015-07-18 01:25:55 +00:00
fewizz 96ba092c53 Ooops O_o 2015-07-11 13:49:12 +03:00
fewizz c057c4c88a Doing progress 2015-07-11 13:32:13 +03:00
fewizz 727ab4820e some changes 2015-06-30 10:36:18 +03:00
811 changed files with 11237 additions and 11664 deletions

No files matched your search

+24 -2
View File
@@ -8,7 +8,14 @@
/out/* /out/*
/asm/* /asm/*
/bin/* /bin/*
/libs/* /download/*
/.settings/*
/eclipse/*
/debug/*
/.metadata/*
/config/*
/logs/*
/saves/*
#File Extensions #File Extensions
*.psd *.psd
@@ -17,7 +24,22 @@
*.iws *.iws
*.classpath *.classpath
*.project *.project
*.lock
#Specific files #Specific files
MCFPost.txt MCFPost.txt
Thumbs.db options.txt
#Remove OS generated garbage
*/.DS_Store
.DS_Store
.DS_Store?
.Spotlight-V100
.Trashes
Icon?
ehthumbs.db
Thumbs.db
#Vim backups
*~
*.bat
-133
View File
@@ -1,133 +0,0 @@
Changelog of the mod : Electric Magic Tools, a Thaumcraft 4/Industrial-Craft 2 addon
--------------------------------------------------------------------------------------------------------------------------------------------------------
Version 2.0.0Alpha-Build 29:
Hopefully no more duplicate packages or stuff. I hope.
Version 2.0.0Alpha-Build 28:
Started updating changelog again. Oops :p
Fixed the TileEntities not getting registered.
Version 2.0.0Alpa5:
Wild Material Shards have appeared! They are used in the tools' crafting recipes :D.
And here come the carvers!
Version 2.0.0Alpha4:
Added some items to the vanilla module of the mod: Wooden, Stone, Iron, Golden and Diamond Drills.
Added Wooden, Stone, Iron, Golden and Diamond Chainsaws.
Added Iron, Golden and Diamond Omnitools.
Removed stuff from capes, it's not needed anymore.
Version 2.0.0Alpha3:
Fixed the UU-Matter infusion research page crash. But the recipes aren't viable anymore, I'll get to fixing that ASAP.
Added a few Base tools, just for later purposes.
Added an interface for using in said tools, for later purposes too
Version 2.0.0Aplha2:
Fixed the Electric/Nano/Qunatum Boots of the Traveller not preventing fall damage. They now drain energy when doing so.
Fixed the Wings not preventing fall damage. They just do it.
Fixed the Wings model being derpy (Finally, huzza!)
Version 2.0.0Alpha1:
Since SOMEONE decided to change the modid, and almost everything else, this is now EMT 2.0.0. Hurray, and all that stuff.
Fixed the Essentia Generators crashing when placed in world. Oops.
And, well, as you can see, resumed the work on EMT. Sorry for the delay! :p
Version 1.1.4 :
Updated to Minecraft version 1.7.10.
Rewrote and improved the Essentia Generator code. It's now very easy to add new ones.
Rewrote and improved the Solar Panel code. It's now very easy to add new ones.
Rewrote and improved the Drill, Chainsaw, Omnitool, Boot, Goggle and Wing code. It's now very easy to add new ones, as well as way more efficient.
Refactored a lot of the code in preparation for the modules.
Added a new Essentia Generator, the Aer Generator.
Added a tooltip to the current Essentia Generators, saying they will be removed in future versions.
Added an Essentia Generator, alongisde with a dynamic system calculating outputs linked to different essentias. Change the values of the primals in the config, and there is even a maximum cap!
Added localization text for almost everything. (TehNut)
Added config GUI for in game config changes. (Implemented by Tombenpotter, fixed by TehNut)
Fixed Charged Creepers and Tainted Chickens not dropping things. (TehNut)
Organized creative tab to make it look nicer (TehNut)
Compressed Solar Panel tooltips are now easier to read. (TehNut)
Version 1.1.3 :
Added a logo to the mcmod.info, and fixed the version tag.
Version 1.1.2 :
Fixed the Shield Block being broken by the wither.
Added Config GUIs. Regenerating the config file is HIGLY reccomended.
Moved the baubles API to package it with EMT, along with the @API annotation to prevent any issues.
Version 1.1.1 :
Fixed a bug with The One Ring where mobs attacked you when you removed it while in creative.
New Thaumonomicon entries for a couple of things, thanks to Professor29.
Forgot to mention it, new Nanosuit Boots of the Traveller texture thanks to TehNut.
Removed Thaumium Plate and Lightning Summoner, and moved them to use other ids. This will delete existing ones.
Moved all the Solar Panels tooltips to require the use of the shift key to show themselves.
Adding wings, my take at the mix of Magic and Jetpacks.
Blacklist of the Etheral Processor now extends to anything containing armor, armour, helm, chestp, legging, boot, sword, shovel, axe or pick in its unlocalized name.
Added a drop to the Tainted Chicken, the Tainted Feather. Also added a crafting recipe for it.
Added a couple of crating components, used in the making of the wings.
Added a bunch of console outputs on the starting of the game so that I know exactly when it crashed if it died at startup.
Fixed a bug with the drill of the Rockbreaker that would make it use durability and eventually break when shift-breaking a block.
Added a different texture file for each solar panel, so that it can be changed more easily.
CyanideX remade all the EMT textures! Finally featuring cool looking stuff! Yey, thanks a lot to him!
Version 1.1.0 :
Updating to MC 1.7.2.
Added an Inventory Charging Bauble and an Armor Charging Bauble.
Added The One Ring, available only through dungeon loot.
Added a Wand Charging wand focus.
Versions 1.0.9a, 1.0.9b, 1.0.9c, 1.0.9d :
Added a blacklist for the Ethereal Processor to anything that has "dust" in its OreDict entry.
Mainly bugfixes.
Version 1.0.9 :
Fixed the bug with the Drill of the Rockbreaker.
Added UU-Matter Infusion Recipes.
Fixed the recipe for the Quantum Solar Helmet of Revealing.
Added the Wand Focus: Charging.
Added a cool particle effect existing when the Electric/Nano/Quantum boots of the traveller are worn (you an disable it in the config).
Added a portable node, and an Elecric Hoe of Growth.
Version 1.0.8 :
Added some magical solar panels, different tiers and special abilities to all of them.
Version 1.0.7 :
Updated to Thaumcraft 4.1.0x.
Version 1.0.6 :
Added an Industrial Wand Charging Station.
Added some legendary tools.
A couple of other things.
Code wise, switching to Forge Gradle (#964).
Added some enhanced boots of the traveller, and capes for some friends and I.
Version 1.0.5 :
Added some Ignis/Potentia/Auram generators.
Added Electric Goggles of revealing.
Added a Chainsaw of the Stream.
Added a Drill of the Rockbreaker.
Version 1.0.4 :
Added the Kris-tmas Focus.
Added the Shield Focus
Version 1.0.3b :
Second attempt to fix the server crash, it is again working in SMP.
Version 1.0.3 :
Attempt to fix the server crash of the mod. Attempt failed.
Version 1.0.2 :
Adds the Wand Focus : Laser.
Added a christmas easter egg.
Does not work on servers.
Version 1.0.1 :
Fixes a crash due to the Omnitools.
Version 1.0.0 :
First release of the mod.
--------------------------------------------------------------------------------------------------------------------------------------------------------
+22
View File
@@ -0,0 +1,22 @@
![](/src/main/resources/logo.png?raw=true)
#Electro-Magic Tools
Electro-Magic Tools is a Minecraft mod which integrates Thaumcraft 4 with IndustrialCraft 2 by adding cross-mod tools and items, such as magic solar panels, essentia generators and legendary items.
#Downloads
[CurseForge downloads](http://minecraft.curseforge.com/projects/electro-magic-tools)
[Github Releases](https://github.com/fewizz/Electro-Magic-Tools/releases)
#Issues
Before posting to the issue tracker, make sure you meet the following criteria:
- You're using the latest version of EMT.
- You've made sure the version of Forge you're using is the one EMT has been compiled for. (Newer is usually OK, but be careful!)
- You've gone through the effort to isolate EMT from other mods that aren't related to the issue.
- You've gone through the effort to find what conditions are necessary to reproduce the issue.
- The issue is subtle enough and has been around long enough that you think we might have missed it.
- You speak English or Russian well enough to explain yourself without wondering whether you will be understood.
+6 -58
View File
@@ -2,16 +2,13 @@ buildscript {
repositories { repositories {
mavenCentral() mavenCentral()
maven { url = "http://files.minecraftforge.net/maven" } maven { url = "http://files.minecraftforge.net/maven" }
maven { url = "https://oss.sonatype.org/content/repositories/snapshots/" }
} }
dependencies { dependencies {
classpath 'net.minecraftforge.gradle:ForgeGradle:1.2-SNAPSHOT' classpath 'net.minecraftforge.gradle:ForgeGradle:1.2-SNAPSHOT'
classpath 'org.ajoberstar:gradle-git:0.10.1'
} }
} }
apply plugin: 'forge' apply plugin: 'forge'
apply plugin: 'maven-publish'
ext.configFile = file "build.properties" ext.configFile = file "build.properties"
configFile.withReader { configFile.withReader {
@@ -20,23 +17,10 @@ configFile.withReader {
project.ext.config = new ConfigSlurper().parse prop project.ext.config = new ConfigSlurper().parse prop
} }
def build_number = 'CUSTOM' version = config.mod_version + "[" + config.mc_version + "]"
if (System.getenv('BUILD_NUMBER') != null)
build_number = System.getenv('BUILD_NUMBER')
version = config.mc_version + "-" + config.mod_version + "-${build_number}"
group= config.package_group group= config.package_group
archivesBaseName = config.mod_name archivesBaseName = config.mod_name
import org.ajoberstar.grgit.Grgit
def gitHash = 'unknown'
if (new File(projectDir, '.git').exists()) {
def repo = Grgit.open(project.file('.'))
gitHash = repo.log().find().abbreviatedId
}
minecraft { minecraft {
version = config.mc_version + "-" + config.forge_version + "-" + config.mc_version version = config.mc_version + "-" + config.forge_version + "-" + config.mc_version
runDir = "run" runDir = "run"
@@ -51,25 +35,14 @@ processResources {
from(sourceSets.main.resources.srcDirs) { from(sourceSets.main.resources.srcDirs) {
include '**/*.info' include '**/*.info'
include '**/*.properties' expand 'version': config.mod_version
expand 'version': project.version, 'mcversion': project.minecraft.version
}
from(sourceSets.main.resources.srcDirs) {
exclude '**/*.info'
exclude '**/*.properties'
exclude '**/*.db'
} }
} }
jar { jar {
manifest.mainAttributes( exclude "baubles/**"
"Built-By": System.getProperty('user.name'), exclude "ic2/**"
"Created-By": "${System.getProperty('java.vm.version')} + (${System.getProperty('java.vm.vendor')})", exclude "thaumcraft/**"
"Implementation-Title": project.name,
"Implementation-Version": project.version,
"Git-Hash": gitHash
)
} }
// add a source jar // add a source jar
@@ -78,39 +51,14 @@ task sourceJar(type: Jar) {
classifier = 'sources' classifier = 'sources'
} }
// add a javadoc jar
task javadocJar(type: Jar) {
from javadoc.destinationDir
classifier = 'javadoc'
}
// because the normal output has been made to be obfuscated // because the normal output has been made to be obfuscated
task deobfJar(type: Jar) { task deobfJar(type: Jar) {
from sourceSets.main.output from sourceSets.main.output
classifier = 'deobf' classifier = 'deobf'
} }
tasks.build.dependsOn sourceJar, javadocJar, deobfJar tasks.build.dependsOn sourceJar, deobfJar
tasks.withType(JavaCompile) { task -> tasks.withType(JavaCompile) { task ->
task.options.encoding = 'UTF-8' task.options.encoding = 'UTF-8'
}
publishing {
tasks.publish.dependsOn 'build'
publications {
mavenJava(MavenPublication) {
from components.java
artifact sourceJar
//artifact javadocJar
artifact deobfJar
}
}
repositories {
if (project.hasProperty('maven_repo')) {
maven { url maven_repo }
} else {
mavenLocal()
}
}
} }
+3 -5
View File
@@ -1,7 +1,5 @@
# package_group=emt
#Wed Feb 24 14:31:53 PDT 2015
package_group=com.tombenpotter.emt
mc_version=1.7.10 mc_version=1.7.10
forge_version=10.13.2.1307 forge_version=10.13.4.1614
mod_version=2.0.0Alpha2 mod_version=1.2.6.2
mod_name=ElectroMagicTools mod_name=ElectroMagicTools
+2
View File
@@ -0,0 +1,2 @@
org.gradle.debug=false
org.gradle.daemon=false
Binary file not shown.
+2 -2
View File
@@ -1,6 +1,6 @@
#Fri Sep 26 11:20:52 CDT 2014 #Fri Nov 27 18:08:08 MSK 2015
distributionBase=GRADLE_USER_HOME distributionBase=GRADLE_USER_HOME
distributionPath=wrapper/dists distributionPath=wrapper/dists
zipStoreBase=GRADLE_USER_HOME zipStoreBase=GRADLE_USER_HOME
zipStorePath=wrapper/dists zipStorePath=wrapper/dists
distributionUrl=https\://services.gradle.org/distributions/gradle-2.1-bin.zip distributionUrl=https\://services.gradle.org/distributions/gradle-2.13-bin.zip
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
-1
View File
@@ -1 +0,0 @@
rootProject.name = 'ElectroMagicTools'
@@ -13,7 +13,7 @@ public interface IBauble {
/** /**
* This method return the type of bauble this is. * This method return the type of bauble this is.
* Type is used to determine the slots it can go into. * Type is used to determine the slots it can go into.
*/ */
public BaubleType getBaubleType(ItemStack itemstack); public BaubleType getBaubleType(ItemStack itemstack);
Binary file not shown.
@@ -1,5 +1,8 @@
package ic2.api; package ic2.api;
import java.util.EnumSet;
import java.util.Set;
import net.minecraft.tileentity.TileEntity; import net.minecraft.tileentity.TileEntity;
import net.minecraft.world.World; import net.minecraft.world.World;
@@ -36,6 +39,15 @@ public enum Direction {
*/ */
ZP; ZP;
private Direction() {
int side = ordinal() / 2;
int sign = getSign();
xOffset = side == 0 ? sign : 0;
yOffset = side == 1 ? sign : 0;
zOffset = side == 2 ? sign : 0;
}
public static Direction fromSideValue(int side) { public static Direction fromSideValue(int side) {
return directions[(side + 2) % 6]; return directions[(side + 2) % 6];
} }
@@ -83,7 +95,7 @@ public enum Direction {
/** /**
* Get the inverse of this direction (XN -> XP, XP -> XN, etc.) * Get the inverse of this direction (XN -> XP, XP -> XN, etc.)
* *
* @return Inverse direction * @return Inverse direction
*/ */
public Direction getInverse() { public Direction getInverse() {
@@ -92,7 +104,7 @@ public enum Direction {
/** /**
* Convert this direction to a Minecraft side value. * Convert this direction to a Minecraft side value.
* *
* @return Minecraft side value * @return Minecraft side value
*/ */
public int toSideValue() { public int toSideValue() {
@@ -112,6 +124,12 @@ public enum Direction {
return ForgeDirection.getOrientation(toSideValue()); return ForgeDirection.getOrientation(toSideValue());
} }
public final int xOffset;
public final int yOffset;
public final int zOffset;
public static final Direction[] directions = Direction.values(); public static final Direction[] directions = Direction.values();
public static final Set<Direction> noDirections = EnumSet.noneOf(Direction.class);
public static final Set<Direction> allDirections = EnumSet.allOf(Direction.class);
} }
Binary file not shown.
@@ -37,13 +37,16 @@ public abstract class CropCard {
/** /**
* Determine the mod id owning this crop. * Determine the mod id owning this crop.
* *
* It's recommended to hard code this to your mod id. * The owner serves as a name space. With every mod using a different owner, a mod only has to
* make sure it doesn't have conflicts with name() in itself.
* It's recommended to hard code this to your mod id as specified in the @Mod annotation.
* Do not use IC2's mod id here.
* *
* @note changing name or owner will cause existing crops in users' worlds to disappear. * @note changing name or owner will cause existing crops in users' worlds to disappear.
* *
* @return Mod id. * @return Mod id.
*/ */
public String owner() { public String owner() { // TODO: make abstract
return modId; return modId;
} }
@@ -100,7 +103,7 @@ public abstract class CropCard {
* @param crop reference to ICropTile * @param crop reference to ICropTile
* @return roots lengt use in isBlockBelow * @return roots lengt use in isBlockBelow
*/ */
public int getrootslength(ICropTile crop) { public int getrootslength(ICropTile crop) { // TODO: camel case
return 1; return 1;
} }
@@ -126,7 +129,7 @@ public abstract class CropCard {
* @param n index of the requested stat * @param n index of the requested stat
* @return The requested value of the stats * @return The requested value of the stats
*/ */
public abstract int stat(int n); public abstract int stat(int n); // TODO: change to fixed property object or builder with other attributes like tier
/** /**
* Additional attributes of the plant, also influencing breeding. * Additional attributes of the plant, also influencing breeding.
@@ -134,7 +137,7 @@ public abstract class CropCard {
* *
* @return Attributes as an array of strings * @return Attributes as an array of strings
*/ */
public abstract String[] attributes(); public abstract String[] attributes(); // TODO: default to none
/** /**
* Determine the max crop size. * Determine the max crop size.
@@ -212,7 +215,7 @@ public abstract class CropCard {
* @return 0-30 * @return 0-30
*/ */
public int weightInfluences(ICropTile crop, float humidity, float nutrients, float air) { public int weightInfluences(ICropTile crop, float humidity, float nutrients, float air) {
return (int) (humidity+nutrients+air); return (int) (humidity + nutrients + air);
} }
/** /**
@@ -247,7 +250,7 @@ public abstract class CropCard {
* @return need crop size for best output. * @return need crop size for best output.
*/ */
public abstract int getOptimalHavestSize(ICropTile crop); public abstract int getOptimalHavestSize(ICropTile crop); // TODO: default to maxSize
/** /**
* Check whether the crop can be harvested. * Check whether the crop can be harvested.
@@ -255,7 +258,7 @@ public abstract class CropCard {
* @param crop reference to ICropTile * @param crop reference to ICropTile
* @return Whether the crop can be harvested in its current state. * @return Whether the crop can be harvested in its current state.
*/ */
public abstract boolean canBeHarvested(ICropTile crop); public abstract boolean canBeHarvested(ICropTile crop); // TODO: default to maxSize check
/** /**
* Base chance for dropping the plant's gains, specify values greater than 1 for multiple drops. * Base chance for dropping the plant's gains, specify values greater than 1 for multiple drops.
@@ -263,10 +266,8 @@ public abstract class CropCard {
* *
* @return Chance to drop the gains * @return Chance to drop the gains
*/ */
public float dropGainChance() { public float dropGainChance() { // TODO: change to double
float base = 1F; return (float) Math.pow(0.95, tier());
for (int i = 0; i < tier(); i++) {base*=0.95;}
return base;
} }
/** /**
@@ -284,20 +285,20 @@ public abstract class CropCard {
* @param crop reference to ICropTile * @param crop reference to ICropTile
* @return Plant size after harvesting * @return Plant size after harvesting
*/ */
public byte getSizeAfterHarvest(ICropTile crop) {return 1;} public byte getSizeAfterHarvest(ICropTile crop) {return 1;} // TODO: change to int
/** /**
* Called when the plant is leftclicked by a player. * Called when the plant is left clicked by a player.
* Default action is picking the plant. * Default action is picking the plant.
* *
* Only called Serverside. * Only called server side.
* *
* @param crop reference to ICropTile * @param crop reference to ICropTile
* @param player player leftclicked the crop * @param player player left clicked the crop
* @return Whether the plant has changed * @return Whether the plant has changed
*/ */
public boolean leftclick(ICropTile crop, EntityPlayer player) { public boolean leftclick(ICropTile crop, EntityPlayer player) { // TODO: camel case
return crop.pick(true); return crop.pick(true);
} }
@@ -398,7 +399,7 @@ public abstract class CropCard {
*/ */
public boolean isWeed(ICropTile crop) { public boolean isWeed(ICropTile crop) {
return crop.getSize() >= 2 && return crop.getSize() >= 2 &&
(crop == Crops.weed || crop.getGrowth() >= 24); (crop.getCrop() == Crops.weed || crop.getGrowth() >= 24);
} }
@@ -430,4 +431,5 @@ public abstract class CropCard {
protected IIcon textures[]; protected IIcon textures[];
private final String modId; // TODO: make owner abstract, remove modId auto detection private final String modId; // TODO: make owner abstract, remove modId auto detection
// TODO: add a clean way to obtain world reference and position
} }
File renamed without changes.
@@ -260,6 +260,15 @@ public interface ICropTile {
*/ */
public boolean isBlockBelow(Block block); public boolean isBlockBelow(Block block);
/**
* Check if a block is under the farmland containing the crop.
* Searches up to 2 blocks below the farmland or an air space, whichever appears first.
*
* @param oreDictionaryName blocks to search
* @return Whether the blocks were found
*/
public boolean isBlockBelow(String oreDictionaryName);
/** /**
* Generate plant seeds with the given parameters. * Generate plant seeds with the given parameters.
* *
File renamed without changes.
Binary file not shown.
@@ -1,5 +1,6 @@
package ic2.api.info; package ic2.api.info;
import net.minecraft.potion.Potion;
import net.minecraft.util.DamageSource; import net.minecraft.util.DamageSource;
import cpw.mods.fml.common.Loader; import cpw.mods.fml.common.Loader;
@@ -16,6 +17,12 @@ public class Info {
*/ */
public static DamageSource DMG_ELECTRIC, DMG_NUKE_EXPLOSION, DMG_RADIATION; public static DamageSource DMG_ELECTRIC, DMG_NUKE_EXPLOSION, DMG_RADIATION;
/**
* Potions used by IC2.
* Getting assigned in preload.
*/
public static Potion POTION_RADIATION;
public static boolean isIc2Available() { public static boolean isIc2Available() {
if (ic2Available != null) return ic2Available; if (ic2Available != null) return ic2Available;
Loaded 100 of 811 files, more files were not shown because too many files have changed in this diff. Show more