Reusing a design using TCastleDesign, TCastleTransformDesign (our equivalent to Unity prefabs)
Channel: Castle Game Engine
Date: 30/09/2022

This video describes TCastleDesign and TCastleTransformDesign components of Castle Game Engine ( https://castle-engine.io/ ). Their purpose is to reuse a design (of UI or transformation) multiple times in other design files.

The relevant documentation:

- The manual chapter: https://castle-engine.io/reuse_design

- API docs of TCastleDesign: https://castle-engine.io/apidoc/html/CastleControls.TCastleDesign.html
- API docs of TCastleTransformDesign: https://castle-engine.io/apidoc/html/CastleTransform.TCastleTransformDesign.html

In this video I used graphics done by:

- Slava Z. from https://sketchfab.com/3d-models/pony-cartoon-885d9f60b3a9429bb4077cfac5653cf9
- Ironthunder from https://opengameart.org/content/markeus-b-ui-buttons

Chapters:

0:00 Introduction
1:15 Using TCastleDesign to reuse a custom button (with extra label and extra image) design
14:52 Using "New User Interface - Custom Root - ..."
16:04 Creating TCastleDesign without drag-and-drop
17:23 Context menu of TCastleDesign
17:50 Edit Referenced Design
21:16 Revert To Referenced Design
22:28 Using TCastleTransformDesign to reuse a car
33:30 Using TCastleDesign to reuse a viewport, which has other designs