A stable modding interface between Techblox and mods https://mod.exmods.org/
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

UserPrompts.cs 1002B

123456789101112131415161718192021222324252627
  1. using System;
  2. using HarmonyLib;
  3. using RobocraftX.Services;
  4. namespace GamecraftModdingAPI.App
  5. {
  6. public class DualChoicePrompt : MultiChoiceError
  7. {
  8. public DualChoicePrompt(string errorMessage, string title, string firstButtonText, Action firstButtonAction, string secondButtonText, Action secondButtonAction) : base(errorMessage, firstButtonText, firstButtonAction, secondButtonText, secondButtonAction)
  9. {
  10. // internal readonly field smh
  11. new Traverse(this).Field<string>("Title").Value = title;
  12. }
  13. }
  14. public class SingleChoicePrompt : SingleChoiceError
  15. {
  16. public SingleChoicePrompt(string errorMessage, string buttonText, Action buttonClickAction) : base(errorMessage, buttonText, buttonClickAction)
  17. {
  18. }
  19. public SingleChoicePrompt(string titleText, string errorMessage, string buttonText, Action buttonClickAction) : base(titleText, errorMessage, buttonText, buttonClickAction)
  20. {
  21. }
  22. }
  23. }