X-Git-Url: https://git.verplant.org/?a=blobdiff_plain;f=src%2Fscripting%2Ftilemap.hpp;h=331580ed051c1bdc60daa320903265c4360ff777;hb=7a0031e8f250c852743709ab06ecafe1896eefbe;hp=5b2e3cd25b95d5cae96edf51f049e8917bdb22be;hpb=68ed4e94bda50566616c21031c3beb48499a7f7c;p=supertux.git diff --git a/src/scripting/tilemap.hpp b/src/scripting/tilemap.hpp index 5b2e3cd25..331580ed0 100644 --- a/src/scripting/tilemap.hpp +++ b/src/scripting/tilemap.hpp @@ -45,6 +45,22 @@ public: /** Stop tilemap at next node */ void stop_moving(); + /** + * Start fading the tilemap to opacity given by @c alpha. + * Destination opacity will be reached after @c seconds seconds. Also influences solidity. + */ + void fade(float alpha, float seconds); + + /** + * Instantly switch tilemap's opacity to @c alpha. Also influences solidity. + */ + void set_alpha(float alpha); + + /** + * Return tilemap's opacity. Note that while the tilemap is fading in or out, this will return the current alpha value, not the target alpha. + */ + float get_alpha(); + #ifndef SCRIPTING_API _TileMap* tilemap; #endif