supertux
custom_particle_system_file.hpp
1 // SuperTux
2 // Copyright (C) 2020 A. Semphris <semphris@protonmail.com>
3 //
4 // This program is free software: you can redistribute it and/or modify
5 // it under the terms of the GNU General Public License as published by
6 // the Free Software Foundation, either version 3 of the License, or
7 // (at your option) any later version.
8 //
9 // This program is distributed in the hope that it will be useful,
10 // but WITHOUT ANY WARRANTY; without even the implied warranty of
11 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
12 // GNU General Public License for more details.
13 //
14 // You should have received a copy of the GNU General Public License
15 // along with this program. If not, see <http://www.gnu.org/licenses/>.
16 
17 #ifndef HEADER_SUPERTUX_OBJECT_CUSTOM_PARTICLE_SYSTEM_FILE_HPP
18 #define HEADER_SUPERTUX_OBJECT_CUSTOM_PARTICLE_SYSTEM_FILE_HPP
19 
20 #include "math/easing.hpp"
21 #include "math/vector.hpp"
22 #include "object/custom_particle_system.hpp"
23 #include "object/particlesystem_interactive.hpp"
24 #include "object/particle_zone.hpp"
25 #include "video/surface.hpp"
26 #include "video/surface_ptr.hpp"
27 
29 {
30  friend class ParticleEditor;
31 
32 public:
35  ~CustomParticleSystemFile() override;
36 
37  static std::string class_name() { return "particles-custom-file"; }
38  virtual std::string get_class_name() const override { return class_name(); }
39  static std::string display_name() { return _("Custom Particles from file"); }
40  virtual std::string get_display_name() const override { return display_name(); }
42  virtual ObjectSettings get_settings() override;
43 
44  virtual const std::string get_icon_path() const override {
45  return "images/engine/editor/particle_file.png";
46  }
47 
48 private:
49  void update_data();
50 
51 private:
52  std::string m_filename;
53 
54 private:
56  CustomParticleSystemFile& operator=(const CustomParticleSystemFile&) = delete;
57 };
58 
59 #endif
60 
61 /* EOF */
Definition: particle_editor.hpp:38
virtual GameObjectClasses get_class_types() const override
List notable classes in inheritance hierarchy of class.
Definition: custom_particle_system_file.hpp:41
virtual std::string get_display_name() const override
Returns the display name of the object, translated to the user&#39;s locale.
Definition: custom_particle_system_file.hpp:40
Definition: object_settings.hpp:39
A ""CustomParticleSystem"" that was given a name can be controlled by scripts.
Definition: custom_particle_system.hpp:34
virtual GameObjectClasses get_class_types() const override
List notable classes in inheritance hierarchy of class.
Definition: custom_particle_system.hpp:56
Definition: custom_particle_system_file.hpp:28
A helper structure to list all the type_indexes of the classes in the type hierarchy of a given class...
Definition: game_object.hpp:57
Definition: reader_mapping.hpp:32