Fix: Don't allow right-click to close world generation progress window. (#13084)
[openttd-github.git] / src / effectvehicle_base.h
blobae064d92ffd229e28f15541868293f4741f7bf40
1 /*
2 * This file is part of OpenTTD.
3 * OpenTTD is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation, version 2.
4 * OpenTTD is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
5 * See the GNU General Public License for more details. You should have received a copy of the GNU General Public License along with OpenTTD. If not, see <http://www.gnu.org/licenses/>.
6 */
8 /** @file effectvehicle_base.h Base class for all effect vehicles. */
10 #ifndef EFFECTVEHICLE_BASE_H
11 #define EFFECTVEHICLE_BASE_H
13 #include "vehicle_base.h"
14 #include "transparency.h"
16 /**
17 * A special vehicle is one of the following:
18 * - smoke
19 * - electric sparks for trains
20 * - explosions
21 * - bulldozer (road works)
22 * - bubbles (industry)
24 struct EffectVehicle final : public SpecializedVehicle<EffectVehicle, VEH_EFFECT> {
25 uint16_t animation_state; ///< State primarily used to change the graphics/behaviour.
26 uint8_t animation_substate; ///< Sub state to time the change of the graphics/behaviour.
28 /** We don't want GCC to zero our struct! It already is zeroed and has an index! */
29 EffectVehicle() : SpecializedVehicleBase() {}
30 /** We want to 'destruct' the right class. */
31 virtual ~EffectVehicle() = default;
33 void UpdateDeltaXY() override;
34 bool Tick() override;
35 TransparencyOption GetTransparencyOption() const;
38 #endif /* EFFECTVEHICLE_BASE_H */