Giter Site home page Giter Site logo

cocolabs / pz-zmod Goto Github PK

View Code? Open in Web Editor NEW
21.0 3.0 1.0 580 KB

ZomboidMod is compact mod development environment for Project Zomboid.

License: MIT License

Java 75.35% Shell 22.38% Ruby 2.27%
zomboid project-zomboid mod projectzomboid build-environment

pz-zmod's People

Contributors

matshou avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar

Forkers

xenoloaf

pz-zmod's Issues

Cannot run "initializeMod" run configuration :: Caused by: java.lang.NoSuchMethodException: No such accessible method: getGameVersion() on object: zombie.core.Core

Reproduction Steps:

  • Follow setup procedure with version 2.4.0 up to the intellij setup
  • In Intellij, Choose > File > Project Structure
  • Set Project SDK to corretto-1.8
  • Set Project language level to sdk default ( 8 - Lambdas, type annotations etc.)
  • Run initializeMod
  • Enter Project Zomboid Path
  • Enter intellij
  • Get error Caused by: java.lang.NoSuchMethodException: No such accessible method: getGameVersion() on object: zombie.core.Core

Create project README

The current project README does not give any information on what this project is about, it is a template for building a mod.
This version of the readme should be the one included in the distribution, but the repo one should be instructional.

Discord rich presence

Create IDEA Discord rich presence configuration so users can display their modding activity.

Error when decompiling with Java 8 (UnsupportedClassVersionError)

This exception occurs because the decompiler jar distributed with IntelliJ IDEA has been compiled with a higher Java version.

Stacktrace:

java.lang.UnsupportedClassVersionError: org/jetbrains/java/decompiler/main/decompiler/ConsoleDecompiler has been compiled by a more recent version of the Java Runtime (class file version 55.0), this version of the Java Runtime only recognizes class file versions up to 52.0
	at java.lang.ClassLoader.defineClass1(Native Method)
	at java.lang.ClassLoader.defineClass(ClassLoader.java:756)
	at java.security.SecureClassLoader.defineClass(SecureClassLoader.java:142)
	at java.net.URLClassLoader.defineClass(URLClassLoader.java:468)
	at java.net.URLClassLoader.access$100(URLClassLoader.java:74)
	at java.net.URLClassLoader$1.run(URLClassLoader.java:369)
	at java.net.URLClassLoader$1.run(URLClassLoader.java:363)
	at java.security.AccessController.doPrivileged(Native Method)
	at java.net.URLClassLoader.findClass(URLClassLoader.java:362)
	at java.lang.ClassLoader.loadClass(ClassLoader.java:418)
	at sun.misc.Launcher$AppClassLoader.loadClass(Launcher.java:352)
	at java.lang.ClassLoader.loadClass(ClassLoader.java:351)
	at sun.launcher.LauncherHelper.checkAndLoadMain(LauncherHelper.java:601)
Error: A JNI error has occurred, please check your installation and try again

Set language level for gradle JVM

Currently the setup is relaying on users to properly set their JDK in project properties. This can be improved by using gradle toolchains which allow us to properly designate which JDK we want the project to use. If the designated JDK is not installed locally, it will be downloaded, automating things for users.

runZomboidDoc config fails with java version error

Running with fresh install and default settings against build 41 gives an error like:

zombie/Lua/LuaManager has been compiled by a more recent version of the Java Runtime

Changing the following line in zdoc.gradle (176):

		languageVersion = JavaLanguageVersion.of(8)

to

		languageVersion = JavaLanguageVersion.of(15)

fixes the issue for me. Not sure if 15 is the right version to pick but it gets the job to run happily and autocomplete works like a charm.

Changelog repo user configuration

Project properties that define repository information for generateChangelog task need to be automatically configured from user input. The best way to get repo.owner and repo.name would be from url property in mod.info file.

Automate dev environment creation

Tasks that need to be executed in a particular order to create a dev environment from scratch should be executed under a single task to make it easier for new users to set everything up with just running one or two gradle tasks.

Gradle sync fails with IDEA

Gradle auto-build action fails when refreshing build before initializing mod properties.

FAILURE: Build failed with an exception.

* Where:
Script 'C:\Users\Yooks\Documents\GitHub\project-zomboid\pz-zmod\setup.gradle' line: 35

* What went wrong:
A problem occurred evaluating script.
> Unable to find local project property gameDir

Document setting path variable

IDEA path variable $PZ_DIR_PATH needs to be set in order to launch game via run configurations.
This should be documented in Setup section of README.md.

Run ZomboidDoc on new versions

ZomboidMod should store the current version of ZomboidDoc and run all associated tasks when dependency updates version.

Task to apply mod template

Current distribution is not including ZomboidMod README.md or LICENSE.txt. Distribution should not be a out-of-the box template, but rather have a task to set it up which can be included in an existing run configuration.

Execution failed for task ':compileZomboidLua'.

Hi everyone, when launching the gradle task "setupWorkspace" it is unable to conclude due to the error reported here:
Execution failed for task ':compileZomboidLua'.

Process 'command 'C:\Program Files\Java\jre1.8.0_311\bin\java.exe'' finished with non-zero exit value 1
Any suggestions?

Steam mods not loading in game

The mods I have installed via Steam are not appearing in the mods menu.

It should be noted that the game has three directories for mods: Local-Mods, Workshop-Upload, and Workshop-Download.

Local-Mods = C:\Users\<name>\Zomboid\mods
Workshop-Upload = C:\Users\<name>\Zomboid\Workshop
Workshop-Download = D:\Steam\steamapps\workshop\content

Assembling mod distributions

Creating mod distributions should be automated with gradle distribution plugin.

There are currently tasks that assemble classes (mediaClasses) and resources (processMediaResources), they just need to be packed together with other content in a distribution archive.

Library sources do not match bytecode

Decompiled sources do not match bytecode for output of zomboidClasses.

When sources are attached to classes in a jar that resulted as output from zomboidJar the error does not occur.

Initialize mod.info with console

Mod properties should not have to be manually updated by users.
They should be able to provide values for each property through console inputs.

Console log highlighting

Distribution should include a Grep configuration that highlights log entries according to preset groups. Aside from Highlighting warning and errors, Grep should also highlight all logs printed from mod scripts (provided they use the right format).

2021-02-22_205414

initModInfo task failed on Could not get resource 'https://git.io/JqJiC'

  • Environment:
    Windows 11, Intellij IDEAC 2023.2.5, adoptium jdk8u392, in a restricted network but has a proxy tool
  • How it went wrong:
    Downloaded latest release, follow the instruction and got stuck on this.
FAILURE: Build failed with an exception.

* Where:
Script 'D:\Projects\Mod\ProjectZomboid\pzarcade\distribution.gradle' line: 5

* What went wrong:
A problem occurred evaluating script.
> Could not get resource 'https://git.io/JqJiC'.
   > Could not GET 'https://git.io/JqJiC'.
      > Connect to git.io:443 [git.io/128.242.240.218, git.io/2a03:2880:f10a:83:face:b00c:0:25de] failed: Connection timed out: connect

* 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 42s

Support for modular mod structure

Project Zomboid supports modular mod structures for Steam workshop mods.
Each mod uploaded to the workshop can contain other mods that can then be toggled on and off in the game mod menu.

Currently zmod does not support this modular structure and some features will not work.

Sync distribution with Steam workshop

Developing mods built with gradle under VCS for the Steam workshop is difficult as everything located in the workshop staging area gets pulled and packaged as part of the mod. This includes project build, config and VCS files.

To resolve this, distributions installed with installDist should be synced with the designated Steam workshop directory to allow modders to keep their mod dev environment separate from workshop directory.

Dynamic game version property

Property game_version defined in gradle.properties should be dynamically set according to actual game version.
We can use version command from ZomboidDoc to get current game version.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.