Fix T49466: Stupid typo in logicbricks new copy code from rB776a8548f03a

Moved that code forth and back a few times while creating rB776a8548f03a fix,
ended up forgetting to update it correctly for function where it layed down in the end.

Last-minute fixes are never a good thing... Now we already have real reason for 2.78 'a' release :(
This commit is contained in:
Bastien Montagne 2016-09-27 17:55:12 +02:00 committed by Sergey Sharybin
parent a05f9bef3f
commit d78a4b0c62
1 changed files with 2 additions and 2 deletions

View File

@ -789,7 +789,7 @@ void BKE_sca_logic_copy(Object *ob_new, Object *ob)
copy_controllers(&ob_new->controllers, &ob->controllers);
copy_actuators(&ob_new->actuators, &ob->actuators);
for (bSensor *sens = ob->sensors.first; sens; sens = sens->next) {
for (bSensor *sens = ob_new->sensors.first; sens; sens = sens->next) {
if (sens->flag & SENS_NEW) {
for (int a = 0; a < sens->totlinks; a++) {
if (sens->links[a] && sens->links[a]->mynew) {
@ -799,7 +799,7 @@ void BKE_sca_logic_copy(Object *ob_new, Object *ob)
}
}
for (bController *cont = ob->controllers.first; cont; cont = cont->next) {
for (bController *cont = ob_new->controllers.first; cont; cont = cont->next) {
if (cont->flag & CONT_NEW) {
for (int a = 0; a < cont->totlinks; a++) {
if (cont->links[a] && cont->links[a]->mynew) {