Ed 2.23 is out - Fri, Sep 20, 2024
Ed 2.23 is out on Steam. These are the new features and changelog for this build. I started writing changes on Post-its and I plan to collect them for every release to compile a changelog. Old school methods seem faster than loading Trello/Jira’s JavaScript!
Changelog
- CameraTarget flag: Make camera move and focus on this tile*.
- TileDef list sort: Sort by Ref, Handle or default.
- Draw borders around tiles of the current board (CTRL+G to toggle)
- Duplicate Ref finder assistant: Find assets with the same Ref and quickly rename them to unique values
- Fix bugs related to Rule Brush, Folder and TileDef management
- Fix undo drawing making the camera jump to 0,0.^
- Make undo drawing faster.^
- Make zooming in and out with scroll wheel smoother.
- Zoom and move the camera to cursor.
- Circle brush with size 3 is + instead of a square.
- Fix issues with animations and optimize drawing performance.
- Announcer UI and chimes
- IsPlayer TileDef flag
- Performance improvement: Don’t run polish on tiles that are being drawn
- Refactor renderer
- Pan camera with space bar
- CTRL+D to deselect
- Export animations to Unity and play them*
- Export collisions to Unity*
- Flag to clone TileDef per tile on runtime or use static (shared) data
- New animation code in Editor and Unity*
- CTRL+S to save
- Annotation TileDef flag: Ignore exporting/spawning sprites in game*
- Unity tile Become()*
- Unity tile Mimic()*
- Tile-level collision inheritance*
- Board-level collision override*
- Draw colliders*
- Duplicating assets assigns unique Refs
- Gravity multiplier*
- Rotation and position locks*
- Physics simulation mode per TileDef (with export to Unity RigidBody2D)*
- Propagate colliders to all TileDefs of a Rule Brush
(*Unity Experimental)
(^Known issues exist when undoing draws)
KiloTexture - OptimizedWall
Unity integration is coming along, with a focus on making a 2D platformer game mode work. I added a specific TileDef flag named OptimizedWall, which separates colliders from sprites, batches sprites into 2048x2048 pixels (or smaller) textures and draws those bigger textures instead of spawning small tiles individually. I’m tempted to call it KiloTexture as an homage to idTech’s MegaTexture.
The colliders are run through a merging algorithm that returns polygons of the union of rect colliders, and those polygons are spawned as Polygon Collider 2Ds in Unity.
Animated tiles are excluded from this process and are rendered separately.
Unity Export
Another challenge is to find the most optimal way to store data for Unity. Currently I’m writing data as code, because it’s fast at runtime, and can be accessed in any way they want by the programmer, git friendly, and readable. However, Unity Editor tends to re-compile scripts every time they change, and these large source files make the development and debug cycle slow, so I might move data out to resource files.
This is how large the main data source file is.
On another note, spawning a medium-sized level at edit times and saving the Unity scene file makes the scene file as large as 500 MB or more, and that already categorizes the file as LFS by Github. What’s the point of making things text-based if they aren’t properly handled by Git? So I think I should rethink how I’m serializing data in general.
Games
The main reason I’m focused on Unity integration and specifically on making the 2D platformer thing work is, if I can reduce the development to release cycle of an okay 2D platformer down to a month or so, Ed can be used at game jams to make platformers, and meanwhile I can bring artists in to create a game per month, early 90s style. We’ll see how it goes.