Skip to content
| Marketplace
Sign in
Visual Studio Code>Other>SAMP dialog editorNew to Visual Studio Code? Get it now.
SAMP dialog editor

SAMP dialog editor

il_kol

|
137 installs
| (0) | Free
Provides the ability to view a preview of the SAMP dialog
Installation
Launch VS Code Quick Open (Ctrl+P), paste the following command, and press enter.
Copied to clipboard
More Info

samp-dialog-editor

  • English
  • Русский

en

A VSCode extension that provides a SAMP dialog editor.

Preview

  • Features
  • Usage
  • Defines
  • Known Issues
  • Plans

Features

  • Preview of SAMP dialogs inside VSCode.

Usage

  1. Open the command palette (Ctrl + Shift + P or Cmd + Shift + P on macOS).
  2. Run the command: Open SAMP dialog editor
  3. The editor will open in a new panel.
  4. Fill out the form
  5. Click button Draw. Or click Auto draw button to activate automatic drawing for any change.

Defines

The editor supports the ability to use replaceable constants from the code (define) inside the dialog. To add a constant, you must:

  1. Click the button at the bottom of the Defines form
  2. Add a pattern key that will be replaced
  3. Add the value to be inserted instead of the key in the text. The editor does not check your dialog code! To study in detail the work of the #define preprocessor command in Pawn in order to avoid mistakes. It is also worth considering the order in which constants are declared.:

❌ Incorrect order: | Ключ | Значение | | ---------- | ------------- | | WHITE | "{ffffff}" | | RED | "{ff0000}" | | MENU_ITEM | "RED"-"WHITE" |

✅ Correct order: | Ключ | Значение | | ---------- | ------------- | | MENU_ITEM | "RED"-"WHITE" | | WHITE | "{ffffff}" | | RED | "{ff0000}" |

The constants are saved when restarting both the dialog editor and the VSCode application as a whole.

Defines panel screenshot

Known Issues

  • SAMP dialog sizes and preview sizes do not match
  • Difference between preview and SAMP fonts

Plans

  • Add real time preview update
  • Separate preview from form
  • Collaborate with The Pawn Language extesnsion
  • Export finished dialog code

Ru

Расширение VSCode, предоставляющее редактор диалогов SAMP.

Превью

  • Возможности
  • Использование
  • Автозаменяемые константы
  • Известные проблемы
  • Плнаы

Возможности

  • Предпросмотр диалогов SAMP внутри VSCode.

Использование

  1. Открой Command palette (Ctrl + Shift + P или Cmd + Shift + P на macOS).
  2. Выполните команду: Open SAMP dialog editor
  3. В редакторе откроется нове окно
  4. Заполните форму
  5. Нажмите кнопку Draw либо Auto draw, активирующую автоматическую отрисовку при любом изменении

Константы

Редактор поддерживает возможность использовать заменяемые константы из кода (define) внутри диалога. Чтобы добавить константу необходимо:

  1. Нажать кнопку снизу формы Defines
  2. Добавить ключ-паттерн, который будет заменятся
  3. Добавить значение, которое будет вставлено замето ключа в текст Редактор не проверяет ваш код диалога! Подробно изучить работу команды препроцессора #define в Pawn, чтобы не допускать ошибок. Также стоит учитывать порядок объявления констант:

❌ Неверный порядок: | Ключ | Значение | | ---------- | ------------- | | WHITE | "{ffffff}" | | RED | "{ff0000}" | | MENU_ITEM | "RED"-"WHITE" |

✅ Верный порядок: | Ключ | Значение | | ---------- | ------------- | | MENU_ITEM | "RED"-"WHITE" | | WHITE | "{ffffff}" | | RED | "{ff0000}" |

Константы сохраняются при перезапуске как редактора диалогов, так и приложения VSCode в целом.

Скриншот панели дефайнов

Известные проблемы

  • Размеры диалогового окна в SAMP и превью различаются
  • Различие шрифта в диалогах SAMP и шрифта расширения

Планы

  • Взаимодействие с расшиернием The Pawn Language
  • Экспорт готового кода диалога

Examples

MSGBOX https://i.postimg.cc/zG1NM1d4/image.png INPUT https://i.postimg.cc/yYC08vvc/image.png PASSWORD https://i.postimg.cc/N0jzPgXs/image.png

  • Contact us
  • Jobs
  • Privacy
  • Manage cookies
  • Terms of use
  • Trademarks
© 2025 Microsoft