Hi all.
I have not really been on for at least 4 -5 years, so first I would like to say, Hi again.
-------------------------------------------------
Ok, I've just found my InSim, and I want to add a Km Bonus System. Yes thats right a KM Bonus System. Dont be alarmed! I've got my code here, but I just need someone to help me out with the variables.
My Code so far is:
Now as we see here the code inside the statement will not work. This is what I need help with. What I want to do is put
into some kind of... Oh, forgot the name... Damn.... But some kind of Integrar should I say for now. For example:
Can anyone help me?
Thanks!
I have not really been on for at least 4 -5 years, so first I would like to say, Hi again.
-------------------------------------------------
Ok, I've just found my InSim, and I want to add a Km Bonus System. Yes thats right a KM Bonus System. Dont be alarmed! I've got my code here, but I just need someone to help me out with the variables.
My Code so far is:
// KM bonuses
if (Connections[GetConnIdx(Players[GetPlyIdx(MCI.Info[0].PLID)].UniqueID)].TotalDistance / 1000 == 100) ;
{
// Give them £2000
Connections[GetConnIdx(Players[GetPlyIdx(MCI.Info[i].PLID)].UniqueID)].Cash = cashbonus;
Connections[GetConnIdx(Players[GetPlyIdx(MCI.Info[i].PLID)].UniqueID)].Username += cash;
}
Now as we see here the code inside the statement will not work. This is what I need help with. What I want to do is put
"Connections[GetConnIdx(Players[GetPlyIdx(MCI.Info[i].PLID)].UniqueID)].Cash"
into some kind of... Oh, forgot the name... Damn.... But some kind of Integrar should I say for now. For example:
Connections[GetConnIdx(Players[GetPlyIdx(MCI.Info[i].PLID)].UniqueID)].Cash == CashBonus;
Can anyone help me?
Thanks!