mirror of
https://github.com/luanti-org/luanti.git
synced 2025-06-27 16:36:03 +00:00
Add API to control shadow intensity from the game/mod (#11944)
* Also Disable shadows when sun/moon is hidden. Fixes #11972.
This commit is contained in:
parent
8d55702d13
commit
0f25fa7af6
24 changed files with 375 additions and 169 deletions
|
@ -22,6 +22,7 @@ with this program; if not, write to the Free Software Foundation, Inc.,
|
|||
|
||||
#include "player.h"
|
||||
#include "skyparams.h"
|
||||
#include "lighting.h"
|
||||
|
||||
class PlayerSAO;
|
||||
|
||||
|
@ -125,6 +126,10 @@ public:
|
|||
*frame_speed = local_animation_speed;
|
||||
}
|
||||
|
||||
void setLighting(const Lighting &lighting) { m_lighting = lighting; }
|
||||
|
||||
const Lighting& getLighting() const { return m_lighting; }
|
||||
|
||||
void setDirty(bool dirty) { m_dirty = true; }
|
||||
|
||||
u16 protocol_version = 0;
|
||||
|
@ -160,5 +165,7 @@ private:
|
|||
MoonParams m_moon_params;
|
||||
StarParams m_star_params;
|
||||
|
||||
Lighting m_lighting;
|
||||
|
||||
session_t m_peer_id = PEER_ID_INEXISTENT;
|
||||
};
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue