As for TCastleWindow
and TCastleWindowBase
:
They are indeed not available on the component palette. You should create an instance of TCastleWindowBase
(or TCastleWindow
) by code. The window created this way does not use Lazarus LCL forms. The initial pages of the manual (like https://castle-engine.io/manual_window.php ) describe both the process of using TCastleWindowXxx
and TCastleControlXxx
.
You can use either TCastleWindowXxx
and TCastleControlXxx
, both approaches work 100%. I advise using TCastleWindowXxx
if you only want a simplest window that displays the game. Use TCastleControlXxx
if you want to mix CGE rendering with other LCL forms and visual components.
As for creating scene manager:
-
Indeed if you use
TCastleControlBase
(instead ofTCastleControl
) then it will not have a scene manager. You can trivially create it yourself, by doingSceneManager := TCastleSceneManager.Create(Application); CastleControl1.Controls.InsertFront(SceneManager);
I advise doing this (instead of using
TCastleControl
that already created scene manager for you) in future code.This gives you more flexibility. This way you create scene manager just like all others 2D user interface controls (https://castle-engine.io/manual_user_interface_and_2d_drawing.php ), you can also design it using CGE editor (https://castle-engine.io/manual_editor.php – we heavily work on it, to allow designing there user interface stuff, and 2D and 3D worlds inside scene manager).
-
A similar situation is with TCastleWindowBase and TCastleWindow. TCastleWindow just has a scene manager created automatically. I advise now using TCastleWindowBase, and doing it yourself.
-
The manual is indeed not yet updated to show the approach of TCastleControlBase/TCastleWindowBase (and manual creattion of TCastleSceneManager). Most of the manual and examples instead show usage of TCastleControl/TCastleWindow. I plan to fix this ASAP
Sorry for confusing, I should have mentioned it earlier.