v0.5.0 — Blazing-fast ct.place, game packer, code completions and more!
And here comes a shiny-new update to ct.js! This update aims towards making ct.js both feature-rich and highly efficient.
ct.place optimizations
The most important change comes to ct.place: it got a bunch of optimizations and now works much, much faster.
The previous approach just took a list of all the copies and collided them one against another, until it finds something. The new approach splits the map into rectangular chunks, and each copy or tile is stored inside 1-4 of these chunks. Copies collide with only those objects that belong to their own chunk. This makes collisions faster and allows games to scale greatly if the size of a single copy is much smaller than the whole map (and in most games, it is).
You will hardly notice any difference if your game has a low quantity of copies, or they are sparsely placed across the map (e.g. in space simulators). For other games, this is a huge speed boost.
These changes to ct.place will require a bit of config. The default values (512x512) will be set to your projects, but you might need to tweak them for better results.
UI Tab and Fonts Manager
The Styles tab was renamed to UI, as it now manages both styles and fonts. You can now bundle custom .ttf fonts with your games, so you get both unique and uniform look across different devices.
Game Packer
You can now export your games as executables for all the major platforms! Just click the menu button on the top-left corner. Supports Windows 7+, Linux and Mac.
Future improvements of this feature will include custom icons and advanced settings.
EQS
EQS stands for Environment Querying System. It is a system that allows your copies to get information about the world that surrounds them, interpret it as points, and then pick the best points suitable for your task.
This can be used in different situations:
- to help enemies' AI pick the best cover spots nearby;
- to create believable pirate battles;
- to place pickups and collectibles on procedurally-generated map segments;
- to drive AI movement in a top down, or even side-view world;
- and more!
This is an experimental feature, though, so it may contain bugs. Beware!
Multi-tile Editing
Have you ever drawn a ton of tiles only to realize you placed them on a wrong layer? I did, so I added a multi-tile editing. You can now shift tiles in groups, delete them, or move to another layer.
These were most notable and important changes. I hoped I could do more, but due to the lack of time and some unforeseen events I had to postpone some features. Multi-tile editing should have come with multi-copy manipulations, and EQS comes in an untested form. I planned autocompletions for modules, too, but for now it will be for the core library only. In any way, I did quite a lot of work that shouldn't lay in silence on my laptop for months, too.
If you face any bugs, please contact me at Discord or at the itch-based community!
Changelog
⚡ General Improvements
- Add a /*%commented%*/ format for modules' configurable fields, as an alternative to the %standard% one.
- Improvements to ct.place: greatly improve speed for ct.place.occupied, ct.place.free, ct.place.meet, ct.place.tile. Make x and y parameters in most functions optional. The new variant is now preferred (e.g. ct.place.occupied(this, 'Solid'); )
- Little performance optimizations for drawing
- Make a small transition to a prototype-based system. Introduce
this.draw
,this.move
andthis.addSpeed
calls on copies. - More zoom levels in the room editor
- Refactor ct.types, move actual types to ct.types.templates
- Reuse of metadata in ct.js and exported projects
✨ New Features
- Add a font manager
- Add a Reimport button to imported graphics assets
- Add ct.js autocompletions for code editors
- Add ct.u.deltaDir, ct.u.lerp, ct.u.unlerp, ct.u.clamp, and ct.u.inspect
- Add multi-selection for tiles
🐛 Bug Fixes
- Fix ct.place.nearest and ct.place.furthest
- Fix drawing copies with graphics offsets in the room editor
- Fix incorrect export of tilesets with non-square grids
📝 Docs
- Add a notice about location of catmods' docs
- Visually better tips in tutorials and minor changes
⚗ Experimental
- Add ct.eqs and ct.victoria catmods
- Project exporter
💬 Misc
- Add a link to Patreon
- Add links to Twitter, Discord and VK to the starting screen
Updates to Game Jam Sources and site are coming soon!
Happy coding!
Comigo
Files
Get Ct.js game engine
Ct.js game engine
Create cool 2D games with a free game maker!
Status | In development |
Category | Tool |
Author | Cosmo Myzrail Gorynych |
Tags | 2D, ctjs, gamedev, game-development, Game engine, GameMaker, html5, javascript, Moddable, nwjs |
Languages | German, English, Spanish; Castilian, French, Romanian Moldavian Moldovan, Russian, Ukrainian, Chinese (Simplified) |
Accessibility | High-contrast |
More posts
- Announcing the 4th ct.js game jam!25 days ago
- v5.1.0 — Enumeration asset type, asset searchbar, and QoL improvements49 days ago
- v5.0 releases with a visual programming language Catnip!85 days ago
- Ct.js v4.0.1 — minor bug fixes and improvementsFeb 18, 2024
- Ct.js v4.0.0 — more than a year worth of work with hundreds of new features an...Feb 10, 2024
- Ct.js v3.3.0Dec 13, 2023
- v3.2.0 — Support for CoffeeScript, a simple, easy to write language that can d...Dec 25, 2022
- Work in progress: CoffeeScript in ct.js!Nov 20, 2022
- v3.1.0 — TypeScript support, multiple ct.js windows support, translations, and...Nov 08, 2022
Leave a comment
Log in with itch.io to leave a comment.