New update time! This one’s more focused on stablization and new options for CASP itself. This was nice to finally get properly into a dev rythym and polish a lot of small papercuts or implement ideas that will help quite a bit! I’m also glad the unstable branch got some proper use.
We’re nearing the end of this Castagne cycle, bit by bit. Next up: flow and AI! And then it’s off to make the big passage to Godot 4, only on Unstable for a good while.
TLDR
- S Branches are now easier to use, especially for attacks with
SATK
- E Branches and Events have now been added, expanding possibilities. Attack flow now uses this.
- R Branches now allow random
- Many bugfixes!
Breaking changes
If you used the previous system for OnHit behavior and the like, you’ll need to update it to use events now.
Full Changelog
- CASP:
- S Branches:
- S Branch Dynamic Modulo: Can now just use an S branch with a
%
but no number after the modulo (e.g. S10%:
) will compute it automatically (was already present but I don’t know if it was written in a CL before)
- S Branch End: Can now add a
then
after the main part of an S branch part to do an action on the last frame
- S Branch Automatic Attack Duration: Can use
SATK
instead of S
at the start to automatically add an AttackDuration
function at the start of the branch.
- E Branches: New branch type that can be easily called back from external triggers, and easily modified.
- Compiler tool now can display Events
- Can add code to several events at once with
,
(e.g. EOnHit,OnBlock:
)
- Added Events:
DefenderAttackOverrides
, OnAttackHit
, OnAttackBlocked
, OnGetHit
, OnBlocking
.
- Can override previous Event code by adding
*
at the end of an event name.
- Added
Enter
and Exit
events
- Added a
Landing
event. Some states now use that, but full transition will be done in a later update.
- Added a
Liftoff
flag and event, active when the previous frame is grounded and this one airborne.
- P Branches:
- Small bugfix / optimization in how they are implemented, now they act like native code.
- Allowed several phases at once with
,
(e.g. PAction,Reaction:
)
- R Branches: New branch type for random choice. Syntax is of the form
R[Weight]:
for the first and R[Weight]
for others. Will pick one of the branches according to the ration between its weight to the total weights of the branch. Non-deterministic at the moment.
- Attacks:
- Base CASP changes: now uses events. All behavior was moved into the
AttackReactEvents
states.
- Overrides now go through the same event whether attacking or blocking.
- An attack being blocked now has the
Blocked
attack flag.
- Clashes now are handled through the
OnAttackHit
event. Clashes now have the Clashing
attack flag.
- Attacks now reset through the Enter event instead of frame 1.
Launcher
attack flag is now added automatically to an attack with upwards momentum.
- Added
OTG
as an attack override on OTG attacks
- Editor
- Updater:
- Updater now displays build date and time.
- Updater can now force an update or a reinstall of Castagne, removing the need to do it manually
- Updater now explains the error when it happens
- Editor can now delete a subentity easily by deleting it’s base block.
- Editor now displays version properly on the main menu and top bar, along with build date and branch
- Improved the Overriden state default text
- Fixed editor not adding CallParent to the called state list
- Editor now registers input during frame advance
- Editor now has a button to join the Discord community directly
- Misc:
- Added TransitionToFrame which allows starting a state at a later frame.
- VFX now pauses by default during hitstop (adjustable in graphics specblock)
- Can now disable automatic Z-Order in graphics specblock
- Added new attack template using S branches
- Compiler now catches missing endifs
- Compiler now catches when you forget the
:
at the end
- Increased default pixelsize for sprites to adjust with the new pixelsize values
- Added the ability to lock VFX to entities, enabled by default
- Hits now register their boxes overlap
- General Bugfixes: Some of these reports were old, so a CNR probably has been fixed in a previous build (or might have been a project-specific issue).
- Graphics:
- 3D Sprites were using the 2D shader, and color correction was wrong.
- Fixed wrong color correction on 3D sprites
- Fixed on hit and on block VFX not appearing by default. Can be disabled by overriding VFXHit and VFXBlock.
- Fixed a gizmo bug for VFXModelCreate and VFXSpriteCreate
- Fixed VFX animation players playing during freeze / pause
- Fixed sprite VFX in 3D not appearing at the correct position
- Engine doesn’t crash when using an invalid VFX animation player path
- Fixed first frame of hitstun / blockstun animation not activating
- CNR: UI Mirroring not working + UI scaling being improper
- CNR: UI mirroring / scaling issues
- Physics:
- 2D physics were having bugs.
- Fixed not being able to block during an air jump (can be turned off manually by overwriting)
- CNR: Infinite Airdashes
- CNR: Airdash freaking out
- WON’T FIX: Invul / Guard flags don’t work. This has been replaced by
HitboxRequires
and similar functions.
- Other:
- Fixed engine crash when some motion inputs are enabled and a direction is held on startup (thanks mrgoodtimehaver for this fix!)
- Fixed deleted entities sometimes crashing the engine (especially with VFX)
- CNR: Holding a keyboard key after reload crashes castagne editor
- WON’T FIX (for now): Using
GetAttackParameter
with an existing character variable name doesn’t work. Will be naturally fixed when working on the compiler.
- WON’T FIX (for now): Hot Reload can crash engine when having errors. Filing this under “skill issue lol” since editor is going to be reworked
- Known issue: Long freeze make the engine lag. Probably input related ? But long to analyze/fix so unless someone gets on this case I’ll leave it for the v0.6x cycle.