DP Random Mode Controller
Pick which random generator is live
- random_mode
- random_token_limit
This pack ships several themed random-prompt generators - superhero, vehicle, psychedelic punk, logo style, a general "crazy" mode, and a mixed mode that combines them. Rather than manually swapping which one feeds your workflow every time you want a different flavor, DP Random Mode Controller is the single dropdown that names which one is active, paired with a token budget that travels alongside it. It's the config half of a two-node combo - this one picks the mode, DP Random Mode Switch (a separate node in this pack) is what actually reads the pick and routes the matching text through.
How it works
random_mode is a six-way choice covering this pack's random generators: Crazy Random Prompt, Random Psychedelic Punk, Random Superhero, Random Vehicle, Random Letter Style, and All Mixed. random_token_limit sets a token budget that rides along with the choice - useful for keeping whichever generator gets selected from producing something too long for your target model's effective attention window.
Like its sibling DP Prompt Mode Controller, this node doesn't generate or transform anything on its own. It's a labeled setting with two outputs that only do something once they're wired into a node built to consume them - in this case, the matching switch node that holds the actual six generator outputs and picks between them based on what this controller says.
Inputs and outputs
Required:
random_mode- six-way choice:Crazy Random Prompt(default),Random Psychedelic Punk,Random Superhero,Random Vehicle,Random Letter Style,All Mixed.random_token_limit(0-512, default 72, integer) - a token budget that passes through alongside the mode choice.
No optional inputs.
Two outputs: random_mode (typed to the same six-value set - it only connects to inputs built to accept it) and random_token_limit (a plain INT passthrough).
Installing it
ComfyUI Manager: search ComfyUI-Desert-Pixel-Nodes, install, restart. Manual:
cd ComfyUI/custom_nodes
git clone https://github.com/DesertPixelAi/ComfyUI-Desert-Pixel-Nodes
Restart ComfyUI - a config node, nothing to download.
Where people get tripped up
Same trap as its Prompt-mode sibling: this node changes nothing on its own. If you flip random_mode and your generated text doesn't change, follow the wire - you need this node's output actually connected to DP Random Mode Switch (or whatever else in the graph is built to read a typed six-value mode), not just sitting on the canvas configured correctly. A correctly-set controller with nothing downstream reading it does nothing.
The random_token_limit output is also easy to leave dangling. It's meant to travel with the mode choice into whatever's generating or trimming text on the other end - if the receiving node has its own separate token-limit setting and you don't wire this one in, you'll end up with two different budgets in play and only one of them actually enforced. Check which one your downstream node is actually reading before assuming the limit here is doing anything.
Inputs (2)
| Name | Type | Default | Description |
|---|---|---|---|
| random_mode | COMBO | Crazy Random Prompt | 6 options: Crazy Random Prompt, Random Psychedelic Punk, Random Superhero, Random Vehicle, Random Letter Style, All Mixed |
| random_token_limit | INT | 720–512 | — |
Outputs (2)
| Name | Type | Description |
|---|---|---|
| random_mode | Crazy Random Prompt,Random Psychedelic Punk,Random Superhero,Random Vehicle,Random Letter Style,All Mixed | — |
| random_token_limit | INT | — |