udpate to dnd
This commit is contained in:
parent
eb80e825e2
commit
347619eae6
18
README.org
18
README.org
|
@ -5461,6 +5461,13 @@ Using emacs to run rpg things
|
|||
(add-to-list 'load-path "/home/chris/dev/emacs-rpgdm/")
|
||||
(use-package rpgdm
|
||||
:config
|
||||
|
||||
(defun chris/dnd-get-table (table range)
|
||||
"Get a list of the contents of any `table' and use `range' to get the info"
|
||||
(with-current-buffer
|
||||
(find-file-noselect "~/docs/notes/20240804T132141--dungeons-and-dragons__area_fun_personal.org")
|
||||
(org-table-get-remote-range table range)))
|
||||
|
||||
(defun chris/dnd-skill-check (&optional skill)
|
||||
"Roll for a skill check using skill or prompting for one."
|
||||
(interactive)
|
||||
|
@ -5481,7 +5488,12 @@ Using emacs to run rpg things
|
|||
skill skills
|
||||
:test 'string=))
|
||||
skills))))
|
||||
(message value)))
|
||||
(rpgdm-roll (concat "1d20" value))))
|
||||
|
||||
(defun chris/dnd-spell-attack-check ()
|
||||
"roll for a spell attack"
|
||||
(interactive)
|
||||
(rpgdm-roll "1d20+9"))
|
||||
|
||||
:general
|
||||
(chris/leader-keys
|
||||
|
@ -5489,7 +5501,9 @@ Using emacs to run rpg things
|
|||
:keymaps 'override
|
||||
"a" '(:ignore t :which-key "RPGDM")
|
||||
"ar" '(rpgdm-roll :which-key "roll")
|
||||
"aa" '(hydra-rpgdm/body :which-key "hydra")))
|
||||
"aa" '(hydra-rpgdm/body :which-key "hydra")
|
||||
"as" '(chris/dnd-skill-check :which-key "check skill")
|
||||
"ap" '(chris/dnd-spell-attack-check :which-key "Spell attack")))
|
||||
#+end_src
|
||||
|
||||
** Performance
|
||||
|
|
18
init.el
18
init.el
|
@ -4020,6 +4020,13 @@ interfere with the default `bongo-playlist-buffer'."
|
|||
(add-to-list 'load-path "/home/chris/dev/emacs-rpgdm/")
|
||||
(use-package rpgdm
|
||||
:config
|
||||
|
||||
(defun chris/dnd-get-table (table range)
|
||||
"Get a list of the contents of any `table' and use `range' to get the info"
|
||||
(with-current-buffer
|
||||
(find-file-noselect "~/docs/notes/20240804T132141--dungeons-and-dragons__area_fun_personal.org")
|
||||
(org-table-get-remote-range table range)))
|
||||
|
||||
(defun chris/dnd-skill-check (&optional skill)
|
||||
"Roll for a skill check using skill or prompting for one."
|
||||
(interactive)
|
||||
|
@ -4040,7 +4047,12 @@ interfere with the default `bongo-playlist-buffer'."
|
|||
skill skills
|
||||
:test 'string=))
|
||||
skills))))
|
||||
(message value)))
|
||||
(rpgdm-roll (concat "1d20" value))))
|
||||
|
||||
(defun chris/dnd-spell-attack-check ()
|
||||
"roll for a spell attack"
|
||||
(interactive)
|
||||
(rpgdm-roll "1d20+9"))
|
||||
|
||||
:general
|
||||
(chris/leader-keys
|
||||
|
@ -4048,7 +4060,9 @@ interfere with the default `bongo-playlist-buffer'."
|
|||
:keymaps 'override
|
||||
"a" '(:ignore t :which-key "RPGDM")
|
||||
"ar" '(rpgdm-roll :which-key "roll")
|
||||
"aa" '(hydra-rpgdm/body :which-key "hydra")))
|
||||
"aa" '(hydra-rpgdm/body :which-key "hydra")
|
||||
"as" '(chris/dnd-skill-check :which-key "check skill")
|
||||
"ap" '(chris/dnd-spell-attack-check :which-key "Spell attack")))
|
||||
|
||||
;; Reduce rendering/line scan work for Emacs by not rendering cursors or regions
|
||||
;; in non-focused windows.
|
||||
|
|
Loading…
Reference in a new issue