Jump to content

WildTan

Members
  • Posts

    48
  • Joined

  • Last visited

Everything posted by WildTan

  1. When i try to install 1.17.1 mdk i get an error: Could not resolve all files for configuration ':runtimeClasspathCopy'. Could not find net.minecraftforge:forge:1.17.1-37.0.50_mapped_official_1.17.1. Searched in the following locations: - file:/C:/Users/ACER/.gradle/caches/forge_gradle/bundeled_repo/net/minecraftforge/forge/1.17.1-37.0.50_mapped_official_1.17.1/forge-1.17.1-37.0.50_mapped_official_1.17.1.pom - file:/C:/Users/ACER/.gradle/caches/forge_gradle/bundeled_repo/net/minecraftforge/forge/1.17.1-37.0.50_mapped_official_1.17.1/forge-1.17.1-37.0.50_mapped_official_1.17.1.jar Required by: project : Possible solution: - Declare repository providing the artifact, see the documentation at https://docs.gradle.org/current/userguide/declaring_repositories.html How i can fix it?
  2. The new project, deleting user/.gradle/ and full reinstalation of all of java, intellij, have fixed it.
  3. The jdk is all right - all other projects works currectly. I changed jdk a lot of times - nothing new.
  4. 12:26:47: Executing task 'runClient'... FAILURE: Build failed with an exception. * Where: Build file 'C:\Cookie\CookiePrivates\build.gradle' line: 18 * What went wrong: A problem occurred evaluating root project 'ru.privates'. > Failed to apply plugin 'net.minecraftforge.gradle'. > Failed to validate certificate for https://maven.minecraftforge.net/, Most likely cause is an outdated JDK. Try updating at https://adoptopenjdk.net/ To disable this check re-run with -Dnet.minecraftforge.gradle.test_certs=false * Try: Run with --stacktrace option to get the stack trace. Run with --info or --debug option to get more log output. Run with --scan to get full insights. * Get more help at https://help.gradle.org BUILD FAILED in 510ms 12:26:48: Task execution finished 'runClient'. buildscript { ext.kotlin_version = '1.5.20' repositories { maven { url = 'https://maven.minecraftforge.net' } maven { url = 'https://repo.spongepowered.org/repository/maven-public/' } mavenCentral() } dependencies { classpath group: 'net.minecraftforge.gradle', name: 'ForgeGradle', version: '4.1+', changing: true //classpath 'org.spongepowered:mixingradle:0.7-SNAPSHOT' classpath "org.jetbrains.kotlin:kotlin-gradle-plugin:$kotlin_version" } } apply plugin: 'net.minecraftforge.gradle' apply plugin: 'kotlin' //apply plugin: 'org.spongepowered.mixin' group = 'ru' version = '0.0.0.1' archivesBaseName = 'cookieteam' java.toolchain.languageVersion = JavaLanguageVersion.of(8) minecraft { mappings channel: 'snapshot', version: '20210309-1.16.5' runs { client { workingDirectory project.file('run') property 'forge.logging.markers', 'REGISTRIES' property 'forge.logging.console.level', 'debug' // arg "-mixin.config=ru.privates.mixins.json" mods { privates { source sourceSets.main } } } server { workingDirectory project.file('run') property 'forge.logging.markers', 'REGISTRIES' property 'forge.logging.console.level', 'debug' //arg "-mixin.config=ru.privates.mixins.json" mods { privates { source sourceSets.main } } } data { workingDirectory project.file('run') property 'forge.logging.markers', 'REGISTRIES' property 'forge.logging.console.level', 'debug' args '--mod', 'ru.privates', '--all', '--output', file('src/generated/resources/'), '--existing', file('src/main/resources/') mods { privates { source sourceSets.main } } } } } //mixin { add sourceSets.main, "ru.privates.refmap.json" } sourceSets.main.resources { srcDir 'src/generated/resources' } repositories { maven { name = 'Kotlin for Forge' url = 'https://thedarkcolour.github.io/KotlinForForge/' } } dependencies { minecraft 'net.minecraftforge:forge:1.16.5-36.1.31' //annotationProcessor 'org.spongepowered:mixin:0.8:processor' implementation "org.jetbrains.kotlin:kotlin-stdlib-jdk8:$kotlin_version" fg.deobf(implementation('thedarkcolour:kotlinforforge:1.13.0')) } jar { manifest { attributes( [ "Specification-Title" : "ru.privates", "Specification-Vendor" : "GoogleTan", "Specification-Version" : "1", "Implementation-Title" : project.name, "Implementation-Version" : project.version, "Implementation-Vendor" : "GoogleTan", //"MixinConfigs" : "ru.privates.mixins.json", "Implementation-Timestamp": new Date().format("yyyy-MM-dd'T'HH:mm:ssZ") ]) } } jar.finalizedBy('reobfJar') repositories { mavenCentral() } compileKotlin { kotlinOptions {jvmTarget = "1.8"} } compileTestKotlin { kotlinOptions { jvmTarget = "1.8"} } distributionBase=GRADLE_USER_HOME distributionPath=wrapper/dists distributionUrl=https\://services.gradle.org/distributions/gradle-6.9-bin.zip zipStoreBase=GRADLE_USER_HOME zipStorePath=wrapper/dists Why it does not work and how i can fix it?
  5. { "ambientocclusion": false, "textures": { "all": "block/water_still" }, "elements": [ { "name": "water", "from": [2, 1, 2], "to": [14, 12, 15], "rotation": {"angle": 0, "axis": "y", "origin": [10, 9, 10]}, "color": 4, "faces": { "north": {"uv": [0, 0, 16, 16], "texture": "#all", "cullface": "north"}, "east": {"uv": [0, 0, 16, 16], "texture": "#all", "cullface": "up"}, "south": {"uv": [0, 0, 16, 16], "texture": "#all", "cullface": "south"}, "west": {"uv": [0, 0, 16, 16], "texture": "#all", "cullface": "west"}, "up": {"uv": [0, 0, 16, 16], "texture": "#all", "cullface": "up"}, "down": {"uv": [0, 0, 16, 16], "texture": "#all", "cullface": "down"} } } ] } smth like it
  6. I have custom mappings. I have a repository with them. I tryed to attach them: ... minecraft { mappings channel: 'custom', version: 'com.github.GoogeTan:TheMappings:Tag' accessTransformer = file('src/main/resources/META-INF/accesstransformer.cfg') runs { client { workingDirectory project.file('run') property 'forge.logging.markers', 'SCAN,REGISTRIES,REGISTRYDUMP' property 'forge.logging.console.level', 'debug' ... But it shouts: A problem occurred configuring root project 'PhoenixProject'. > Supplied String module notation 'net.minecraftforge:forge:1.15.2-31.2.47_mapped_custom_com.github.GoogeTan:TheMappings:Tag_at_904f7754f2116b78834cf8ff88239b5b038624fc' is invalid. Example notations: 'org.gradle:gradle-core:2.2', 'org.mockito:mockito-core:1.9.5:javadoc'. What i sould do?
  7. PR has already been there for a long time, why hasn't it been accepted yet?
  8. If i want to use Kotlin for modding i need to use language adapter but there are around 7 adapters and they are not work or i work terrible. How about integrating the Kotlin standard library into Forge? No effort is required from you, I will do it myself. You only need to take PR.
  9. If i remove all json files, I can not see pink-black cube... Minecraft combines TESR and json models. How i can do it?
  10. Yes, but i changed path in gradle. I must not do it?
  11. I did all of it. I only changed file name. You can see it in files above
  12. I have AT: public net.minecraft.world.dimension.DimensionType * public net.minecraft.world.dimension.DimensionType *() public-f net.minecraft.world.dimension.DimensionType * public net.minecraft.world.gen.surfacebuilders.SurfaceBuilder *() public net.minecraft.client.renderer.RenderType * public net.minecraft.client.renderer.RenderType *() public net.minecraft.world.biome.Biome * public net.minecraft.world.biome.Biome *() public net.minecraft.world.server.ServerChunkProvider * public-f net.minecraft.world.server.ServerChunkProvider * public net.minecraft.item.crafting.RecipeManager *() public net.minecraft.client.renderer.RenderState * My gradle: buildscript { ext.kotlin_version = '1.4.20-M1' repositories { maven { url = 'https://files.minecraftforge.net/maven' } jcenter() mavenCentral() maven { url 'https://dl.bintray.com/kotlin/kotlin-eap' } } dependencies { classpath group: 'net.minecraftforge.gradle', name: 'ForgeGradle', version: '3.+', changing: true classpath "org.jetbrains.kotlin:kotlin-gradle-plugin:$kotlin_version" } } apply plugin: 'net.minecraftforge.gradle' apply plugin: 'kotlin' version = modVersion group = modGroup archivesBaseName = modBaseName compileJava.options.encoding = "UTF-8" compileTestJava.options.encoding = "UTF-8" sourceCompatibility = targetCompatibility = compileJava.sourceCompatibility = compileJava.targetCompatibility = '1.8' minecraft { mappings channel: 'snapshot', version: '20201118-1.15.1' accessTransformer = file('src/main/resources/META-INF/phoenix_at.cfg') runs { client { workingDirectory project.file('run') property 'forge.logging.markers', 'SCAN,REGISTRIES,REGISTRYDUMP' property 'forge.logging.console.level', 'debug' mods { phoenix { source sourceSets.main } } } server { workingDirectory project.file('run') // Recommended logging data for a userdev environment property 'forge.logging.markers', 'SCAN,REGISTRIES,REGISTRYDUMP' // Recommended logging level for the console property 'forge.logging.console.level', 'debug' mods { phoenix { source sourceSets.main } } } data { workingDirectory project.file('run') // Recommended logging data for a userdev environment property 'forge.logging.markers', 'SCAN,REGISTRIES,REGISTRYDUMP' // Recommended logging level for the console property 'forge.logging.console.level', 'debug' args '--mod', 'phoenix', '--all', '--output', file('src/generated/resources/') mods { phoenix { source sourceSets.main } } } } } repositories { mavenCentral() maven { // Мавен, который поддерживает JEI. name = "Progwml6 maven" url = "http://dvs1.progwml6.com/files/maven" } maven { // Мавен, который поддерживает JEI, для резерва. name = "ModMaven" url = "modmaven.k-4u.nl" } maven { url 'https://dl.bintray.com/kotlin/kotlin-eap' } mavenCentral() jcenter() } dependencies { minecraft 'net.minecraftforge:forge:1.15.2-31.2.46' implementation "org.jetbrains.kotlin:kotlin-stdlib-jdk8:$kotlin_version" compileOnly fg.deobf("mezz.jei:jei-${minecraft_version}:${jei_version}:api") runtimeOnly fg.deobf("mezz.jei:jei-${minecraft_version}:${jei_version}") } compileKotlin { kotlinOptions { jvmTarget = "1.8" } } compileTestKotlin { kotlinOptions { jvmTarget = "1.8" } } jar { manifest { attributes 'FMLAT': 'phoenix_at.cfg' attributes([ "Specification-Title": "phoenix", "Specification-Vendor": "phoenix", "Specification-Version": "1", "Implementation-Title": project.name, "Implementation-Version": "${version}", "Implementation-Vendor" : "wildtan", "Implementation-Timestamp": new Date().format("yyyy-MM-dd'T'HH:mm:ssZ") ]) } } AT works it testing client but not in real client.
  13. I have entity: class KnifeEntity : ThrowableEntity { var knife = ItemStack(PhoenixItems.ZIRCONIUM_KNIFE.get()) var isReal = false; constructor(type: EntityType<KnifeEntity>, worldIn: World) : super(type, worldIn) constructor(worldIn: World, owner: LivingEntity, isReal: Boolean) : super(PhoenixEntities.KNIFE.get(), owner, worldIn) { this.isReal = isReal; } @OnlyIn(Dist.CLIENT) override fun handleStatusUpdate(id: Byte) { if (id.toInt() == 3) { for (i in 0..7) { //Появляются частицы лавы. В обычном майнкрафте они образуются на потолке, если сверху лава. world.addParticle(ParticleTypes.RAIN, posX, posY, posZ, 0.0, 0.0, 0.0) } } } override fun onImpact(result: RayTraceResult) { if (!world.isRemote) { var dropItem = isReal dropItem = when (result.type) { ENTITY -> dropItem and (knife.item as KnifeItem).onHitEntity(world, owner, this, (result as EntityRayTraceResult).entity, knife) BLOCK -> dropItem and (knife.item as KnifeItem).onHitBlock(world, owner, (result as BlockRayTraceResult).pos, this, knife) MISS -> dropItem } if (dropItem) world.addEntity(ItemEntity(world, posX, posY, posZ, knife)) onKillCommand() } } override fun registerData() { } } And renderer: public class KnifeRenderer<T extends KnifeEntity> extends EntityRenderer<T> { private final ItemRenderer itemRenderer; private final float scale = 1; public KnifeRenderer(EntityRendererManager renderManagerIn) { super(renderManagerIn); itemRenderer = Minecraft.getInstance().getItemRenderer(); } protected int getBlockLight(T entityIn, float partialTicks) { return super.getBlockLight(entityIn, partialTicks); } @Override public void render(T entityIn, float entityYaw, float partialTicks, MatrixStack matrixStackIn, IRenderTypeBuffer bufferIn, int packedLightIn) { Phoenix.getLOGGER().error("no..."); matrixStackIn.push(); matrixStackIn.scale(this.scale, this.scale, this.scale); matrixStackIn.rotate(this.renderManager.getCameraOrientation()); matrixStackIn.rotate(Vector3f.YP.rotationDegrees(180.0F)); this.itemRenderer.renderItem(new ItemStack(PhoenixItems.INSTANCE.getZIRCONIUM_KNIFE().get()), ItemCameraTransforms.TransformType.GROUND, packedLightIn, OverlayTexture.NO_OVERLAY, matrixStackIn, bufferIn); matrixStackIn.pop(); super.render(entityIn, entityYaw, partialTicks, matrixStackIn, bufferIn, packedLightIn); } public ResourceLocation getEntityTexture(T entity) { return AtlasTexture.LOCATION_BLOCKS_TEXTURE; } } Register: public static void onClientSetup(FMLClientSetupEvent event) { ... RenderingRegistry.registerEntityRenderingHandler(PhoenixEntities.getKNIFE().get(), KnifeRenderer::new); ... } Item: class KnifeItem(tier: IItemTier, attackDamageIn: Float, attackSpeedIn: Float, maxUsages: Int) : ToolItem(attackDamageIn, attackSpeedIn, tier, breakableBlocks, Properties().group(Phoenix.PHOENIX).maxDamage(maxUsages)) { val damage: Float = attackDamageIn + tier.attackDamage override fun onItemRightClick(world : World, player : PlayerEntity, hand : Hand): ActionResult<ItemStack> { val itemstack = player.getHeldItem(hand) world.playSound(null, player.posX, player.posY, player.posZ, SoundEvents.ENTITY_SNOWBALL_THROW, SoundCategory.NEUTRAL, 0.5f, 0.4f / (random.nextFloat() * 0.4f + 0.8f)) var coolDown = 10 val speed = EnchantmentHelper.getEnchantmentLevel(Enchantments.POWER, itemstack) coolDown = (coolDown * speed.toDouble() / 3).toInt() player.cooldownTracker.setCooldown(this, coolDown) if (!world.isRemote) { val knife = KnifeEntity(world, player, true) knife.shoot(player, player.rotationPitch, player.rotationYaw, 0.0f, 1.5f, 1.0f) world.addEntity(knife) val count = EnchantmentHelper.getEnchantmentLevel(Enchantments.MULTISHOT, itemstack) + 1 for (i in 0..count - 1) { addTask(5) { val knife2 = KnifeEntity(world, player, false) knife2.shoot(player, player.rotationPitch, player.rotationYaw, 0.0f, 1.5f, 1.0f) world.addEntity(knife2) } } } itemstack.count = 0 return ActionResult(ActionResultType.SUCCESS, itemstack) } fun onHitBlock(world: World, owner: LivingEntity, pos: BlockPos, knife: KnifeEntity, item: ItemStack): Boolean { var shouldBroke = false val block = world.getBlockState(pos).block for (tag in breakableBlocksTypes) if (block.isIn(tag)) { shouldBroke = true break } if (breakableBlocks.contains(world.getBlockState(pos).block) || shouldBroke) { WorldUtils.destroyBlock(world, pos, true, owner, item) } item.damageItem(1, owner, { p: LivingEntity? -> world.playSound(null, owner.position, SoundEvents.ENTITY_SNOWBALL_THROW, SoundCategory.NEUTRAL, 0.5f, 0.4f / (random.nextFloat() * 0.4f + 0.8f)) }) return !(block !== Blocks.SNOW_BLOCK && block !== Blocks.SNOW && block.isIn(Tags.Blocks.SAND)) } fun onHitEntity(world: World?, owner: LivingEntity, knife: KnifeEntity, hitted: Entity, knifeItem: ItemStack): Boolean { val powerLevel = EnchantmentHelper.getEnchantmentLevel(Enchantments.POWER, knifeItem) val damage = damage + powerLevel.toDouble() * 0.6 if (EnchantmentHelper.getEnchantmentLevel(Enchantments.FLAME, knifeItem) > 0 && hitted.type !== EntityType.SNOW_GOLEM) hitted.setFire(100) hitted.attackEntityFrom(DamageSource.causeThrownDamage(knife, knife.thrower), damage.toFloat()) return hitted.type !== EntityType.SNOW_GOLEM && hitted.type !== EntityType.END_CRYSTAL && hitted.type !== EntityType.PANDA } override fun canApplyAtEnchantingTable(stack: ItemStack, enchantment: Enchantment): Boolean { return enchantment === Enchantments.POWER || enchantment === Enchantments.QUICK_CHARGE || enchantment === Enchantments.MENDING || enchantment === Enchantments.FLAME || enchantment === Enchantments.SILK_TOUCH || enchantment === Enchantments.UNBREAKING } companion object { var breakableBlocks: Set<Block> = ImmutableSet.of(Blocks.SPONGE, Blocks.VINE, Blocks.SEA_PICKLE, Blocks.WET_SPONGE) var breakableBlocksTypes: Set<Tag<Block?>> = ImmutableSet.of(Tags.Blocks.GLASS, Tags.Blocks.STAINED_GLASS_PANES) } } Entity exits(it has damage), but render isn't runned... I can not see it. And If i tap F3 + B there are not any hit boxes of it. It is really strange... I need some help.
  14. You can not use client classes on server part
  15. I try to divide game into stages. In some stages of the game, some biomes and structures should not be generated.
  16. If i try to get WorldSavedData from world gen it is null. How i can storage information for world gen?
  17. How do you imagine that? Yes, I can determine whether the item is salted or not, but how can I use it THERE? Should I write my entire food system or what? It sounds like a bicycle.
  18. Item#getFood does not contain it. I can not get it from there.
  19. How i can verify what item is salted without itemstack?
×
×
  • Create New...

Important Information

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