X-Git-Url: https://git.verplant.org/?a=blobdiff_plain;f=src%2Fobject%2Fbackground.hpp;h=3321c923cc6d84a07c55ead52108e83d9d4f30c2;hb=ae7bd4f460fdd93934fc0abc9589758a49309bda;hp=ac268a97123311053d734ef6dfa2ea36000c3379;hpb=4ccc2606d1b037bb385604bdeaa40df7a94eff36;p=supertux.git diff --git a/src/object/background.hpp b/src/object/background.hpp index ac268a971..3321c923c 100644 --- a/src/object/background.hpp +++ b/src/object/background.hpp @@ -1,7 +1,7 @@ // $Id$ // -// SuperTux - A Jump'n Run -// Copyright (C) 2004 Matthias Braun // // This program is free software; you can redistribute it and/or // modify it under the terms of the GNU General Public License @@ -16,6 +16,7 @@ // You should have received a copy of the GNU General Public License // along with this program; if not, write to the Free Software // Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. + #ifndef SUPERTUX_BACKGROUND_H #define SUPERTUX_BACKGROUND_H @@ -42,27 +43,16 @@ public: void set_image(const std::string& name, float bkgd_speed); - void set_gradient(Color top, Color bottom); - std::string get_image() const - { return imagefile; } + { return imagefile; } float get_speed() const - { return speed; } - Color get_gradient_top() const - { return gradient_top; } - Color get_gradient_bottom() const - { return gradient_bottom; } + { return speed; } virtual void update(float elapsed_time); virtual void draw(DrawingContext& context); private: - enum Type { - INVALID, GRADIENT, IMAGE - }; - - Type type; int layer; std::string imagefile_top; std::string imagefile; @@ -72,9 +62,7 @@ private: float speed_y; /**< scroll-speed in vertical direction */ std::auto_ptr image_top; /**< image to draw above pos */ std::auto_ptr image; /**< image to draw, anchored at pos */ - std::auto_ptr image_bottom; /**< image to draw below pos+ */ - Color gradient_top, gradient_bottom; + std::auto_ptr image_bottom; /**< image to draw below pos+screenheight */ }; #endif /*SUPERTUX_BACKGROUND_H*/ -