… | |
… | |
1418 | // update the mapspace, if we are on a map |
1418 | // update the mapspace, if we are on a map |
1419 | if (!flag [FLAG_REMOVED] && map) |
1419 | if (!flag [FLAG_REMOVED] && map) |
1420 | map->at (x, y).flags_ = 0; |
1420 | map->at (x, y).flags_ = 0; |
1421 | } |
1421 | } |
1422 | |
1422 | |
|
|
1423 | void |
|
|
1424 | object::set_glow_radius (sint8 rad) |
|
|
1425 | { |
|
|
1426 | glow_radius = rad; |
|
|
1427 | |
|
|
1428 | if (is_on_map ()) |
|
|
1429 | update_all_los (map, x, y); |
|
|
1430 | else if (object *env = outer_env ()) |
|
|
1431 | { |
|
|
1432 | env->update_stats (); |
|
|
1433 | |
|
|
1434 | if (env->is_on_map ()) |
|
|
1435 | update_all_los (env->map, env->x, env->y); |
|
|
1436 | } |
|
|
1437 | } |
|
|
1438 | |
1423 | /* |
1439 | /* |
1424 | * Returns true if the given player is a legal class. |
1440 | * Returns true if the given player is a legal class. |
1425 | * The function to add and remove class-bonuses to the stats doesn't |
1441 | * The function to add and remove class-bonuses to the stats doesn't |
1426 | * check if the stat becomes negative, thus this function |
1442 | * check if the stat becomes negative, thus this function |
1427 | * merely checks that all stats are 1 or more, and returns |
1443 | * merely checks that all stats are 1 or more, and returns |