Commit Graph
4117 Commits
Author SHA1 Message Date
bigguy345 6fc0bf4d6b Fix expression typing gate to route JS function/lambda expressions into ExpressionParser
Problem:
- function(act){...} expressions not reaching ExpressionParser
- resolveExpressionType only checked containsOperators() or startsWith("(")
- Function expressions went through simple resolver and returned null type

Solution:
- Added looksLikeFunctionOrLambda helper (lines 4766-4773) to detect:
  * JS functions: function(...)
  * Arrow functions: =>
  * Java lambdas: ->
- Updated gate condition at line 4144 to route these into ExpressionParser
- Function expressions now reach ExpressionTypeResolver.resolveJSFunctionType

Impact:
- SAM typing now works in pass-2 when expected type is known
- Fixes schedule("TpGainAction", function(act){...}) argument typing
- Enables proper overload resolution for function/lambda parameters
2026-02-03 22:12:43 +02:00
bigguy345 ba7e4cc3b2 Merge remote-tracking branch 'origin/dev' into syntax-highlighter-unified
# Conflicts:
#	src/api
#	src/main/java/kamkeel/npcs/util/BukkitUtil.java
#	src/main/java/kamkeel/npcs/util/VaultUtil.java
#	src/main/java/noppes/npcs/CustomNpcsPermissions.java
2026-02-03 18:26:30 +02:00
Vidal 2d47aa00d8 - Added standalone min max methods to FieldDef
- Increased lightning density and radius minmax on all energy abilities
- Made AbilityOrbBarrage interruptible during active state
- Renamed AbilityEnergyBeam to AbilityBeam
- Updated imports
2026-02-03 12:32:30 -03:00
Vidal 1a8b8fb5f3 Made staves shoot EntityAbilityOrb 2026-02-03 11:58:39 -03:00
Vidal eb2d904bac Color-only overload to EnergyColorData 2026-02-03 11:57:47 -03:00
Vidal 4889c8b881 Added animation to shockwave 2026-02-03 11:57:19 -03:00
Vidal c5822023a0 Added modifyVisibility to FieldDef
AbilityGuard tweaks
2026-02-03 07:45:02 -03:00
Kam fd85215592 Fix Ability Def Handler 2026-02-03 05:07:54 -05:00
Kam b368871e4f Update Ability.java 2026-02-03 04:45:31 -05:00
Kam 8aa6e926f6 Some Ability Helpers 2026-02-03 04:27:54 -05:00
Vidal 8fc0155df8 Attempt at damage reduction 2026-02-03 06:22:24 -03:00
Vidal 4f629c5679 Made ability abort after the counter has been triggered 2026-02-03 05:57:40 -03:00
Vidal 60b846b35e - Added onDamageTaken to Ability
- Reworked AbilityGuard
- Added AbilityOrbBarrage
- Updated translation
- Updated onDamageTaken method calls
2026-02-03 05:43:50 -03:00
bigguy345 9db8a0b2e7 Forgotten Merge resolution for 'Add Tooltips.' commit 2026-02-03 07:20:24 +02:00
bigguy345 9e4692d8e4 Support d.ts patch overlays in gradle plugin
GenerateTypeScriptTask can now copy an optional patches directory into the generated output so manual overrides can ship alongside generated defs.

Converter tweaks: anchor method signature regex to line starts, and ensure generated (including nested) types include a @javaFqn tag for reliable mapping back to Java sources.
2026-02-03 07:04:50 +02:00
bigguy345 074c780d50 Add inner callable scope locals and expression type resolution
ScriptDocument now tracks locals inside lambdas/function expressions and resolves identifiers by consulting the innermost callable scope before falling back to method/global scope.

Adds expression resolver nodes/type resolver and wires position-aware resolution for lambda bodies, plus basic lambda operator marking and return type validation against expected functional interface SAM.
2026-02-03 07:03:33 +02:00
bigguy345 4e78ffb024 Fix autocomplete trigger after dot 2026-02-03 06:54:09 +02:00
bigguy345 d63a1b8d4c hussar bukkit fixes 2026-02-03 05:50:57 +02:00
Kam 0004029de9 Remove Bukkit from this 2026-02-02 21:54:51 -05:00
Kam 8985ab0f12 Merge branch 'dev' of https://github.com/KAMKEEL/CustomNPC-Plus into dev 2026-02-02 21:51:22 -05:00
Kam 2c6ec0ce34 Better GUI handling for Ability Making System 2026-02-02 21:51:21 -05:00
somehussar 11444946cb Go back to reflections 2026-02-03 03:27:32 +01:00
bigguy345 98351bbc3c dev merge 2026-02-03 04:25:16 +02:00
somehussar fcaf1b0017 Merge remote-tracking branch 'origin/dev' into dev 2026-02-03 03:19:17 +01:00
somehussar 35e76ea9eb gay janino 2026-02-03 03:19:03 +01:00
Kam 38d305ab99 Merge branch 'dev' of https://github.com/KAMKEEL/CustomNPC-Plus into dev 2026-02-02 20:40:19 -05:00
Kam d3167df1b9 Fix to Type Tab 2026-02-02 20:40:17 -05:00
somehussar b5971f258b No class def handling 2026-02-03 02:38:55 +01:00
somehussar e030986d0d gay ass reflections 2026-02-03 02:33:42 +01:00
somehussar 157bbcd3b4 Test 2026-02-03 01:50:09 +01:00
somehussar d8e72b7da8 Fix API jar to only include... just APIs (could probably be minimalized further) 2026-02-03 01:13:39 +01:00
somehussar 650a13edb1 Merge branch 'dev' into kam-cant-make-plugin-integrations-part-2
# Conflicts:
#	dependencies.gradle
2026-02-03 01:10:40 +01:00
somehussar f6342b2335 Fix integration with bukkit and plugins codewise 2026-02-03 01:04:34 +01:00
Kam 0cbc30f8cb Better GUI Handling for Abilities 2026-02-02 18:53:36 -05:00
Kam 911f185400 Fields Builder for Ability GUIs 2026-02-02 18:26:52 -05:00
KamandClaude Opus 4.5 0ff501bb16 Declarative ability GUI: replace 18 SubGui classes with FieldDef system
All ability GUI tabs (General, Target, Effects, Type, Visual) are now
fully declarative via FieldDef definitions. Deleted 18 SubGuiAbility*
classes (~3100 lines) and rewrote SubGuiAbilityConfig to use
GuiScrollWindow for every tab with a unified field renderer.

- Add FieldDef, FieldType, TabTarget, ColumnHint, TabDef gui framework
- Add getFieldDefinitions() to all 18 ability subclasses
- Add getBaseFieldDefinitions() to Ability.java for shared tabs
- Merge COLOR/EFFECTS into SUB_GUI with convenience factories
- Net reduction: ~3100 lines removed

Co-Authored-By: Claude Opus 4.5 <[email protected]>
2026-02-02 16:17:37 -05:00
Kam 3651643f26 Fix GL Issues? 2026-02-02 14:59:55 -05:00
Vidal 335ccd260b Updated translation 2026-02-02 04:48:43 -03:00
Vidal bcc9d790d6 Added Disc Dual animation 2026-02-02 03:00:35 -03:00
Vidal b74149d98d Added Heavy Hit and Cutter animations 2026-02-02 00:52:43 -03:00
Vidal 0369b6de83 oopsie >< 2026-02-01 20:53:12 -03:00
Vidal bc88c88982 Changed animation name reading logic 2026-02-01 20:49:34 -03:00
Vidal 8ae3bcff1c nevermind 2026-02-01 20:44:23 -03:00
Vidal 0883d7fb94 Cast register animation to builtin 2026-02-01 20:39:15 -03:00
Vidal 9d7ad714a1 WIP Animations Register 2026-02-01 20:27:21 -03:00
Vidal b254ad0ba9 WIP Animations Register 2026-02-01 20:25:16 -03:00
Vidal c168702970 WIP Animations Register 2026-02-01 20:09:12 -03:00
Vidal c39ce6b6d1 Fixed sync windup animation not being an ability property and getting overridden on gui init 2026-02-01 17:08:24 -03:00
Vidal b7fdda6905 Updated translation 2026-02-01 06:51:26 -03:00
Vidal f4db57875a Changed dual ability names 2026-02-01 06:45:29 -03:00