Jump to content
Search In
  • More options...
Find results that contain...
Find results in...

frakier

Members
  • Posts

    61
  • Joined

  • Last visited

Everything posted by frakier

  1. Thanks, but... Yes... I was not asking about sides but does that matter or does the CreatureEntity blindly prompt a sound to play. And if that is so could I test during registration of sounds and make the decision. I have a entity class that extends a CreatureEntity, with methods getAmbientSound(), getHurtSound(), getDeathSound(), as in... @Override protected SoundEvent getAmbientSound() { return SpiderSounds.SPIDER_TALK; } I would like to be able to test the "SpiderSounds.SPIDER_TALK" to see if it is empty. as you say ... "if the sound happens to be empty"... "if the sound happens to be empty"... All I was asking is how to "Check if soundEvent is empty". if (SpiderSounds.SPIDER_TALK != null) {} does not work because SpiderSounds.SPIDER_TALK is never null, even if empty. If I can see that SpiderSounds.SPIDER_TALK is empty then I use a simple if statement and return SoundEvents.ENTITY_SPIDER_AMBIENT instead of returning the SpiderSounds.SPIDER_TALK in the overridden getAmbientSound(), getHurtSound(), getDeathSound() methods.
  2. Is there a way to check if a soundEvent is empty so I can specify a fallback sound using a minecraft existing sounds. I'm working on a mod that has spiders, so I can use the minecraft spiders sounds but if someone wants to add a resource pack just for my mob, without changing the minecraft spider sounds, i would like to leave that option open. something like... in a getAmbientSound or getHurtSound method if (SpiderSounds.SPIDER_TALK.isEmpty()) { return SoundEvents.ENTITY_SPIDER_AMBIENT; //use minecrafts spider sounds } else { return SpiderSounds.SPIDER_TALK; //use the sound provided by the resource pack } I could rip the spider sounds out of minecraft and include them in the mod with a different name but what would the legal impact be doing it that way. Or I could create the sounds from scratch but never have done that and doubt how it would come out.
  3. Well went back and tried the eclipse again and it worked, seems intellij is downloading/unpacking the needed dependencies [the snapshot stuff] into ".gradle\caches\forge_gradle" that eclipse is not doing correctly or at all. Before there was this error... ...missing required library: 'C:\Windows\System32\unresolved dependency - net.minecraftforge forge 1.14.4-28.1.87_mapped_snapshot_20190719-1.14.3'' now completes with C:\Users\{username}\.gradle\caches\forge_gradle\minecraft_user_repo\net\minecraftforge\forge\1.14.4-28.1.87_mapped_snapshot_20190719-1.14.3 Hope this helps someone else and if anyone knows where I should report this let me know.
  4. IntelliJ worked though and using the AdoptOpenJDK, got to be something on the eclipse gradle side having problems. 1. Create WORKSPACE "test.forge.mod.intellij". 2. Create the PROJECT_FOLDER "intellijtest" in the WORKSPACE folder. 3. Copy in the contents of forge-1.14.4-28.1.87-mdk.zip into the PROJECT_FOLDER. 4. Right click the PROJECT_FOLDER and in the contexzt menuslect "open folder as intellij idea community edition project". Let intellij do its thing. 5. On the bottom left hand side of the window next to "build" and "TODO" find the Terminal and click it. Execute gradlew genIntellijRuns ...{had a problem had to set classpath} still a problem intellij using internal jdk {had to point to the AdoptOpenJDK folder}... 6. "Run"->"Edit Configurations"->"Run Client"... ...set the "Use classpath of module:" to intellijtest.main .. [Apply] ...set the "JRE:"->"Browse"[using the folder icon] to your java jdk folder [for me it was "C:\Program Files\AdoptOpenJDK\jdk-8.0.232.09-hotspot"] .. [Apply] ...[OK].."Run"->"runClient" WORKED!! INTELLIJ: IntelliJ IDEA 2019.2.4 (Community Edition) Build #IC-192.7142.36, built on October 29, 2019 Runtime version: 11.0.4+10-b304.77 amd64 VM: OpenJDK 64-Bit Server VM by JetBrains s.r.o Windows 10 10.0 GC: ParNew, ConcurrentMarkSweep Memory: 725M Cores: 4 Registry: Non-Bundled Plugins: JAVA: (due to the recent changes by oracle using the recommended openJDK, tried "Eclipse OpenJ9" but it did not work with [drum-roll please] eclipse had to switch to Hotspot version) (would not be surprised if this is the whole problem) openjdk version "1.8.0_232" OpenJDK Runtime Environment (AdoptOpenJDK)(build 1.8.0_232-b09) OpenJDK 64-Bit Server VM (AdoptOpenJDK)(build 25.232-b09, mixed mode)
  5. From what I have gathered this is the process...(the process was different last time I played with any mods) Now I know I have to make changes to make a mod this is just a straight up test to see if I can narrow down what was going on and was [sort of] surprised to get the same error on the forge example mod. 1. Create WORKSPACE "test.forge.mod". 2. Create the PROJECT_FOLDER"test" in the WORKSPACE "test.forge.mod". 3. Copy in the contents of forge-1.14.4-28.1.87-mdk.zip into the "test" PROJECT_FOLDER. 4. Start eclipse and select the PROJECT_FOLDER then "import projects"->"Gradle"->"import existing gradle project" [NEXT] select the "test" PROJECT_FOLDER and [finish]. let eclipse do its thing. 5. Run the Gradle task "idle" -> "eclipse" then "fg_runs"->"genEclipseRuns". 6. Be sure and refresh select the PROJECT_FOLDER "test" and refresh [f5] (some 40 errors or so will come down to two errors). 6. When all is said and done the project has two problems... ..."Project 'test' is missing required library: 'C:\Windows\System32\unresolved dependency - net.minecraftforge forge 1.14.4-28.1.87_mapped_snapshot_20190719-1.14.3'' and ..."The project cannot be built until build path errors are resolved". I have searched all over and even tried looking around in here, actually found a similar topic but it seemed to just die and there is another topic from today that was for intellij that could be similar but did not want to hijack their post by even explaining I was getting something similar in eclipse. Any help would be appreciated. EDIT: if there are any logs tell me where to find them and I will attach them. ALSO... ECLIPSE: Eclipse IDE for Java Developers Version: 2019-06 (4.12.0) Build id: 20190614-1200 JAVA: (due to the recent changes by oracle using the recommended openJDK, tried "Eclipse OpenJ9" but it did not work with [drum-roll please] eclipse had to switch to Hotspot version) (would not be surprised if this is the whole problem) openjdk version "1.8.0_232" OpenJDK Runtime Environment (AdoptOpenJDK)(build 1.8.0_232-b09) OpenJDK 64-Bit Server VM (AdoptOpenJDK)(build 25.232-b09, mixed mode)
  6. I see that now. Makes sense. Believe it or not I have programmed in other languages switching to Java has been a bit different, when I quit getting in my own way I'll have it. I've already setup forge and source for mods from off-line, made simple changes and compiled jar files. This is mostly just a weekend hobby I'm trying to learn and I learn better by example, matching examples from real world [and current forge] to tutorials on-line is interesting to say the least. Thanks for the help.
  7. Apparently some people use it when they are not overriding anything. Or maybe I'm just misunderstanding. Like I said still learning. In this case the author had a customTorch class that extends BlockTorch [a minecraft class] which of course extends Block [a minecraft class]. @Override was used on the onBlockActivated method in customTorch and of course as you say BlockTorch does not have the onBlockActivated method but Block does. Most of what I have done has been fairly simple up to now and I have used @Override only when.. well overriding a method int a direct parent class. Figured I need to go learn more on the subject.
  8. Also I'm still learning, think I need to go learn more about @Override. Seems more subtle than the straight forward use I have been putting it to.
  9. Sorry, I had gotten into a brain loop and had started assuming based on experience from other work I'm doing that the code was there in 1.10. I had convinced myself that somewhere between 1.10 and 1.12 that the method was removed. If I had thought to look back at 1.10 source I would have realized my mistake. I even had the 1.10 source open in a window. Thanks for the jolt, knocked me out of that endless loop. I've been running around in for hours.
  10. I've run into a few methods that have been removed/missing like onBlockActivated From minecraft classes that extend the Block class such as... BlockTorch BlockBush Just for examples. I'm kind of new to this so I figured I would ask what I am missing before I drop back to the block class and reinvent the wheel. Should I wait for 1.12.2 to mature more? Thanks
×
×
  • Create New...

Important Information

By using this site, you agree to our Privacy Policy.