Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- [lua]
- code = <<
- local respawn_point
- local radius = 1
- repeat
- respawn_point = wesnoth.get_locations {
- "include_borders" = false,
- { "and",
- { "filter",
- { "id" = wesnoth.get_variable("respawn_hub") }
- },
- "radius" = radius
- },
- { "and" ,
- { "not",
- { "filter", {} }
- },
- { "not",
- { "terrain" = "Wo,*^Xm,X*,Q*" }
- }
- }
- }
- radius = radius + 1
- until respawn_point ~= false
- wesnoth.set_variable("respawn_point.x" respawn_point.x)
- wesnoth.set_variable("respawn_point.y" respawn_point.y)
- >>
- [/lua]
Advertisement
Add Comment
Please, Sign In to add comment