Console



Console is a developer interface in Don't Starve. Players can open a console menu by pressing

~ (English/French/American/Canadian) or ^ (German Keyboard Layout) for any OS. However, the feature must be enabled in the file under the following directory:

Windows, Mac: \Klei\DoNotStarve\settings.ini Linux: ~/.klei/DoNotStarve/settings.ini

Opening settings.ini, players should make the following changes:

[MISC] ENABLECONSOLE = true

Debug Spawn


Main Article: Console/Prefab List

DebugSpawn in the console is the mostly used by players. It can spawn unimplemented features like Unimplemented/Speculated Characters and Unimplemented/Speculated Items.

Players can also spawn other entities too. For example, if a player wants to spawn a Deerclops, he/she has to open the console and type DebugSpawn("deerclops").

Nevertheless, players are noticed that the entity name should follow the file name under. If players want to spawn a Treeguard, players should type DebugSpawn("leif") as the file name of Treeguard is leif.lua.

A list of the prefabs is being compiled at Console/Prefab List.

Spawn multiple items at once

The follow the instructions below to spawn 40 items. Substitute  by the technical code name of the item, players can look these codes up below in paragraph "List of Debug Spawn".

Step 1: Open console

Step 2: Enter this code: for x = 1, 40 do DebugSpawn("yourprefabname") end

Step 3: Press Enter/Return to execute code.

List of Debug Spawn Main Article: Console/Prefab List

Characters

 * DebugSpawn("Wilson")
 * DebugSpawn("Willow")
 * DebugSpawn("Wendy")
 * DebugSpawn("Wolfgang")
 * DebugSpawn("Wickerbottom")
 * DebugSpawn("WX78")


 * DebugSpawn("Wes")
 * DebugSpawn("Lockedwes")
 * DebugSpawn("Woodie")
 * DebugSpawn("Wilton")
 * DebugSpawn("Waxwell") (Only In Surprise! Story Mode Preview)

Structures
DebugSpawn("pighouse")

Simple
Maxwellian
 * DebugSpawn("beehive")


 * DebugSpawn("adventure_portal")
 * DebugSpawn("teleportato_base")
 * DebugSpawn("diviningrodbase")
 * DebugSpawn("teleportato_box")
 * DebugSpawn("teleportato_crank")
 * DebugSpawn("teleportato_potato")
 * DebugSpawn("teleportato_ring")


 * DebugSpawn("maxwellthrone")
 * DebugSpawn("maxwellkey")
 * DebugSpawn("maxwelllock")
 * DebugSpawn("marbletree")
 * DebugSpawn("maxwellhead")
 * DebugSpawn("maxwelllight")

Nature
 * DebugSpawn("tree")
 * DebugSpawn("pond")
 * DebugSpawn("sapling")
 * DebugSpawn("flower")
 * DebugSpawn("pighouse")
 * DebugSpawn("pigtorch")
 * DebugSpawn("rabbithole")
 * DebugSpawn("spiderden")
 * DebugSpawn("tallbirdnest")
 * DebugSpawn("berrybush")
 * DebugSpawn("blue_mushroom")
 * DebugSpawn("red_mushroom")
 * DebugSpawn("green_mushroom")
 * DebugSpawn("grass")
 * DebugSpawn("basalt")
 * DebugSpawn("rain") WARNING: This will stay permanently
 * DebugSpawn("snow") WARNING: This will stay permanently

Mobs
Hostile


 * DebugSpawn("snowman) (does not currently work)''
 * DebugSpawn("spider")
 * DebugSpawn("slurtle)''
 * DebugSpawn("spiderwarrior")
 * DebugSpawn("merm")
 * DebugSpawn("knight")
 * DebugSpawn("bishop")
 * DebugSpawn("spiderqueen")
 * DebugSpawn("tentacle")
 * DebugSpawn("tallbird")
 * DebugSpawn("bat")


 * DebugSpawn("hound")
 * DebugSpawn("firehound")
 * DebugSpawn("icehound")
 * DebugSpawn("krampus")
 * DebugSpawn("walrus")
 * DebugSpawn("ghost")
 * DebugSpawn("leif")
 * DebugSpawn("deerclops")
 * DebugSpawn("killerbee")
 * DebugSpawn("basic_shop")

Neutral


 * DebugSpawn("bee")
 * DebugSpawn("beefalo")
 * DebugSpawn("frog")
 * DebugSpawn("penguin)''


 * DebugSpawn("pigman")
 * DebugSpawn("koalefant_summer")
 * DebugSpawn("koalefant_winter")
 * DebugSpawn("bunnyman")

Passive
 * DebugSpawn("butterfly")
 * DebugSpawn("crow")
 * DebugSpawn("rabbit")
 * DebugSpawn("perd")
 * DebugSpawn("mandrake")

Items

 * DebugSpawn("amulet")
 * DebugSpawn("armor_grass")
 * DebugSpawn("armor_marble")
 * DebugSpawn("armor_sanity")
 * DebugSpawn("armorwood")
 * DebugSpawn("ash")
 * DebugSpawn("axe")
 * DebugSpawn("backpack")
 * DebugSpawn("bandage")
 * DebugSpawn("beardhair")
 * DebugSpawn("bedroll_straw")
 * DebugSpawn("beefalowool")
 * DebugSpawn("birdtrap")
 * DebugSpawn("blowdart")
 * DebugSpawn("blowdart_pipe")
 * DebugSpawn("blowdart_fire")
 * DebugSpawn("blowdart_sleep")
 * DebugSpawn("bluegem")
 * DebugSpawn("blueprint")
 * DebugSpawn("boards")
 * DebugSpawn("boomerang")
 * DebugSpawn("bugnet")
 * DebugSpawn("butter")
 * DebugSpawn("butterflywings")
 * DebugSpawn("cane")
 * DebugSpawn("carrot")
 * DebugSpawn("charcoal")
 * DebugSpawn("chester_eyebone")
 * DebugSpawn("cutgrass")
 * DebugSpawn("cutreeds")
 * DebugSpawn("cutstone")
 * DebugSpawn("deadlyfeast")
 * DebugSpawn("deerclops_eyeball")
 * DebugSpawn("diviningrod")
 * DebugSpawn("egg")
 * DebugSpawn("feathers")
 * DebugSpawn("feather_robin")
 * DebugSpawn("feather_robin_winter")
 * DebugSpawn("feather_crow")
 * DebugSpawn("firestaff")
 * DebugSpawn("fish")
 * DebugSpawn("fishingrod")
 * DebugSpawn("flint")
 * DebugSpawn("froglegs")
 * DebugSpawn("gears")
 * DebugSpawn("goldnugget")
 * DebugSpawn("gunpowder")
 * DebugSpawn("hambat")
 * DebugSpawn("hammer")
 * DebugSpawn("healingsalve")
 * DebugSpawn("heatrock")
 * DebugSpawn("honey")
 * DebugSpawn("honeycomb")
 * DebugSpawn("horn")
 * DebugSpawn("houndstooth")
 * DebugSpawn("icestaff")
 * DebugSpawn("icegem")
 * DebugSpawn("krampus_sack")
 * DebugSpawn("livinglog")


 * DebugSpawn("nightmarefuel")
 * DebugSpawn("nightsword")
 * DebugSpawn("nitre")
 * DebugSpawn("onemandband")
 * DebugSpawn("panflute")
 * DebugSpawn("papyrus")
 * DebugSpawn("petals")
 * DebugSpawn("petals_evil")
 * DebugSpawn("pickaxe")
 * DebugSpawn("piggyback")
 * DebugSpawn("pigskin")
 * DebugSpawn("pinecone")
 * DebugSpawn("pitchfork")
 * DebugSpawn("poop")
 * DebugSpawn("pumpkin_lantern")
 * DebugSpawn("purplegem")
 * DebugSpawn("razor")
 * DebugSpawn("redgem")
 * DebugSpawn("seeds")
 * DebugSpawn("sewingkit")
 * DebugSpawn("shovel")
 * DebugSpawn("silk")
 * DebugSpawn("spear")
 * DebugSpawn("spidereggsack")
 * DebugSpawn("spidergland")
 * DebugSpawn("stinger")
 * DebugSpawn("sweatervest")
 * DebugSpawn("tallbirdegg")
 * DebugSpawn("tentaclespike")
 * DebugSpawn("tentaclespots")
 * DebugSpawn("torch")
 * DebugSpawn("twigs")
 * DebugSpawn("umbrella")
 * DebugSpawn("walrus_trusk")

Other Characters

 * DebugSpawn("abigail")
 * DebugSpawn("chester")
 * DebugSpawn("pigking")
 * DebugSpawn("maxwell")

Caves

 * DebugSpawn("rabbithouse") (Rabbit Hutch)
 * DebugSpawn("flower_cave")  (Light Flower)
 * DebugSpawn("stalagmite") (Stalagmite)
 * DebugSpawn("bunnyman") (Bunnyman)
 * DebugSpawn("lightbulb") (Lightbulb)
 * DebugSpawn("bat") (Batilisk)
 * DebugSpawn("lantern") (Lantern)
 * DebugSpawn("mushtree_tall") (Mushtree)
 * DebugSpawn("slurtlehole") (Slurtle Mound)
 * DebugSpawn("slurtle") (Slurtle)
 * DebugSpawn("snurtle") (Snurtle)
 * DebugSpawn("lureplant") (Lureplant)
 * DebugSpawn("rocky") (Rock Lobster)
 * DebugSpawn("spiderhole") (Spilagmite)

Useful commands For A Giant Penis Like You :D
To enable useful commands, declared in data\scripts\consolecommands.lua, but disabled by default, do:

Step 1: Open console

Step 2: Enter RunScript("consolecommands")

This will allow you to use the following commands: There's some other commands, but they're hard to use and not quite useful.
 * c_spawn("prefab", amount) -- Improved DebugSpawn("prefab"), spawns amount of selected "prefab".
 * c_doscenario(scenario) -- Apply a scenario script to the selection and run it. *Not tested*
 * c_sethealth(0.percent) -- Sets your health to selected percentage. Note: Use fractional numbers 0.90 = 90%.
 * c_setsanity(0.percent) -- Sets your sanity to selected percentage. Note: Use fractional numbers 0.90 = 90%.
 * c_sethunger(0.percent) -- Sets your hunger to selected percentage. Note: Use fractional numbers 0.90 = 90%.
 * c_give("prefab", amount) -- Creates selected item at given amount directly into your inventory.
 * c_godmode -- Toggle godmode.

Reveal map

Enter following code: minimap = TheSim:FindFirstEntityWithTag("minimap")

Enter the next code: minimap.MiniMap:ShowArea(0,0,0, 10000)

God mode

Enter the following code: GetPlayer.components.health:SetInvincible(true)

(When you travel through a wormhole you are no longer invincible so you must re-enter the code)

Run Speed
Example code: GetPlayer.components.locomotor.runspeed = 10

the above line will make you a bit faster. Set it to about 50 if you want to be able to run through walls and over water. (you move so fast that the game doesnt have time to test for collision)

Skipping days
To skip a day, enter the following code: GetClock:MakeNextDay

To skip more days:

Enter the following code: for x = 1, 40 do GetClock:MakeNextDay end

Sidenote: You can replace 40 with a number you like, If you want to skip 60 days then enter 60.

Note: Don't skip too many days at once, it could freeze your game, or at least hang it for a very long time.

Set Max Health

Enter the following code: GetPlayer.components.health:SetMaxHealth(300)

You now have 300 health (at first it seems like it did nothing, but get hit, and it will show you your new max health).

Set Max Sanity

Enter the following code: GetPlayer.components.sanity:SetMax(500)

You now increased your Max Sanity to 500! (current sanity will also be set to 500)

Pause Hunger

Enter the following code: GetPlayer.components.hunger:Pause(true)

You will never starve now!

"Creative Mode"

Enter the following code: GetPlayer.components.builder:GiveAllRecipes

After executing that code, select something in your inventory, pick up an item, or otherwise update your inventory.

Once enabled, you will unlock all recipes and be able to craft anything, regardless of if you have sufficient recources. Note that if you have recources, they will be consumed. This effect will wear off once you reload the world.