mirror of
https://github.com/luanti-org/luanti.git
synced 2025-06-27 16:36:03 +00:00
set_sky improvements, set_sun, set_moon and set_stars
This commit is contained in:
parent
580e7e8eb9
commit
946c03c69b
19 changed files with 1525 additions and 400 deletions
|
@ -22,6 +22,7 @@ with this program; if not, write to the Free Software Foundation, Inc.,
|
|||
|
||||
#include "player.h"
|
||||
#include "cloudparams.h"
|
||||
#include "skyparams.h"
|
||||
|
||||
class PlayerSAO;
|
||||
|
||||
|
@ -83,23 +84,21 @@ public:
|
|||
return hud_hotbar_selected_image;
|
||||
}
|
||||
|
||||
void setSky(const video::SColor &bgcolor, const std::string &type,
|
||||
const std::vector<std::string> ¶ms, bool &clouds)
|
||||
{
|
||||
m_sky_bgcolor = bgcolor;
|
||||
m_sky_type = type;
|
||||
m_sky_params = params;
|
||||
m_sky_clouds = clouds;
|
||||
}
|
||||
void setSky(const SkyboxParams &skybox_params) { m_skybox_params = skybox_params; }
|
||||
|
||||
void getSky(video::SColor *bgcolor, std::string *type,
|
||||
std::vector<std::string> *params, bool *clouds)
|
||||
{
|
||||
*bgcolor = m_sky_bgcolor;
|
||||
*type = m_sky_type;
|
||||
*params = m_sky_params;
|
||||
*clouds = m_sky_clouds;
|
||||
}
|
||||
const SkyboxParams &getSkyParams() const { return m_skybox_params; }
|
||||
|
||||
void setSun(const SunParams &sun_params) { m_sun_params = sun_params; }
|
||||
|
||||
const SunParams &getSunParams() const { return m_sun_params; }
|
||||
|
||||
void setMoon(const MoonParams &moon_params) { m_moon_params = moon_params; }
|
||||
|
||||
const MoonParams &getMoonParams() const { return m_moon_params; }
|
||||
|
||||
void setStars(const StarParams &star_params) { m_star_params = star_params; }
|
||||
|
||||
const StarParams &getStarParams() const { return m_star_params; }
|
||||
|
||||
void setCloudParams(const CloudParams &cloud_params)
|
||||
{
|
||||
|
@ -164,12 +163,12 @@ private:
|
|||
std::string hud_hotbar_image = "";
|
||||
std::string hud_hotbar_selected_image = "";
|
||||
|
||||
std::string m_sky_type;
|
||||
video::SColor m_sky_bgcolor;
|
||||
std::vector<std::string> m_sky_params;
|
||||
bool m_sky_clouds;
|
||||
|
||||
CloudParams m_cloud_params;
|
||||
|
||||
SkyboxParams m_skybox_params;
|
||||
SunParams m_sun_params;
|
||||
MoonParams m_moon_params;
|
||||
StarParams m_star_params;
|
||||
|
||||
session_t m_peer_id = PEER_ID_INEXISTENT;
|
||||
};
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue