From 8091eb2e8b5194399d69233a66b18d39cd6468ed Mon Sep 17 00:00:00 2001 From: Zeno Rogue Date: Sat, 1 Aug 2026 12:11:12 +0200 Subject: [PATCH] los:: neon mode is now enabled for magic vision --- celldrawer.cpp | 3 +++ colors.cpp | 2 +- config.cpp | 12 +++++++----- 3 files changed, 11 insertions(+), 6 deletions(-) diff --git a/celldrawer.cpp b/celldrawer.cpp index d1ea99d3..d28404f1 100644 --- a/celldrawer.cpp +++ b/celldrawer.cpp @@ -2921,6 +2921,9 @@ void celldrawer::draw() { if(seen) { + dynamicval b(neon_mode, neon_mode); + if(!in_line_of_sight(c)) neon_mode = neon_magic_vision; + if(inmirror(c)) { if(inmirrorcount >= 10) return; cellwalker cw(c); diff --git a/colors.cpp b/colors.cpp index 89d7662a..bf62c156 100644 --- a/colors.cpp +++ b/colors.cpp @@ -129,7 +129,7 @@ EX color_t align(color_t col) { enum class eNeon { none, neon, no_boundary, neon2, illustration}; #endif -EX eNeon neon_mode; +EX eNeon neon_mode, neon_magic_vision = eNeon::neon2; EX bool neon_nofill; EX void apply_neon(color_t& col, int& r) { diff --git a/config.cpp b/config.cpp index 3b168d39..40c6e0a4 100644 --- a/config.cpp +++ b/config.cpp @@ -1678,6 +1678,7 @@ EX void initConfig() { {"geodesic", "Graph geodesic: any sequence of tiles is OK for line-of-sight as long as there are no shortcuts"}, {"geometric", "Approximations of geometric straight lines."}}, "line-of-sight mode", 'v') + ->add_extra([] { add_edit(neon_magic_vision); }) ->set_reaction(switchLOS_quiet); param_f(vid.plevel_factor, "plevel_factor", 0.7); @@ -1876,12 +1877,13 @@ EX void initConfig() { param_i(nilv::nilperiod[0], "nilperiod_x"); param_i(nilv::nilperiod[1], "nilperiod_y"); param_i(nilv::nilperiod[2], "nilperiod_z"); + + vector> neon_options = {{"OFF", ""}, {"standard", ""}, {"no boundary mode", ""}, {"neon mode II", ""}, {"illustration mode", ""}}; - param_enum(neon_mode, "neon_mode", neon_mode) - ->editable( - {{"OFF", ""}, {"standard", ""}, {"no boundary mode", ""}, {"neon mode II", ""}, {"illustration mode", ""}}, - "neon mode", 'M' - ); + param_enum(neon_mode, "neon_mode", neon_mode)->editable(neon_options, "neon mode", 'M'); + + param_enum(neon_magic_vision, "neon_mode", neon_magic_vision)->editable(neon_options, "neon mode in magic vision", 'V') + ->add_extra([] { dialog::addHelp("Some Orbs let you see tiles you would not normally see. Such tiles can be shown differently."); }); param_enum(bow::weapon, "pc_class", bow::weapon) -> editable({{"blade", "Standard Rogue weapon. Bump into a monster to hit. Most monsters attack you the same way."},