mirror of
https://github.com/wesnoth/wesnoth
synced 2025-05-18 16:35:40 +00:00
Add support for images entry/exit teleport point for the new teleport footpath.
Currently twice the same file, to ease experiment and because url is still harcoded. I tried some fancy whirl and color, but with my gimp skill, better let a simple and good working placeholder (+I start to get used and like it)
This commit is contained in:
parent
ba862fc551
commit
bad0f6b4b0
Before Width: | Height: | Size: 7.4 KiB After Width: | Height: | Size: 7.4 KiB |
BIN
images/footsteps/teleport-out.png
Normal file
BIN
images/footsteps/teleport-out.png
Normal file
Binary file not shown.
After Width: | Height: | Size: 7.4 KiB |
@ -704,8 +704,11 @@ std::vector<surface> game_display::footsteps_images(const gamemap::location& loc
|
||||
const int second_half = (i+1 == route_.steps.end()) ? 0 : 1;
|
||||
|
||||
for (int h = first_half; h <= second_half; h++) {
|
||||
const std::string sense( h==0 ? "-in" : "-out" );
|
||||
|
||||
if (!tiles_adjacent(*(i-1+h), *(i+h))) {
|
||||
teleport = image::get_image("footsteps/teleport-step.png", image::UNMASKED);
|
||||
std::string teleport_image = "footsteps/teleport" + sense + ".png";
|
||||
teleport = image::get_image(teleport_image, image::UNMASKED);
|
||||
continue;
|
||||
}
|
||||
|
||||
@ -720,7 +723,7 @@ std::vector<surface> game_display::footsteps_images(const gamemap::location& loc
|
||||
}
|
||||
|
||||
const std::string image = foot_speed_prefix
|
||||
+ (h==0 ? "-in-" : "-out-") + i->write_direction(dir)
|
||||
+ sense + "-" + i->write_direction(dir)
|
||||
+ ".png" + rotate;
|
||||
|
||||
res.push_back(image::get_image(image, image::UNMASKED));
|
||||
|
Loading…
x
Reference in New Issue
Block a user