From a7011421b4a59f2cb472397744d2a88d084ac741 Mon Sep 17 00:00:00 2001 From: myk002 Date: Fri, 29 Jul 2022 16:31:37 -0700 Subject: [PATCH] update docs for rendermax --- docs/plugins/rendermax.rst | 36 +++++++++++++++++++++++---------- plugins/rendermax/rendermax.cpp | 15 ++++---------- 2 files changed, 29 insertions(+), 22 deletions(-) diff --git a/docs/plugins/rendermax.rst b/docs/plugins/rendermax.rst index a173a75db..641a7a248 100644 --- a/docs/plugins/rendermax.rst +++ b/docs/plugins/rendermax.rst @@ -1,18 +1,32 @@ rendermax ========= -A collection of renderer replacing/enhancing filters. For better effect try changing the -black color in palette to non totally black. See :forums:`128487` for more info. +Tags: +:dfhack-keybind:`rendermax` -Options: +Modify the map lighting. This plugin provides a collection of OpenGL lighting +filters that affect how the map is drawn to the screen. -:trippy: Randomizes the color of each tiles. Used for fun, or testing. -:light: Enable lighting engine. -:light reload: Reload the settings file. -:light sun |cycle: Set time to (in hours) or set it to df time cycle. -:occlusionON, occlusionOFF: Show debug occlusion info. -:disable: Disable any filter that is enabled. +Usage: -An image showing lava and dragon breath. Not pictured here: sunlight, shining items/plants, -materials that color the light etc... +``rendermax light`` + Light the map tiles realisitically. Outside tiles are light during the day + and dark at night. Inside tiles are always dark unless a nearby unit is + lighting it up, as if they were carrying torches. +``rendermax light sun |cycle`` + Set the outside lighting to correspond with the specified day hour (1-24), + or specify ``cycle`` to have the lighting follow the sun (which is the + default). +``rendermax light reload`` + Reload the lighting settings file. +``rendermax trippy`` + Randomize the color of each tile. Used for fun, or testing. +``rendermax disable`` + Disable any ``rendermax`` lighting filters that are currently active. + +An image showing lava and dragon breath. Not pictured here: sunlight, shining +items/plants, materials that color the light etc. .. image:: ../images/rendermax.png + +For better visibility, try changing the black color in palette to non totally +black. See :forums:`128487` for more info. diff --git a/plugins/rendermax/rendermax.cpp b/plugins/rendermax/rendermax.cpp index d391bdb36..b7c703e09 100644 --- a/plugins/rendermax/rendermax.cpp +++ b/plugins/rendermax/rendermax.cpp @@ -49,16 +49,9 @@ static command_result rendermax(color_ostream &out, vector & parameters DFhackCExport command_result plugin_init (color_ostream &out, std::vector &commands) { commands.push_back(PluginCommand( - "rendermax", "switch rendering engine.", rendermax, false, - " rendermax trippy\n" - " rendermax truecolor red|green|blue|white\n" - " rendermax lua\n" - " rendermax light - lighting engine\n" - " rendermax light reload - reload the settings file\n" - " rendermax light sun |cycle - set time to x (in hours) or cycle (same effect if x<0)\n" - " rendermax light occlusionON|occlusionOFF - debug the occlusion map\n" - " rendermax disable\n" - )); + "rendermax", + "Modify the map lighting.", + rendermax)); return CR_OK; } @@ -331,7 +324,7 @@ static command_result rendermax(color_ostream &out, vector & parameters return CR_WRONG_USAGE; if(!enabler->renderer->uses_opengl()) { - out.printerr("Sorry, this plugin needs open gl enabled printmode. Try STANDARD or other non-2D\n"); + out.printerr("Sorry, this plugin needs open GL-enabled printmode. Try STANDARD or other non-2D.\n"); return CR_FAILURE; } string cmd=parameters[0];