Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- append = [$arg1 = (concat (getalias $arg1) $arg2)]
- appendword = [$arg1 = (concatword (getalias $arg1) $arg2)]
- clampval = [max $arg2 (min $arg3 $arg1)]
- keygen = [
- local chars tmp1 tmp2 tmp3
- chars = [ABCDEFGHIJKLMNOPQRSTUVWXYZ1234567890]
- tmp2 = (? $arg1 (clampval $arg1 3 10) 5)
- tmp3 = (? $arg2 (clampval $arg2 3 8) 4)
- loop i $tmp2 [
- loop p $tmp3 [
- appendword tmp1 (substr $chars (rnd (strlen $chars)) 1)
- ]
- if (< $i (- $tmp2 1)) [append tmp1 ""]
- ]
- say (strreplace $tmp1 " " "-")
- ]
- // use /keygen <section amount> <section length>
- // like, /keygen 6 5
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement