Adding patch notes from git, UI, and loading files from the main install path properly.
Also fixed: * flying wands not pathing properly. * Lantern particles offset * Wand fire offset * Water spray from flask
This commit is contained in:
1 parent
06bb712a46
commit
9bb9797271
19 files changed
+1569
-134
No files matched your search
+11
-10
@@ -62,7 +62,8 @@ void displaced_particle(uint id, FPart p) {
|
||||
fparts[id].c.w = p.c.w + 1u;
|
||||
return;
|
||||
}
|
||||
const float g = 0.1667;
|
||||
const bool spray = (p.c.w & 0x200000u) != 0u;
|
||||
const float g = spray ? PART_GRAV : 0.1667;
|
||||
vec2 target = pos + vel;
|
||||
vel.y += g * (kind == 1u ? 0.25 : 1.0);
|
||||
if (kind == 1u && vel.y > 0.0) kind = 2u;
|
||||
@@ -81,14 +82,14 @@ void displaced_particle(uint id, FPart p) {
|
||||
uint m = cell_mat(cells[q.y * pc.gw + q.x]);
|
||||
if (m != 0u) {
|
||||
uint f = mflags(m);
|
||||
if ((f & F_STATIC) != 0u) { dead = true; break; }
|
||||
if ((f & F_LIQUID) != 0u) {
|
||||
if ((f & F_STATIC) != 0u && !(spray && kind == 1u)) { dead = true; break; }
|
||||
if ((f & F_LIQUID) != 0u || (spray && (f & F_STATIC) != 0u)) {
|
||||
if (kind == 2u) { dead = true; break; } // mode 0 stops at liquid (and powder)
|
||||
float eff = (vel.y > -0.83 || (p.c.w & 0x100000u) != 0u) ? 0.0 : dens; // mode 1: effective density 0 (an upward speed below 50 px/s, or a draw at creation) unless moving up fast; it must be lighter than the target
|
||||
if (!(eff < mdensity(m)) || budget == 0u) { dead = true; break; }
|
||||
budget -= 1u;
|
||||
}
|
||||
}
|
||||
} else if (spray) kind = 2u;
|
||||
} else if (spray) kind = 2u; // 00712390: leaving material ends the mode-1 penetration.
|
||||
cur = nx;
|
||||
}
|
||||
if (!dead && int(mlen) <= 60) { // the target cell itself
|
||||
@@ -98,15 +99,15 @@ void displaced_particle(uint id, FPart p) {
|
||||
uint m = cell_mat(cells[q.y * pc.gw + q.x]);
|
||||
if (m != 0u) {
|
||||
uint f = mflags(m);
|
||||
if ((f & F_STATIC) != 0u) dead = true;
|
||||
else if ((f & F_LIQUID) != 0u) {
|
||||
if ((f & F_STATIC) != 0u && !(spray && kind == 1u)) dead = true;
|
||||
else if ((f & F_LIQUID) != 0u || (spray && (f & F_STATIC) != 0u)) {
|
||||
if (kind == 2u) dead = true;
|
||||
else {
|
||||
float eff = (vel.y > -0.83 || (p.c.w & 0x100000u) != 0u) ? 0.0 : dens;
|
||||
if (!(eff < mdensity(m)) || budget == 0u) dead = true; else budget -= 1u;
|
||||
}
|
||||
}
|
||||
}
|
||||
} else if (spray) kind = 2u;
|
||||
} else if (spray) kind = 2u;
|
||||
if (!dead) cur = target;
|
||||
}
|
||||
} else if (!dead) cur = target; // beyond the 60 probes the end point is taken as it is
|
||||
@@ -116,7 +117,7 @@ void displaced_particle(uint id, FPart p) {
|
||||
kind = 3u; // no place yet: it keeps trying
|
||||
}
|
||||
fparts[id].a = vec4(pos, vel);
|
||||
fparts[id].c = uvec4(cw, kind, budget, (p.c.w & 0x100000u) | ((p.c.w & 0xFFFFFu) + 1u));
|
||||
fparts[id].c = uvec4(cw, kind, budget, (p.c.w & 0x300000u) | ((p.c.w & 0xFFFFFu) + 1u));
|
||||
ivec2 q = ivec2(floor(pos)) - ivec2(pc.view_x, pc.view_y);
|
||||
if (q.x >= 0 && q.y >= 0 && q.x < pc.gw && q.y < pc.gh) {
|
||||
vec3 col = cell_colour(cw);
|
||||
|
||||
Reference in new issue
Block a user