# WorldEditor for game

**URL:** https://forum.castle-engine.io/t/worldeditor-for-game/1242
**Category:** Game Design
**Created:** [June 21, 2024, 7:41am UTC](https://forum.castle-engine.io/t/worldeditor-for-game/1242 "2024-06-21T07:41:24Z")
**Posts on this page:** 3
**Page:** 1

<div class="post-metadata">

### Author: ![Noscow](https://forum.castle-engine.io/user_avatar/forum.castle-engine.io/noscow/32/964_2.png) [@Noscow](https://forum.castle-engine.io/u/Noscow)
#### Post date: [June 21, 2024, 7:41am UTC](https://forum.castle-engine.io/t/worldeditor-for-game/1242/1 "2024-06-21T07:41:24Z")

</div>

Good day!  
There is the small (or not) question I have.  
I need to make the editor for game resources like game objects, game global map and scenes. Like the map editor for strategy games, where you can draw terrains, add units etc… Important feature - non-code and player-friendly design. So:

1. I think will be better, if I make it as the single program and don’t integrate in game. Like StarEdit, WarCraft 3 World Editor or TES Construction Set. Is it good way, or game-integrated level editor has a right to exists?
2. If it will be as special program, I need to add them in the game folder and give them access to game units, contains game object classes? Is it practice safe and good? Another idea - make absolutely independent editor with own classes, because editor don’t need full list of “real” game objects. But it will still result in a partial repetition of the code.
3. I think LCL will be enough for this project, moreover LCL components will be very helpful for editor interface designing. Or better to use game engine (maybe I overlook some important detail…)?

I understand that is questions about the own view to the design, but I am interested you opinions and experience. Thanks for attention!

---

<div class="post-metadata">

### Author: ![michalis](https://forum.castle-engine.io/user_avatar/forum.castle-engine.io/michalis/32/3_2.png) [@michalis](https://forum.castle-engine.io/u/michalis)
#### Post date: [June 25, 2024, 5:36pm UTC](https://forum.castle-engine.io/t/worldeditor-for-game/1242/2 "2024-06-25T17:36:42Z")

</div>

Overall, it’s a broad question and likely various answers can be valid – depending on needs 🙂

Let me share some of my thoughts:

1. _If_ I would decide to make my own game editor, I would definitely plan from start to share some code with the actual game. While surely there will be some things game-specific and editor-specific, in my experience there’s also a nice “common set” of things useful for both editor and game. You want single language, single data structures, single code for them, to save yourself some work.

2. Connecting to the above, I would consider making such editor a “core” part of the game project. So that you can interrupt the “game mode” essentially at any moment and switch into “editor designinig mode” and then of course, once you edit some stuff, jump quickly into “play mode” again. This is the main advantage of making a home-grown, custom editor IMHO – you can make the experience really “seamless” for players and the editor becomes an essential game part.

3. The above also implies that I would then try to make the whole editor just like the game, so using CGE UI classes ( [User Interface | Manual | Castle Game Engine](https://castle-engine.io/user_interface) ), not LCL.

4. Note: If I would not want to give end-players access to editor, I would consider instead making it:

5. I would go for LCL only if LCL has some specific ready control that I desperately need and I cannot make it easily in CGE 🙂

I guess it all comes also into “what do you know” 🙂 For me surely the choice of “making all user interface using CGE components” would be nice, as even if something is missing in CGE – I would like to add it (like a TCastleTreeView, planned). But this is then something I would consider a gain (I’m doing a project, I’m also improving CGE), it may be different for you, I understand you should naturally choose something that you already know well, and you already know it satisfies all your requirements.

I hope this helps as food for thought! 🙂

---

<div class="post-metadata">

### Author: ![Noscow](https://forum.castle-engine.io/user_avatar/forum.castle-engine.io/noscow/32/964_2.png) [@Noscow](https://forum.castle-engine.io/u/Noscow)
#### Post date: [June 27, 2024, 8:20am UTC](https://forum.castle-engine.io/t/worldeditor-for-game/1242/3 "2024-06-27T08:20:16Z")

</div>

Thank you, the information is very useful!
