Skip to content

Commit

Permalink
refactor: use Nim code to add commands related to stories
Browse files Browse the repository at this point in the history
FossilOrigin-Name: 52a72f2724a3bb2b54250faafb70652fe93ba9b5b9bcd1f3844e74ac93f5731b
  • Loading branch information
thindil committed Oct 3, 2024
1 parent d4193fa commit bded398
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 6 deletions.
7 changes: 3 additions & 4 deletions nim/src/ui/knowledgestories.nim
Original file line number Diff line number Diff line change
Expand Up @@ -173,9 +173,8 @@ proc setStoryCommand(clientData: cint; interp: PInterp; argc: cint;
proc addCommands*() {.sideEffect, raises: [], tags: [WriteIOEffect, TimeEffect].} =
## Adds Tcl commands related to the list of known stories
try:
discard
# addCommand("ShowStory", showStoryCommand)
# addCommand("ShowStoryLocation", showStoryLocationCommand)
# addCommand("SetStory", setStoryCommand)
addCommand("ShowStory", showStoryCommand)
addCommand("ShowStoryLocation", showStoryLocationCommand)
addCommand("SetStory", setStoryCommand)
except:
showError(message = "Can't add a Tcl command.")
2 changes: 0 additions & 2 deletions src/ui/knowledge.adb
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,6 @@
with Interfaces.C;
with CArgv;
with Tcl;
with Knowledge.Stories;
with Utils.UI;

package body Knowledge is
Expand Down Expand Up @@ -73,7 +72,6 @@ package body Knowledge is
Add_Command
(Name => "KnowledgeMaxMin",
Ada_Command => Knowledge_Max_Min_Command'Access);
Knowledge.Stories.Add_Knowledge_Stories_Commands;
end Add_Commands;

end Knowledge;

0 comments on commit bded398

Please sign in to comment.