I wanted to disable mapping in a few rooms that were covered in mist. I made a couple small changes to do this.
lib/events/describe.c
line 63:
#if MINIMAP
if(this_object()->GetProperty("minimapping") && !env->GetProperty("disablemapping")){
desc += simple_map(env)+"\n";
}
#endif
line 87:
if(i == VISION_CLEAR || i == VISION_LIGHT || i == VISION_DIM){
desc = env->GetShort();
if(this_object()->GetProperty("minimapping") && !env->GetProperty("disablemapping"))
desc += simple_map(env)+"\n";
This checks a property "disablemapping" to see if it is set to 1. If it is it will disable minimapping for each room it is set. The wizmapping is not affected.
secure/cmds/players/map.c
line 12:
if(!creatorp(this_player()) && environment(this_player())->GetProperty("disablemapping")) {
write("You are unable to see your map.");
} else {
ret = MAP_D->GetMap(environment(this_player()), i, 1);
write(ret);
}
This code will disable viewing maps if you are not a creator and display a message.
This isn't much but I figured it might be helpful if you want to disable viewing of maps for a specific area. Perhaps a one room building or similar since there would be not much value in mapping in those cases.
-Hells