No, I don't think so. I think it was something structural...
quote:
if (int_array_currentmove_player[int_player_counter]==2)
{ [self schedule: @selector(player2Bid) interval:1.5];}
if (int_array_currentmove_player[int_player_counter]==3)
{ [self schedule: @selector(player3Bid) interval:1.5];}
if (int_array_currentmove_player[int_player_counter]==4)
{ [self schedule: @selector(player4Bid) interval:1.5];}
if (int_player_counter==4)
{
int_player_counter=0;
[self schedule: @selector(determineBidWinner) interval:1];
}
Became:
quote:
if (int_player_counter==4)
{
int_player_counter=0;
[self schedule: @selector(determineBidWinner) interval:1];
}
if (int_array_currentmove_player[int_player_counter]==2)
{ [self schedule: @selector(player2Bid) interval:1.5];}
else if (int_array_currentmove_player[int_player_counter]==3)
{ [self schedule: @selector(player3Bid) interval:1.5];}
else if (int_array_currentmove_player[int_player_counter]==4)
{ [self schedule: @selector(player4Bid) interval:1.5];}
I don't really see how this change does anything.
I also moved
quote:
[self reorderChild:_player1actionlabel z:1];
[self reorderChild:_player1actionlabelbackground z:0];
To the top of the method. It was near the bottom. The only thing between the top and the bottom are if statements that define the local string variable for _player1actionlabel, but I am 100% certain the issue is related to the memory allocation for both _player1actionlabel and _player1actionlabelbackground.
There are 2 settings you can use when you're building your app...Debug mode, and Release mode. I think the modes are self explanatory. What I think was happening is whatever was causing this crash was based solely on the speed of the code being executed. When I would test this bug out on the phone, I was using Debug mode so I could step line by line....but I was never able to make it crash. I'm guessing Debug mode slowed things down just enough to not cause a conflict with _player1actionlabel/_player1actionlabelbackground. I'm guessing something similar was happening with iOS 5/iOS 6 and SDK 4.3/4.5. Even running the code in release mode using the Xcode simulator failed to produce this crash. So whatever it was, is based entirely on the performance of the device....i think.
Definitely a learning experience on my part. Can't say I enjoyed it.
[This message has been edited by Philip J Fry (edited 10/10/2012 7:51a).]