diff --git a/CHANGELOG.md b/CHANGELOG.md index 8394a6a5..c32e979c 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,3 +1,42 @@ +## Version 0.6 + +This update is brought to you by TorayLife. If features a lot of scripting related features like listening to Forge events, inline scripts, documentation improvements, and more! + +**Compatible** with McLib **2.4.1**, Aperture **1.8.1**, Blockbuster **2.6** and Metamorph **1.3.1**. It doesn't mean that future versions of McLib, Blockbuster and Metamorph would be incompatible, but older versions are most likely incompatible. + +* New triggers: + * Added **Player: toss an item** trigger +* New features: + * Added Forge event triggers that allow you to listen to Forge events. **WARNING**: this feature can corrupt your world. Use at own fear and risk! + * Added **Inline** scripts feature from BBS, that allows you to write JS (ES5) code directly in script trigger, without creating a script file + * Added `F6` keybind to run currently open script in the script editor + * Added `Ctrl + D` keybind to duplicate current line in script editor + * Added ability to translate documentation. Copy `docs.json` file from Mappet’s jar file, rename it to your language code (i.e. `ru_ru.json` for Russian) and put into `.minecraft/config/mappet/documentation/` + * Added **Ignore NBT** option in crafts and events + * Added search to documentation overlay + * Added link to JavaDocs in documentation + * Added new documentation sctructure. You can enable it in the config +* API changes: + * Added `IScriptNpc.setFaction()` method + * Added `entityItem` variable to **Player: picked up an item** trigger + * Added `IScriptEntity.setMaxHp(float)` method + * Added `IScriptFactory.getIScriptEntity(minecraftEntity)` method + * Added `IMappetSchematic` interface, that works with existing .schematic format + * Added methods to disable creative search and count in UIStackComponent + * Added `IScriptEntityItemStack` interface, that represents EntityItemStack (item that dropped into the world) + * Added `IScriptPlayer.giveItem(IScriptItemStack)` method +* Bugfixes: + * Fixed `UIStringListComponent` doesn’t update if you set empty array as a value + * Fixed `IScriptEvent.scheduleScript(int)` doesn’t work + * Fixed region block doesn’t work, if you disable `passible` option + * Fixed Kotlin doesn’t work with obfuscated methods + * Fixed crashes when you try to cancel uncancelable event + * Fixed crash when you open `executeScript` in documentation + * Fixed **Player: Respawn** trigger not working + * Fixed `createBlockState` issue with metadata +* Other: + * Completely rewrite Russian localization + ## Version 0.5.1 This patch update features Entity attacked trigger by TorayLife. @@ -10,13 +49,13 @@ This patch update features Entity attacked trigger by TorayLife. This is another HUGE update developed by OtakuGamer and TorayLife! This update features lots of new scripting API methods, global triggers, scripting logs panel and a conditional model block! -**IMPORTANT**: `IScriptEntity.shootBBGunProjectile()` to shoot the projectile with the whole data of the bb-gun settings (e.g. damage, etc.). +**IMPORTANT**: `IScriptEntity.shootBBGunProjectile()` to shoot the projectile with the whole data of the bb*gun settings (e.g. damage, etc.). **Compatible** with McLib **2.4.1**, Aperture **1.8.1**, Blockbuster **2.6** and Metamorph **1.3.1**. It doesn't mean that future versions of McLib, Blockbuster and Metamorph would be incompatible, but older versions are most likely incompatible. -* Added new global triggers: - * By TorayLife: `Entity: attacked` and `Player: open container` - * By OtakuGamer: `Projectile: impact`, `Living: equipment change`, `Mappet: state changed`, and `Living: knockback` +* Added new global triggers: + * By TorayLife: `Entity: attacked` and `Player: open container` + * By OtakuGamer: `Projectile: impact`, `Living: equipment change`, `Mappet: state changed`, and `Living: knockback` * Added **logs** panel, which will display script error logs, or records entered by scripts (TorayLife) * Added **Condition model block**, which will display different morphs depends on given conditions (TorayLife) * Added **Check entities** option to region block (TorayLife) @@ -24,20 +63,20 @@ This is another HUGE update developed by OtakuGamer and TorayLife! This update f * Added `/mp script engines` command, which returns list of installed script engines (TorayLife) * Added **Look at player** option's range now depends on path finding distance * Added more scripting API: - * Added `IScriptEvent.scheduleScript(int, Consumer)` overload with Consumer argument, so it works in different engines, such as Kotlin or Python (TorayLife) - * Added `IScriptEntity.setName()`, `IScriptEntity.setInvisible()`, `IScriptEntity.moveTo()`, `IScriptEntity.executeCommand()`, `IScriptEntity.executeScript()`, `IScriptEntity.getFactions()`, `IScriptEntity.lockPosition()`, `IScriptEntity.unlockPosition()`, `IScriptEntity.isPositionLocked()`, `IScriptEntity.lockRotation()`, `IScriptEntity.unlockRotation()`, and `IScriptEntity.isRotationLocked()` (OtakuGamer) - * Added `IScriptEntity.getMount()` method (TorayLife) - * Added `IScriptFactory.getLogger()` method, which returns a `MappetLogger` which can be used to log messages (TorayLife) - * Added `IScriptFactory.isPointInBounds()` and `IScriptFactory.toNBT()` (OtakuGamer) - * Added `info()`, `debug()`, `warning()`, `error()` methods to MappetLogger (TorayLife) - * Added `IScriptWorld.getBlockStackWithTile()`, `IScriptWorld.shootBBGunProjectile()` (OtakuGamer) - * Added `IScriptServer.entityExists()` and `IScriptServer.executeScript()` (OtakuGamer) - * Added `IScriptNBTCompound.addCompound()` and `IScriptNBTCompound.dumpJSON()` (OtakuGamer) - * Added AI methods `IScriptEntity.observe()`, `IScriptEntity.addEntityPatrol()`, `IScriptEntity.clearEntityPatrols()`, `IScriptEntity.setRotationsAI()`, `IScriptEntity.clearRotationsAI()`, `IScriptEntity.executeRepeatingCommand()`, `IScriptEntity.removeRepeatingCommand()`, and `IScriptEntity.clearAllRepeatingCommands()` (OtakuGamer) - * Added `IScriptFancyWorld` and moved some `IScriptWorld` methods to it (OtakuGamer) - * Added `getFancyWorld()` to `IScriptEvent`, `IScriptServer` and `IScriptEntity` (just like `getWorld()`) (OtakuGamer) - * Added `IScriptFancyWorld.explode()`, `IScriptFancyWorld.tpExplode()`, `IScriptFancyWorld.setBlock()`, `IScriptFancyWorld.fill()`, `IScriptFancyWorld.setTileEntity()`, `IScriptFancyWorld.fillTileEntities()`, `IScriptFancyWorld.clone()`, `IScriptFancyWorld.loadSchematic()`, and `IScriptFancyWorld.spawnNpc()` (OtakuGamer) - * Added `IScriptPlayer.getDisplayedHUDs()`, `IScriptPlayer.playScene()`, and `IScriptPlayer.stopScene()` (OtakuGamer) + * Added `IScriptEvent.scheduleScript(int, Consumer)` overload with Consumer argument, so it works in different engines, such as Kotlin or Python (TorayLife) + * Added `IScriptEntity.setName()`, `IScriptEntity.setInvisible()`, `IScriptEntity.moveTo()`, `IScriptEntity.executeCommand()`, `IScriptEntity.executeScript()`, `IScriptEntity.getFactions()`, `IScriptEntity.lockPosition()`, `IScriptEntity.unlockPosition()`, `IScriptEntity.isPositionLocked()`, `IScriptEntity.lockRotation()`, `IScriptEntity.unlockRotation()`, and `IScriptEntity.isRotationLocked()` (OtakuGamer) + * Added `IScriptEntity.getMount()` method (TorayLife) + * Added `IScriptFactory.getLogger()` method, which returns a `MappetLogger` which can be used to log messages (TorayLife) + * Added `IScriptFactory.isPointInBounds()` and `IScriptFactory.toNBT()` (OtakuGamer) + * Added `info()`, `debug()`, `warning()`, `error()` methods to MappetLogger (TorayLife) + * Added `IScriptWorld.getBlockStackWithTile()`, `IScriptWorld.shootBBGunProjectile()` (OtakuGamer) + * Added `IScriptServer.entityExists()` and `IScriptServer.executeScript()` (OtakuGamer) + * Added `IScriptNBTCompound.addCompound()` and `IScriptNBTCompound.dumpJSON()` (OtakuGamer) + * Added AI methods `IScriptEntity.observe()`, `IScriptEntity.addEntityPatrol()`, `IScriptEntity.clearEntityPatrols()`, `IScriptEntity.setRotationsAI()`, `IScriptEntity.clearRotationsAI()`, `IScriptEntity.executeRepeatingCommand()`, `IScriptEntity.removeRepeatingCommand()`, and `IScriptEntity.clearAllRepeatingCommands()` (OtakuGamer) + * Added `IScriptFancyWorld` and moved some `IScriptWorld` methods to it (OtakuGamer) + * Added `getFancyWorld()` to `IScriptEvent`, `IScriptServer` and `IScriptEntity` (just like `getWorld()`) (OtakuGamer) + * Added `IScriptFancyWorld.explode()`, `IScriptFancyWorld.tpExplode()`, `IScriptFancyWorld.setBlock()`, `IScriptFancyWorld.fill()`, `IScriptFancyWorld.setTileEntity()`, `IScriptFancyWorld.fillTileEntities()`, `IScriptFancyWorld.clone()`, `IScriptFancyWorld.loadSchematic()`, and `IScriptFancyWorld.spawnNpc()` (OtakuGamer) + * Added `IScriptPlayer.getDisplayedHUDs()`, `IScriptPlayer.playScene()`, and `IScriptPlayer.stopScene()` (OtakuGamer) * Fixed `IScriptFactory.convertToNBT()` method (TorayLife) * Fixed `IScriptItemStack.setLore()` method that doesn't add lore if item has no lore (TorayLife) * Fixed python errors in console (TorayLife) @@ -65,7 +104,7 @@ This is a HUGE scripting API update by OtakuGamer with some minor contributions * Added scripting `IScriptFactory.random(double)`, `IScriptFactory.random(double, double)`,`IScriptFactory.random(double, double, long)`, `IScriptFactory.style(String...)`, `IScriptFactory.vector2()`, `IScriptFactory.vector2(double, double)`, `IScriptFactory.vector2(Vector2d)`, `IScriptFactory.vector3()`, `IScriptFactory.vector3(double, double, double)`, `IScriptFactory.vector3(Vector3d)`, `IScriptFactory.vector4()`, `IScriptFactory.vector4(double, double, double, double)`, `IScriptFactory.vector4(Vector4d)`, `IScriptFactory.matrix3()`, `IScriptFactory.matrix3(Matrix3d)`, `IScriptFactory.matrix4()`, and `IScriptFactory.matrix4(Matrix4d)` * Added Can pick up loot option to NPCs (by Otaku) * Fixed Russian translation of trigger blocks' frequency option (by TorayLife) -* Fixed encoding problems by switching file reading strictly to UTF-8 (by Pyxl-ion and TorayLife) +* Fixed encoding problems by switching file reading strictly to UTF*8 (by Pyxl*ion and TorayLife) * Removed command `/mp data rencode` ## Version 0.3.1 @@ -82,7 +121,7 @@ This update is brought to you by TorayLife and McHorse. **Compatible** with McLib **2.4.1**, Blockbuster **2.6** and Metamorph **1.3.1**. It doesn't mean that future versions of McLib, Blockbuster and Metamorph would be incompatible, but older versions are most likely incompatible. -* Added support for any Java scripting engine. This means that scripts can be written in any language for which there is an engine. You can search for your language by `java scripting engine`. Mappet itself will determine which engine to use by file extension. (`js` - `javascript`, `kts` - `Kotlin Script`, etc). Made in cooperation with [dyamo](https://github.com/dyam0) +* Added support for any Java scripting engine. This means that scripts can be written in any language for which there is an engine. You can search for your language by `java scripting engine`. Mappet itself will determine which engine to use by file extension. (`js` * `javascript`, `kts` * `Kotlin Script`, etc). Made in cooperation with [dyamo](https://github.com/dyam0) * Added the ability to customize the syntax highlighting in the script editor. Use the files in the `config/mappet/highlights/` directory to customize it. Files for `js` and `kts` extensions are supplied by default * Added a special error text if no script engine is found * Added a folder system for events, dialogues, quests, scripts. etc. Use RMB on the file add, rename, remove icons for new functionality. (May contain bugs) @@ -95,7 +134,7 @@ This update is brought to you by TorayLife and McHorse. * Changed `IScriptPlayer.openUI()` to allow opening a UI when another scripted UI is opened * Fixed `IScriptPlayer.getSkin()` now it works much better * Fixed GraalJS not working with Mappet's scripts -* Fixed Ingredients label present when a recipe has no ingredients +* Fixed Ingredients label present when a recipe has no ingredients ## Version 0.2.3 @@ -115,13 +154,13 @@ This quick patch update patches and updates. * Added `/mp event stop ` subcommand which stops execution of delayed events (with Timer nodes) and scripts (`IScriptEvent.scheduleScript()`) * Added `Player: interact with an entity` global trigger * Added scripting methods: - * Added `IScriptWorld.explode()` - * Added `IScriptItemStack.getMaxCount()` - * Added `IScriptBlockState.isOpaque()` and `IScriptBlockState.hasCollision()` - * Added `IScriptWorld.rayTrace()` and `IScriptWorld.rayTraceBlocks()` - * Added `IScriptEntity.isOnGround()` - * Added `IScriptWorld.stopSound(String, String)`, `IScriptWorld.stopAllSounds()`, `IScriptPlayer.stopSound(String, String)`, and `IScriptPlayer.stopAllSounds()` - * Added `IScriptEntity.getCombinedLight()` + * Added `IScriptWorld.explode()` + * Added `IScriptItemStack.getMaxCount()` + * Added `IScriptBlockState.isOpaque()` and `IScriptBlockState.hasCollision()` + * Added `IScriptWorld.rayTrace()` and `IScriptWorld.rayTraceBlocks()` + * Added `IScriptEntity.isOnGround()` + * Added `IScriptWorld.stopSound(String, String)`, `IScriptWorld.stopAllSounds()`, `IScriptPlayer.stopSound(String, String)`, and `IScriptPlayer.stopAllSounds()` + * Added `IScriptEntity.getCombinedLight()` * Fixed an error with quest node in a dialogue not loading when quest isn't accepted * Fixed respawn options can't be edited by `/mp npc edit` command * Fixed a couple of misspellings in documentation @@ -145,18 +184,18 @@ This update is brought to you by TorayLife (again), featuring NPC respawning mec * Added NPC respawn mechanism with multiple options such as: respawn delay, respawn at died coordinates, and respawn trigger * Added patrol trigger for NPC's patrol points -* Added mod option to limit non-creative players to use NPC tool -* Added mod option to limit non-creative players to open Mappet dashboard (even with OP) +* Added mod option to limit non*creative players to use NPC tool +* Added mod option to limit non*creative players to open Mappet dashboard (even with OP) * Added toggle to player journal to toggle visibility of a quest in HUD * Added comment node to events as well * Added scripting methods: - * Global triggers now pass `event` variable (which is a Forge event), it's useful for advanced scripting (requires knowledge of working with MCP-SRG maps) - * Added sound category to `playSound` and `playStaticSound` methods which allow to specify a channel in which sound would be playing - * Added `IScriptPlayer.setHunger(int)`, `IScriptPlayer.getHunger()`, `IScriptPlayer.setSaturation(int)`, and `IScriptPlayer.getSaturation()` - * Added `IScriptNpc.setNpcState(String)` and `IScriptNpc.getNpcState()` - * Added `UIStringListComponent.setValues(List)` (alias for `UIStringListComponent.values(List)`) and `UIStringListComponent.getValues()` - * Added selected index of a string list UI component to the context data (in `%component_id%.index`) - * Added `INBTCompound.getNBTTagCompound()` (fixes a typo of deprecated method `INBTCompound.getNBTTagComound()`) + * Global triggers now pass `event` variable (which is a Forge event), it's useful for advanced scripting (requires knowledge of working with MCP*SRG maps) + * Added sound category to `playSound` and `playStaticSound` methods which allow to specify a channel in which sound would be playing + * Added `IScriptPlayer.setHunger(int)`, `IScriptPlayer.getHunger()`, `IScriptPlayer.setSaturation(int)`, and `IScriptPlayer.getSaturation()` + * Added `IScriptNpc.setNpcState(String)` and `IScriptNpc.getNpcState()` + * Added `UIStringListComponent.setValues(List)` (alias for `UIStringListComponent.values(List)`) and `UIStringListComponent.getValues()` + * Added selected index of a string list UI component to the context data (in `%component_id%.index`) + * Added `INBTCompound.getNBTTagCompound()` (fixes a typo of deprecated method `INBTCompound.getNBTTagComound()`) * Fixed some places missing OP checks * Fixed morph UI component erroring on a dedicated server * Fixed crash when trying to copy non selected data entry in one of the Mappet dashboard panels @@ -168,16 +207,16 @@ This update is brought to you by TorayLife, with some neat QoL features, trigger **Compatible** with McLib **2.3.5**, Blockbuster **2.3** and Metamorph **1.2.9**. It doesn't mean that future versions of McLib, Blockbuster and Metamorph would be incompatible, but older versions are most likely incompatible. * Added new triggers: - * `Player: log out` trigger gets triggered with a subject player when player logs off the server - * `Player: interact an item` trigger gets triggered when a player right clicks (interacts with) an item in the air + * `Player: log out` trigger gets triggered with a subject player when player logs off the server + * `Player: interact an item` trigger gets triggered when a player right clicks (interacts with) an item in the air * Added scripting methods: - * `IMappetUIBuilder.paused(boolean)` which allows to make UI pausable in singleplayer (by McHorse) - * `IMappetStates.isNumber(String)` and `IMappetStates.isString(String)` allow to check whether given state is of number or string type - * `IScriptItemStack.copy()` which allows to duplicate an item stack -* Added new string value comparison types: - * Exact match of given string (value == "...") - * Contains somewhere in the value a string (value contains "...") - * Regular expression match (value matches /.../) + * `IMappetUIBuilder.paused(boolean)` which allows to make UI pausable in singleplayer (by McHorse) + * `IMappetStates.isNumber(String)` and `IMappetStates.isString(String)` allow to check whether given state is of number or string type + * `IScriptItemStack.copy()` which allows to duplicate an item stack +* Added new string value comparison types: + * Exact match of given string (value == "...") + * Contains somewhere in the value a string (value contains "...") + * Regular expression match (value matches /.../) * Added comment node to dialogues, which passes execution to its connected child nodes, but the main feature is to label or comment sections of the dialogue * Added a feature for emitter block to check against players within the radius (rather than globally) when `radius > 0` * Fixed `Entity: hurt` trigger getting triggered only when a player hurts an entity (and not when other entities hurt each other) @@ -224,31 +263,31 @@ This is a small patch update which fixes a couple of things. ## Version 0.1.1 -This is a small patch which also features new expression condition block. For full change log, check out [this page](https://github.com/mchorse/mappet/wiki/Change-log#01-to-011). +This is a small patch which also features new expression condition block. For full change log, check out [this page](https://github.com/mchorse/mappet/wiki/Change*log#01*to*011). **Compatible** with McLib **2.3.5**, Blockbuster **2.3** and Metamorph **1.2.9**. It doesn't mean that future versions of McLib, Blockbuster and Metamorph would be incompatible, but older versions are most likely incompatible. ## Version 0.1 -I don't really have anything to say about this update. It has a couple of neat QoL features, but I think that is it. For full list of changes, check [this page](https://github.com/mchorse/mappet/wiki/Change-log#-rc5-to-01).  +I don't really have anything to say about this update. It has a couple of neat QoL features, but I think that is it. For full list of changes, check [this page](https://github.com/mchorse/mappet/wiki/Change*log#*rc5*to*01).  **Compatible** with McLib **2.3.5**, Blockbuster **2.3** and Metamorph **1.2.9**. It doesn't mean that future versions of McLib, Blockbuster and Metamorph would be incompatible, but older versions are most likely incompatible. ## Version 0.1 (rc5) -This update features new **world morphs** feature, which allows to display client side morphs without spawning entities (which is a really good tool for visual effects), more scripting methods, more global triggers, and a couple of neat tweaks. For full list of changes, check [this page](https://github.com/mchorse/mappet/wiki/Change-log#-rc4-to--rc5). +This update features new **world morphs** feature, which allows to display client side morphs without spawning entities (which is a really good tool for visual effects), more scripting methods, more global triggers, and a couple of neat tweaks. For full list of changes, check [this page](https://github.com/mchorse/mappet/wiki/Change*log#*rc4*to**rc5). **Compatible** with McLib **2.3.3**, Blockbuster **2.3** and Metamorph **1.2.9**. It doesn't mean that future versions of McLib, Blockbuster and Metamorph would be incompatible, but older versions are most likely incompatible. ## Version 0.1 (rc4) -This update features more UI component scripting methods, more global triggers, and many neat tweaks. For full list of changes, check [this page](https://github.com/mchorse/mappet/wiki/Change-log#-rc3-to--rc4). +This update features more UI component scripting methods, more global triggers, and many neat tweaks. For full list of changes, check [this page](https://github.com/mchorse/mappet/wiki/Change*log#*rc3*to**rc4). **Compatible** with McLib **2.3.3**, Blockbuster **2.3** and Metamorph **1.2.9**. It doesn't mean that future versions of McLib, Blockbuster and Metamorph would be incompatible, but older versions are most likely incompatible. ## Version 0.1 (rc3) -This update features new UI scripting API and a couple of useful scripting functions. For full list of changes, check [this page](https://github.com/mchorse/mappet/wiki/Change-log#-rc1-to--rc3). +This update features new UI scripting API and a couple of useful scripting functions. For full list of changes, check [this page](https://github.com/mchorse/mappet/wiki/Change*log#*rc1*to**rc3). **Compatible** with McLib **2.3.2**, Blockbuster **2.3** and Metamorph **1.2.9**. It doesn't mean that future versions of McLib, Blockbuster and Metamorph would be incompatible, but older versions are most likely incompatible. @@ -267,11 +306,11 @@ This bugfix update features only some important bug and crash fixes. ## Version 0.1 (rc1) -The list of changes is available [here](https://github.com/mchorse/mappet/wiki/Change-log#-dev3-to--rc1). Main features of this update are: in-game scripting documentation, scripting REPL, states editors, HUD scenes and Trigger node. +The list of changes is available [here](https://github.com/mchorse/mappet/wiki/Change*log#*dev3*to**rc1). Main features of this update are: in*game scripting documentation, scripting REPL, states editors, HUD scenes and Trigger node. **Compatible** with McLib **2.3**, Blockbuster **2.3** and Metamorph **1.2.7**. It doesn't mean that future versions of McLib, Blockbuster and Metamorph would be incompatible, but older versions are most likely incompatible. -## Version 0.1-alpha +## Version 0.1*alpha This first release provides tons of features: states, conditions, expressions, emitter block, trigger block, region block, crafting tables, quests, NPCs, factions, events, scripts, dialogues, quest chains, many commands, custom sound events, target selectors, global triggers, and much more. diff --git a/version.json b/version.json index 140aaa15..437be7a4 100644 --- a/version.json +++ b/version.json @@ -1,6 +1,7 @@ { "homepage": "https://www.curseforge.com/minecraft/mc-mods/mappet", "1.12.2": { + "0.6": "This update is brought to you by TorayLife. If features a lot of scripting related features like listening to Forge events, inline scripts, documentation improvements, and more!", "0.5.1": "This patch update features Entity attacked trigger by TorayLife.", "0.5": "This is another HUGE update developed by OtakuGamer and TorayLife! This update features lots of new scripting API methods, global triggers, scripting logs panel and a conditional model block!", "0.4": "This is a HUGE scripting API update by OtakuGamer with some minor contributions by TorayLife.", @@ -19,7 +20,7 @@ "0.1-alpha": "This first release provides tons of features: states, conditions, expressions, emitter block, trigger block, region block, crafting tables, quests, NPCs, factions, events, scripts, dialogues, quest chains, many commands, custom sound events, target selectors, global triggers, and much more." }, "promos": { - "1.12.2-latest": "0.5.1", - "1.12.2-recommended": "0.5.1" + "1.12.2-latest": "0.6", + "1.12.2-recommended": "0.6" } } \ No newline at end of file