Releases: DistrictOfJoban/Joban-Client-Mod
v2.1.2
JCM v2.1.2 for MTR 4.0.3 has been released!
New
- Scripting
-
- Add script quick reload, allowing reloading script without reloading the entire resource pack.
-
-
- JCM Debug Mode must be enabled before using.
-
-
-
- Shift+R: Reload JCM Scripts
-
-
-
- Ctrl+R: Reload MTR Scripts
-
Fixes
- Scripting
-
- Add
java.text.*package to whitelist, allowingAttributedStringto be used on AWT Graphics-based PIDS.
- Add
-
- Fix internal timer possibly rolling into the negatives after rejoining world, causing script with
RateLimitto not work properly for a short while.
- Fix internal timer possibly rolling into the negatives after rejoining world, causing script with
- Fix breaking incomplete/broken multipart block crashing the game.
Download:
You can download this release on Modrinth, CurseForge or GitHub
v2.1.1
JCM v2.1.1 for MTR 4.0.2 has been released!
Fixes
- Fix Weather icon in JSON PIDS Preset being slightly off vertically
- Scripting:
-
- Fix Draw Calls offset potentially affecting position of another draw call
-
- Fix
MinecraftClient#localPlayer()being a non-static method, now you can invoke them directly like all other static method.
- Fix
-
- Fix RenderManager not applying equivalent transformation when used in JCM PIDS.
Download:
You can download this release on Modrinth, CurseForge or GitHub
v2.1.0
JCM v2.1.0 for MTR 4.0.2 has been released!
New
- Add Help Line (Tseung Kwan O Line Type)
- The Script Debug Overlay now allows switching between sources (MTR/JCM) to provide a more clutter-free view.
-
- Default keybind is [ and ], can be changed in Minecraft keybind settings.
- Add Eyecandy Scripting, see documentations for details.
Changes
- Scripting Engine (Rhino)
-
- For Minecraft 1.17+, the Rhino engine has been updated to 1.8.0 which added more support for modern JS syntax. See this compatibility table for details.
- Script Execution:
-
- Script may now execute among 4 different threads.
-
- Note: The same type of script entry will always be executed on the same thread
- Slightly refactor the transaction history logic, should hopefully be a little more robust.
Misc
- Full Changelogs for Script Developers:
For Minecraft 1.16 players
Minecraft 1.16 has already been released for well over 4 years. While there are many efforts in the codebase to make JCM available for 1.16, it also puts a burden to maintain them.
- Feature parity for 1.16 will no longer be maintained. New script features/capabilities (Especially scripting engine related) may not be available on 1.16.
- Players who are still playing on 1.16 should consider upgrading to any newer version.
- When demands have become low enough, we may consider dropping 1.16 builds all-together.
Download:
You can download this release on Modrinth, CurseForge or GitHub
v2.1.0-beta.3
JCM v2.1.0-beta.3 for MTR 4.0.2 has been released!
Note: Normal players are strongly advised to wait until the official release of v2.1.0.
Changes
- Script Execution:
-
- Script Execution are now changed so that the same type of script are executed orderly in the same thread (No longer parallelized per-instance). This should hopefully alleviate some multithreading issues with scripts.
- Slightly refactor the transaction history logics, should hopefully be a little more robust.
Download:
You can download this release on Modrinth, CurseForge or GitHub
v2.1.0-beta.2
JCM v2.1.0-beta.2 for MTR 4.0.2 has been released!
Note: Normal players are strongly advised to wait until the official release of v2.1.0.
New (Scripting Implementation)
Scripting Engine
- Update to Rhino 1.8.1 (Minecraft 1.17+) & Rhino 1.7.15.1 (Minecraft 1.16.5)
-
- Fix a problem with formatting of floating-point numbers to strings that may result in very bad performance in some cases. (Rhino Changelog)
Execution
- Scripts may now execute across 4 different threads (Instead of only 1 background thread), which should improve the amount of scripts that can be executed simultaneously. (zbx1425 for the idea)
Networking
- Breaking change: A failed HTTP request via the
Networkingclass no longer throws an exception. -
- Use
NetworkResponse.success()to check whether the request succeeded
- Use
-
- Use
NetworkResponse.exception()to get the raw java exception.
- Use
- Add
NetworkResponse.ok()to check whether the response code returned by the server is successful. (HTTP Request Code >= 200 & <= 299)
Eyecandy Scripting
- Add
EyecandyBlockEntity.redstoneSignal()to process redstone signal in the block. -
- Note: This only returns 0 and 15 (lit & unlit) with the current implementation. Scripts should however account for future changes, where the true signal level is returned.
- Experimental: Add
EyecandyBlockEntity.setCollisionShape()to set the client-side collision shape of the block. -
- At most 1x1x1 (16x16x16 block unit), anything higher may cause the collision shape to not work as intended.
Download:
You can download this release on Modrinth, CurseForge or GitHub
v2.1.0-beta.1
JCM v2.1.0-beta.1 for MTR 4.0.2 has been released!
New (Player features)
- Add Help Line (Tiu Keng Leng Station Type)
- The Script Debug Overlay now allows switching between sources (MTR/JCM) to provide a more clutter-free view.
-
- Default keybind is
[and], can be changed in Minecraft keybind settings.
- Default keybind is
- More scripting progress, implementation additions are outlined below.
-
- Major milestone reached:
-
-
- [v2.0.0] PIDS Preset Scripting
-
-
-
- [v2.1.0] Scripted Eyecandy displays (e.g. LCD screens) now possible with the use of QuadDrawCall.
-
-
-
- [v2.1.0] MTR 4 version of
mtr_custom_resources.jsonmay now register scripts!
- [v2.1.0] MTR 4 version of
-
New (Scripting Implementation)
Registration
- Eyecandy/Decoration Object scripts in the MTR 4 custom resource format can now be registered!
-
- See documentation for details!
- Added Script Input feature
-
scriptInput(MTR 3/NTE/JCM) /scripting.input(MTR 4) field can now be supplied in the json entry alongsidescriptFilesandscriptText.
-
- Anything within the field (JSON Object/Array/String) will be made accessible to the script via the
SCRIPT_INPUTvariable.
- Anything within the field (JSON Object/Array/String) will be made accessible to the script via the
-
- This is intended as a successor to
scriptTexts(w/ only variable declaration) and ANTE'sCONFIG_INFOfeature.
- This is intended as a successor to
Scripting Engine (Rhino)
- For Minecraft 1.17+, the Rhino JS engine has been updated to 1.8.0 which added more support for modern JS syntax. See this compatibility table for details.
- Minecraft 1.16.5 will remain on Rhino 1.7.15 due to the Java 8 requirement.
Sound
- Added a new
SoundManagerclass for all types of scripting. -
- Provide generic ways to play sound onto the Minecraft world.
ctx.playSound(),ctx.playCarSound()&ctx.playAnnSound()has been deprecated in favor of SoundManager.
Rendering
- Added a new
RenderManagerclass for all types of scripting. - Provide generic ways to draw 3D models or quads onto the Minecraft world
ctx.drawModel(),ctx.drawCarModel()andctx.drawConnModel()has been deprecated in favor of RenderManager.
Eyecandy Scripting
- Adapt RenderManager & SoundManager, can be accessed by
ctx.renderManager()&ctx.soundManager(), see above. - Add
EyecandyBlockEntity.pos()andEyecandyBlockEntity.blockPos()to determine where the eyecandy block is placed. - Allow setting custom outline shape with
ctx.setOutlineShape(shape: VoxelShape) - Add block use events for eyecandy
-
- Call
ctx.events().onBlockUse.occurred()to check, andctx.events().onBlockUse.detail()for event detail.
- Call
-
- Important: Acknowledge events with
ctx.events().handled()afterwards at suitable interval so the internal event state is reset.
- Important: Acknowledge events with
PIDS Scripting
- Adapt RenderManager & SoundManager, can be accessed by
ctx.renderManager()&ctx.soundManager(), see above. -
- This grants PIDS scripts the ability to render 3D OBJ model. It is advised to use this in conjunction with PIDS Projector, which is an invisible block.
- Add
PIDSBlockEntity.blockPos()to determine where the PIDS block is placed. - Add
PIDSBlockEntity.isKeyBlock()to determine if the current block is a unique block within a PIDS pair (e.g. Identify 1 side of a dual-sided PIDS)
Misc. Scripting Additions
- Added the Noto Sans CJK font that were previously shipped with NTE.
- Add
display_helper.jsbased on NTE's implementation. This should provide full backward compatibility for eyecandy using DisplayHelper, without manual interference needed for upgrade. - Add
Vector3ffor performing position-related operation. - Add
VanillaTextfor creating and styling minecraft-based text. (Bold/Italic/Colors etc.) -
- Add
MinecraftClient.displayMessage(text: VanillaText, actionBar: boolean)overload to display these text in chat or action bar, in addition to thestringvariant.
- Add
-
- This can be considered a substitute of
ComponentUtilin ANTE.
- This can be considered a substitute of
- Add
MinecraftClient.localPlayer(): PlayerEntityto retrieve more detailed info of the client player. - Add
MinecraftClient.getScoreboardScore(objective: string, playerName: string)to obtain the scoreboard score of a player. - Add
MinecraftClient.blockLightAt(pos: vector3f),MinecraftClient.skyLightAt(pos: vector3f),MinecraftClient.lightLevelAt(pos: vector3f)to determine light level in the world. - Add
MinecraftClient.gamePaused(): booleanto determine if the game has been paused. - Add
StateTracker.changedTo(state: any)andStateTracker.changedFromTo(fromState: any, toState: any)
Changes
- Scripting:
-
StateTrackernow accepts non-string values.
-
GraphicsTexture.upload()are now more optimized, should be mostly on-par with NTE.
-
- The
Networkingclass in JCM will no longer overwrite the User-Agent header if scripting restrictions is disabled.
- The
Fixes
- Fix script not disposed after leaving the game
- Fix
Timing.elapsed()only returning in-game tick values (i.e. in at least 50ms increments) -
- This also fix
RateLimitonly allowing a max update rate of 20 times per second caused by the above.
- This also fix
Documentations
As JCM v2.1 is still in beta, the documentation for the main site would continue to present v2 as the default.
To view the documentation for v2.1, please use the version selector on the top left of the page to access it.
The v2.1 scripting documentation has been slightly restructured. For existing PIDS Scripting users, this may take some time to get used to!
Content changes (Excluding restructuring):
- Add Scripting Guidelines page
- Add Migration from NTE page
- Add Script Debug Overlay page
- Add Display Helper page (Note: This is mostly translated from NTE's documentation)
- Add
Vector3fto Math Utilities page ResourceLocationhas now been renamed toIdentifieracross the documentations.- Remove the
wrappersuffix for class names, as they should be transparent to script developers -
PIDSWrapperhas been renamed toPIDSBlockEntity
-
ArrivalsWrapperhas been renamed toArrivalEntries
-
ArrivalWrapperhas been renamed toArrivalEntry
Important Note
For Minecraft 1.16 players
Minecraft 1.16 has already been released for well over 4 years. While there are many efforts in the codebase to make JCM available for 1.16, it also puts a burden to maintain them.
- Minecraft 1.16 will no longer receive first-class support like other versions.
- Feature parity will no longer be maintained. New script features/capabilities (Especially scripting engine related) may not be available on 1.16.
- Players who are still using Minecraft 1.16 should consider upgrading to any newer version.
- When demands have become low enough, we may consider dropping all 1.16 builds and CI all-together.
For other players
This is a beta release primarily for script developers to play around and give feedback on.
Normal players are strongly advised to wait until the official release of v2.1.0.
For Script Developers
Breaking changes may occur for all new features introduced during the v2.1.0 beta. JSON fields and scripting APIs may be moved, renamed, redesigned or scrapped at any point during beta releases.
You are more than encouraged to provide feedback for the newly introduced features (Yes, down to the naming!). Otherwise, no new breaking changes will be introduced after the official release, and any imperfections/annoyance that you perceive will stay with you forever :D
Download:
You can download this release on Modrinth, CurseForge or GitHub
v2.0.2
JCM v2.0.2 for MTR 4.0.0/4.0.1 has been released!
JCM v2.0.2 is a bug-fix release. Players using the older v2 version should update for the best experience.
Details as follows:
Fix:
- Allow PIDS 1A to be placed by regular MTR PIDS Pole again.
- Fix RV PIDS Pole not extending with slab on top.
Download:
You can download this release on Modrinth, CurseForge or GitHub
v2.0.1
JCM v2.0.1 for MTR 4.0.0/4.0.1 has been released!
JCM v2.0.1 is mostly a bug-fix release, details as follows:
Fix:
- PIDS Scripting
-
ArrivalWrapper.platforms()no longer return duplicated platform
-
sun.awt.*is now whitelisted to allow Awt RenderHints to work
- Fix a potential crash with RV PIDS
Download:
You can download this release on Modrinth, CurseForge or GitHub
v2.0.0
JCM v2.0.0 for MTR 4.0.0 has been released!
JCM v2.0.0 is a huge milestone for Joban Client Mod! The mod has been rewritten from the ground up with more features empowering players to express their creativity. For more details please view the full changelog.
Note that JCM v2.0.0 is only designed for MTR 4.0.0, and is therefore incompatible with MTR v3.x.
Conversely, JCM v1.x only supports MTR 3.x, and is incompatible with MTR v4.x.
Download:
You can download this release on Modrinth, CurseForge or GitHub
v2.0.0-prerelease.4
JCM (v2.0.0-prerelease.4) for (MTR 4.0.0-prerelease.3) has been released!
Additions:
- Scripting:
-
- Add Script Debug Overlay to display all script instances.
-
-
- Toggleable in JCM Settings > Enable debug mode
-
-
-
- Text highlight color represents the execution speed (Blue = Normal, Yellow = Slow, Red = Very Slow!)
-
-
-
-
- Script authors should generally aim for Blue color
-
-
-
- Add back
ctx.setDebugInfo()from NTE
- Add back
-
- Add
ctx.debugModeEnabled()to determine if JCM debug mode is enabled.
- Add
Changes:
- Operator Button will no longer accept driver keys that are expired. (Creative keys are always accepted)
- Scripting
-
- Due to popular demand, an option is added in JCM config to disable scripting class restriction entirely, this allows any external java packages to be used just like in NTE.
Fixes:
- Fix horizontal blocks (Double ceiling/Trespass Sign) potentially breaking when stacked with WorldEdit
- Scripting
-
- Texts with marquee overflow now no longer disappear for a prolonged duration of time before resetting.
Download:
You can download this release on Modrinth or GitHub