**Language / Langue :** [[fr:editeur:presentation|FR]] | **EN** ====== Graphical editor - Overview ====== The graphical editor lets you create JDR-Bot scenarios without writing YAML by hand. ===== Starting the editor ===== * **Web**: the //Editor// button in the site header. * **Desktop**: the //Editor// button in the application. ===== Main interface ===== The editor is split into several areas: * **Graph** (centre) - a visual map of every room and their connections * **Inspector** (right panel) - detailed editing of the selected room * **Globals panel** - variables, global events, permanent timers, aliases * **Toolbar** (top) - Test, Linter, Export, Undo/Redo and Save buttons Two windows open on demand from the **View** menu: * **Text formatting** (''Ctrl+M'') - inserts the text syntaxes into the field you are editing * **Quick search** (''Ctrl+K'') - reaches a room, an event, an object, or runs an action ===== Editor profiles ===== **View > Open Editor Profile** selects the fields shown in the inspector: * **Simplified** - hides the advanced fields, for a first scenario * **Essential** - the common features, without the rare settings * **Expert** - every field visible, for complex scenarios * **Custom** - you pick the families to display * **Discord** and **Terminal** - only keep what these platforms can really display The two platform profiles hide, for instance, videos and image buttons on Terminal, or video on Discord. **Changing profile never modifies the scenario**: incompatible features already written are kept, and the profile window lists them with their location. ===== Text formatting window ===== It gathers every text syntax of the engine, sorted into five groups: formatting, variables and style, media, interactive elements and story blocks. Each button shows the name of the feature and a preview of what will be inserted. Its behaviour depends on your selection: * **Selected text** is wrapped by the syntax. Select a word, click //Variable//, you get ''v_word_v''. Paste an address, click //Image//, it is wrapped. * **With no selection**, the syntax appears around a sample word, itself selected so you can replace it right away. * When you supplied the text yourself, the **remaining parameter** is preselected instead: the identifier of an event, the slicing of a tile. Spaces sitting at the edge of a rough selection stay outside the syntax, and a story block always starts on a clean line. The window stays open while you write: it follows the active field. ===== Generate rooms ===== **Tools > Generate rooms...** prepares a route using one of six structures. The result opens in a separate tab: fill in the text, test, then import the rooms you want into your scenario. See [[en:editeur:generation|Room generation]] for settings, directions, numbered choices and optional models. ===== File formats ===== The editor works with the ''.jdrproj'' format (internal JSON). It can: * **Import** an existing ''.yaml'' file (''File > Import YAML'') * **Export** to ''.yaml'' (''File > Export YAML'') * **Export** to standalone HTML5 or to a PDF gamebook ===== Undo / Redo ===== Fifty undo levels. Shortcuts: Ctrl+Z / Ctrl+Shift+Z (or Ctrl+Y). When enabled and a save path exists, automatic file saving runs every five minutes. The local Web draft keeps the main scenario; save generated tabs separately as ''.jdrproj''. The editor uses its own confirmations when closing a document or changing scenarios, without adding the browser's native confirmation. Save your tabs before leaving or reloading the page. ===== Palettes and visual styles (v4.10) ===== The game interface and the editor come with **palettes** (colors) and **styles** (layout), freely combinable. ^ Palette ^ Description ^ | ''sombre'' | Dark background, high contrast (default) | | ''neutre'' | Neutral grey, with no color cast | | ''clair'' | Light background, for daytime reading | | ''bonbons'' | Colorful and soft, meant for children and sensitive eyes | | ''reverie'' | Calm pastel blue, mint and pink, a soothing mood | ^ Style ^ Description ^ | ''classique'' | Clean and readable, plain typography | | ''rpg'' | Fantasy atmosphere | | ''terminal'' | Monospace, terminal mood | | ''aventure'' | Narrative typography, novel-like layout | | ''bonbons-s'' | Rounded, playful, child-friendly style | | ''reverie-s'' | Soft and airy gamebook | Palettes carry the colors, styles carry the layout: they combine freely. ===== Room groups (v4.10) ===== Groups organise the rooms visually inside the graph, with no effect on the exported YAML. * View menu > **Manage groups...** lists every group with its number of rooms * Renaming a group to an existing name offers to **merge** the two * Groups are purely visual: no impact on gameplay or on the export ===== Room order and numbering (v4.10) ===== * The room list shows the **exported number** next to the identifier (''1 - start'', ''2 - corridor''...) * **Drag and drop** in the list changes the YAML export order * Typing a number in the Position field moves the room and renumbers the others consistently ===== Data and controls (4.17) ===== Web/Desktop forms support [[en:yaml:listes-boucles|lists, collections and loops]] and [[en:yaml:raccourcis|keyboard, mouse and gamepad shortcuts]]. Large projects use pagination and search to limit the number of displayed fields. During a test, **Test data** opens current values in a separate window. Diagnostics open the relevant field: see [[en:editeur:linter-export|Linter and author tests]]. ===== Models, objects and HUD panels ===== In a [[en:yaml:modeles|model]] definition, insertion into the calling room corresponds to ''inline: true'' and requires one internal room. Each generic collection can also provide defaults for missing properties. In [[en:yaml:objets|objects]], **Display name** is folded when empty. **Secret item**, near the location, simplifies the form while retaining furniture description and button. Hidden fields keep their values. **Rename an item**, in the Objects effect family, has separate object and new display-name fields; an empty value restores the identifier. Every [[en:yaml:hud|HUD panel]] offers **Clear when leaving the room**, unchecked by default. It exports ''scope: room''; omitting scope preserves the historical persistent behaviour. These settings support undo/redo and FR/EN YAML import/export. [[en:yaml:listes-boucles|Structured data]] supports descriptions at every level and tags on roots. Names, values and descriptions remain grouped in the same form.