Commit 9f198928 authored by frankie's avatar frankie 💬

stupid test mistake fixed in particles

parent 31ba5786
...@@ -74,7 +74,7 @@ futari_layers(1) { ...@@ -74,7 +74,7 @@ futari_layers(1) {
set_draw_passes(1); set_draw_passes(1);
set_draw_order(FDRAW_ORDER_INDEX); set_draw_order(FDRAW_ORDER_INDEX);
set_speed_scale(1); set_speed_scale(1);
} }
FutariParticles::~FutariParticles() { FutariParticles::~FutariParticles() {
...@@ -254,6 +254,7 @@ bool FutariParticles::_validate_modifier_vectors() { ...@@ -254,6 +254,7 @@ bool FutariParticles::_validate_modifier_vectors() {
int size = _modifiers.size(); int size = _modifiers.size();
for (int i = 0; i < size; ++i) { for (int i = 0; i < size; ++i) {
if (!(futari_layers & _modifiers[i]->futari_layers)) { if (!(futari_layers & _modifiers[i]->futari_layers)) {
std::cout << "one of the modifier just changed layer and NOT affects particles anymore!" << std::endl;
_rebuild_modifier_vectors(); _rebuild_modifier_vectors();
_procmat_refresh = true; _procmat_refresh = true;
return false; return false;
...@@ -267,7 +268,13 @@ bool FutariParticles::_validate_modifier_vectors() { ...@@ -267,7 +268,13 @@ bool FutariParticles::_validate_modifier_vectors() {
for (it = ds.begin(); it != ite; ++it) { for (it = ds.begin(); it != ite; ++it) {
FutariModifierData* fmd = (*it); FutariModifierData* fmd = (*it);
if (futari_layers & fmd->futari_layers && !_modifiers.find( fmd ) ) { if (futari_layers & fmd->futari_layers && _modifiers.find( fmd ) == -1 ) {
std::cout << "one of the modifier just changed layer and starts affecting particles NOW!" << std::endl;
std::cout << "_modifiers: " << _modifiers.size() << std::endl;
std::cout << "_attractors: " << _attractors.size() << std::endl;
std::cout << "_winds: " << _winds.size() << std::endl;
std::cout << "_vortices: " << _vortices.size() << std::endl;
std::cout << "_floors: " << _floors.size() << std::endl;
_rebuild_modifier_vectors(); _rebuild_modifier_vectors();
_procmat_refresh = true; _procmat_refresh = true;
return false; return false;
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment