X-Git-Url: https://plomlompom.com/repos/?a=blobdiff_plain;f=src%2Fserver%2Ffield_of_view.c;h=45c90e6c0a6f6dc7da76db9938c529f8124076b2;hb=1dc64ee46c2dcbd7eb8a6c4fcd27620dab7d7680;hp=dc60442e3ff28a835d462f5e3ca877b5c938fa2c;hpb=a18ffcfc0b1527b5751ff9c76b8bdb7ee181a764;p=plomrogue diff --git a/src/server/field_of_view.c b/src/server/field_of_view.c index dc60442..45c90e6 100644 --- a/src/server/field_of_view.c +++ b/src/server/field_of_view.c @@ -308,7 +308,7 @@ static void add_things_to_map_memory(struct Thing * t_eye) -extern void update_map_memory(struct Thing * t_eye) +extern void update_map_memory(struct Thing * t_eye, uint8_t age_map) { if (!t_eye->mem_map) { @@ -330,7 +330,8 @@ extern void update_map_memory(struct Thing * t_eye) } continue; } - if ( '0' <= t_eye->mem_depth_map[i] && '9' > t_eye->mem_depth_map[i] + if (age_map && + '0' <= t_eye->mem_depth_map[i] && '9' > t_eye->mem_depth_map[i] && !(rrand() % (uint16_t) pow(2, t_eye->mem_depth_map[i] - 48))) { t_eye->mem_depth_map[i]++;