I'm having trouble giving messages to a particular side under OnTickGame because I don't know how to find out which side I am on (" 'aircraft' is not valid in this context"). Any ideas please?
Code:
public override void OnTickGame()
{
if (Time.tickCounter() % 115200 == 1980) // Testing, reduced to 1 min. 1980 = 60secs delay.
{
GamePlay.gpHUDLogCenter("1 minute Timetick message.");
//issue message after further 30 seconds (test)
double initTime = 0.0;
Timeout(initTime += 30, () =>
if (aircraft != null) //error the name aircraft does not exist in the current context
{
switch (aircraft.Army()) {
case 1:
{ GamePlay.gpHUDLogCenter("Red side message."); }
break;
case 2:
{ GamePlay.gpHUDLogCenter("Blue side message"); }
break;
}
});
}
}