summaryrefslogtreecommitdiff
path: root/src/wasp-user-talents.el
diff options
context:
space:
mode:
authorLLLL Colonq <llll@colonq>2026-04-26 23:47:18 -0400
committerLLLL Colonq <llll@colonq>2026-04-26 23:47:18 -0400
commit75e005e81b73d8471f16dc5fad7bbdc312bdbfe7 (patch)
tree1ad7d61b04c44fc52b453aef44868a42012f3551 /src/wasp-user-talents.el
parentcf266a56f30daae8b9af7c9bc3267c61b1973192 (diff)
Diffstat (limited to 'src/wasp-user-talents.el')
-rw-r--r--src/wasp-user-talents.el27
1 files changed, 27 insertions, 0 deletions
diff --git a/src/wasp-user-talents.el b/src/wasp-user-talents.el
new file mode 100644
index 00000000..8b251c9f
--- /dev/null
+++ b/src/wasp-user-talents.el
@@ -0,0 +1,27 @@
+;;; wasp-user-talents --- skills and perks and talents -*- lexical-binding: t; -*-
+;;; Commentary:
+;;; Code:
+
+(require 'wasp-utils)
+(require 'wasp-db)
+
+;; talent:name -> hashmap from tids to names
+;; talent:desc -> hashmap from tids to description
+;; talent:icon -> hashmap from tids to image bytes
+(defun w/talent-create (tid name desc iconpath)
+ "Create a new talent TID called NAME with DESC and ICONPATH."
+ (let ((icon (or (f-read-bytes iconpath) (error "Failed to open icon path: %s" iconpath))))
+ (progn
+ (w/db-hset "talent:name" tid name)
+ (w/db-hset "talent:desc" tid desc)
+ (w/db-hset "talent:icon" tid icon))))
+
+;; (w/talent-create "bigjoel" "Bigger Joels" "Increase the size of Joels posted." (w/asset "talents/bigjoel.png"))
+;; (w/talent-create "shaderopacity" "Opacity" "Make shaders more opaque." (w/asset "talents/shaderopacity.png"))
+;; (w/talent-create "bonuscard" "Bonus Cards" "Gain a chance to draw extra cards." (w/asset "talents/bonuscard.png"))
+;; (w/talent-create "rarityboost" "Rarity Boost" "Cards you draw have higher rarity." (w/asset "talents/rarityboost.png"))
+;; (w/talent-create "beastmaster" "Beastmaster" "Friend likes you more." (w/asset "talents/beastmaster.png"))
+;; (w/talent-create "multicast" "Multi-cast" "Hexes have a chance to cast on an additional target." (w/asset "talents/multicast.png"))
+
+(provide 'wasp-user-talents)
+;;; wasp-user-talents.el ends here