TPT: Avoid stacking in INVS and FILT, and fix pressurised INVS graphics
This commit is contained in:
parent
2aebc294e8
commit
5f81b70787
@ -2988,6 +2988,7 @@ void Simulation::update_particles_i(int start, int inc)
|
||||
create_part(i, x, y, PT_NBHL);
|
||||
parts[i].temp = MAX_TEMP;
|
||||
parts[i].tmp = pmap_count[y][x]-NPART;//strength of grav field
|
||||
if (parts[i].tmp>51200) parts[i].tmp = 51200;
|
||||
pmap_count[y][x] = NPART;
|
||||
}
|
||||
else
|
||||
@ -4151,6 +4152,9 @@ void Simulation::update_particles()//doesn't update the particles themselves, bu
|
||||
photons[y][x] = t|(i<<8);
|
||||
else
|
||||
{
|
||||
// Particles are sometimes allowed to go inside INVS and FILT
|
||||
// To make particles collide correctly when inside these elements, these elements must not overwrite an existing pmap entry from particles inside them
|
||||
if (!pmap[y][x] || (t!=PT_INVIS && t!= PT_FILT))
|
||||
pmap[y][x] = t|(i<<8);
|
||||
pmap_count[y][x]++;
|
||||
}
|
||||
|
@ -57,8 +57,7 @@ int Element_INVIS::graphics(GRAPHICS_FUNC_ARGS)
|
||||
*colr = 15;
|
||||
*colg = 0;
|
||||
*colb = 150;
|
||||
*pixel_mode &= PMODE;
|
||||
*pixel_mode |= PMODE_BLEND;
|
||||
*pixel_mode = PMODE_BLEND;
|
||||
}
|
||||
return 0;
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user