mirror of
https://github.com/luanti-org/luanti.git
synced 2025-08-01 17:38:41 +00:00
Apply suggestions
This commit is contained in:
parent
442245599b
commit
cb5d97e751
5 changed files with 30 additions and 28 deletions
|
@ -211,7 +211,7 @@ void Clouds::updateMesh()
|
|||
switch (i)
|
||||
{
|
||||
case 0: // top
|
||||
for (video::S3DVertex& vertex : v) {
|
||||
for (video::S3DVertex &vertex : v) {
|
||||
vertex.Normal.set(0, 1, 0);
|
||||
}
|
||||
v[0].Pos.set(-rx, ry,-rz);
|
||||
|
@ -226,14 +226,14 @@ void Clouds::updateMesh()
|
|||
continue;
|
||||
}
|
||||
if (soft_clouds_enabled) {
|
||||
for (video::S3DVertex& vertex : v) {
|
||||
for (video::S3DVertex &vertex : v) {
|
||||
vertex.Normal.set(0, 0, -1);
|
||||
}
|
||||
v[2].Color = c_bottom;
|
||||
v[3].Color = c_bottom;
|
||||
}
|
||||
else {
|
||||
for (video::S3DVertex& vertex : v) {
|
||||
for (video::S3DVertex &vertex : v) {
|
||||
vertex.Color = c_side_1;
|
||||
vertex.Normal.set(0, 0, -1);
|
||||
}
|
||||
|
@ -250,14 +250,14 @@ void Clouds::updateMesh()
|
|||
continue;
|
||||
}
|
||||
if (soft_clouds_enabled) {
|
||||
for (video::S3DVertex& vertex : v) {
|
||||
for (video::S3DVertex &vertex : v) {
|
||||
vertex.Normal.set(1, 0, 0);
|
||||
}
|
||||
v[2].Color = c_bottom;
|
||||
v[3].Color = c_bottom;
|
||||
}
|
||||
else {
|
||||
for (video::S3DVertex& vertex : v) {
|
||||
for (video::S3DVertex &vertex : v) {
|
||||
vertex.Color = c_side_2;
|
||||
vertex.Normal.set(1, 0, 0);
|
||||
}
|
||||
|
@ -274,14 +274,14 @@ void Clouds::updateMesh()
|
|||
continue;
|
||||
}
|
||||
if (soft_clouds_enabled) {
|
||||
for (video::S3DVertex& vertex : v) {
|
||||
for (video::S3DVertex &vertex : v) {
|
||||
vertex.Normal.set(0, 0, -1);
|
||||
}
|
||||
v[2].Color = c_bottom;
|
||||
v[3].Color = c_bottom;
|
||||
}
|
||||
else {
|
||||
for (video::S3DVertex& vertex : v) {
|
||||
for (video::S3DVertex &vertex : v) {
|
||||
vertex.Color = c_side_1;
|
||||
vertex.Normal.set(0, 0, -1);
|
||||
}
|
||||
|
@ -298,14 +298,14 @@ void Clouds::updateMesh()
|
|||
continue;
|
||||
}
|
||||
if (soft_clouds_enabled) {
|
||||
for (video::S3DVertex& vertex : v) {
|
||||
for (video::S3DVertex &vertex : v) {
|
||||
vertex.Normal.set(-1, 0, 0);
|
||||
}
|
||||
v[2].Color = c_bottom;
|
||||
v[3].Color = c_bottom;
|
||||
}
|
||||
else {
|
||||
for (video::S3DVertex& vertex : v) {
|
||||
for (video::S3DVertex &vertex : v) {
|
||||
vertex.Color = c_side_2;
|
||||
vertex.Normal.set(-1, 0, 0);
|
||||
}
|
||||
|
@ -316,7 +316,7 @@ void Clouds::updateMesh()
|
|||
v[3].Pos.set(-rx, 0, rz);
|
||||
break;
|
||||
case 5: // bottom
|
||||
for (video::S3DVertex& vertex : v) {
|
||||
for (video::S3DVertex &vertex : v) {
|
||||
vertex.Color = c_bottom;
|
||||
vertex.Normal.set(0, -1, 0);
|
||||
}
|
||||
|
@ -327,7 +327,7 @@ void Clouds::updateMesh()
|
|||
break;
|
||||
}
|
||||
|
||||
for (video::S3DVertex& vertex : v) {
|
||||
for (video::S3DVertex &vertex : v) {
|
||||
vertex.Pos += pos;
|
||||
vertices.push_back(vertex);
|
||||
}
|
||||
|
|
|
@ -1813,13 +1813,13 @@ void Client::handleCommand_SetLighting(NetworkPacket *pkt)
|
|||
*pkt >> lighting.bloom_intensity
|
||||
>> lighting.bloom_strength_factor
|
||||
>> lighting.bloom_radius;
|
||||
if (pkt->getRemainingBytes() >= 4)
|
||||
}
|
||||
if (pkt->getRemainingBytes() >= 72) {
|
||||
*pkt >> lighting.artificial_light_color;
|
||||
if (pkt->getRemainingBytes() >= 68)
|
||||
*pkt >> lighting.volumetric_beta_r0;
|
||||
*pkt >> lighting.vignette.dark
|
||||
>> lighting.vignette.bright
|
||||
>> lighting.vignette.power;
|
||||
>> lighting.vignette.bright
|
||||
>> lighting.vignette.power;
|
||||
*pkt >> lighting.cdl.slope;
|
||||
*pkt >> lighting.cdl.offset;
|
||||
*pkt >> lighting.cdl.power;
|
||||
|
|
|
@ -58,10 +58,10 @@
|
|||
Rename TOCLIENT_DEATHSCREEN to TOCLIENT_DEATHSCREEN_LEGACY
|
||||
Rename TOSERVER_RESPAWN to TOSERVER_RESPAWN_LEGACY
|
||||
Support float animation frame numbers in TOCLIENT_LOCAL_PLAYER_ANIMATIONS
|
||||
Add beta_r0, vignette, specular intensity, foliage translucency and cdl parameters to Lighting packets
|
||||
[scheduled bump for 5.10.0]
|
||||
PROTOCOL VERSION 47
|
||||
Add particle blend mode "clip"
|
||||
Add artificial light color, beta_r0, vignette, specular intensity, foliage translucency and cdl parameters to Lighting packets
|
||||
[scheduled bump for 5.11.0]
|
||||
*/
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue