Skip to content
View in the app

A better way to browse. Learn more.

Learn more

LAChase

Featured Replies

Firstoff, can someone upload an unmodified version of LAChase.script for me... I've jacked mine up... Installed a second copy of 1.9 as a backup so I can always have a fresh copy. I was attempting to set random values for:

 				int Money = Mission::GetMoneyLeft();
int NewMoney = Money + 300;
Mission::SetMoney(NewMoney);
Mission::PlayHint("Driver fined for speeding. You earned 300 credits!");

My goal was it to say something random like "Fined for expired registration and other things... I tried with if else (random == 1) and this did not work among other different variations... What would the ideal way be to go about having the "PlayHint" change to a random list simply for realistic purpose?

Try this instead of your code:

		int Money = Mission::GetMoneyLeft();
int Fine;
int Chance = Math::rand() % 3;
if (Chance == 0)
{
Fine = 300;
Mission::PlayHint("Driver fined for speeding. You earned 300 credits!");
}
else if (Chance == 1)
{
Fine = 400;
Mission::PlayHint("Blabla!");
}
else if (Chance == 2)
{
Fine = 500;
Mission::PlayHint("BlablaBla!");
}
else
{
Fine = 600;
Mission::PlayHint("BlaBlaBlaBla!");
}
int NewMoney = Money + Fine;
Mission::SetMoney(NewMoney);

Let me know what you made out of it, I might add it to the mod. :)

  • Author

Exactly what I wanted! I tried the exact something just with a few different patterns with different things for each else if. This is what I have mine set up now. Nothing major... just something for more than just speeding...

		int Money = Mission::GetMoneyLeft();
int Fine;
int Chance = Math::rand() % 4;
if (Chance == 0)
{
Fine = 300;
Mission::PlayHint("Driver fined for speeding. You've earned 300 credits!");
}
else if (Chance == 1)
{
Fine = 200;
Mission::PlayHint("Driver fined for expired registration stick. You've earned 200 credits!");
}
else if (Chance == 2)
{
Fine = 200;
Mission::PlayHint("Driver fined for a missing tail light. You've earned 200 credits!");
}
else if (Chance == 3)
{
Fine = 600;
Mission::PlayHint("Driver fined for failure to use a seatbelt. You've earned 600 credits!");
}
int NewMoney = Money + Fine;
Mission::SetMoney(NewMoney);

Exactly what I wanted! I tried the exact something just with a few different patterns with different things for each else if. This is what I have mine set up now. Nothing major... just something for more than just speeding...

		int Money = Mission::GetMoneyLeft();
int Fine;
int Chance = Math::rand() % 4;
if (Chance == 0)
{
Fine = 300;
Mission::PlayHint("Driver fined for speeding. You've earned 300 credits!");
}
else if (Chance == 1)
{
Fine = 200;
Mission::PlayHint("Driver fined for expired registration stick. You've earned 200 credits!");
}
else if (Chance == 2)
{
Fine = 200;
Mission::PlayHint("Driver fined for a missing tail light. You've earned 200 credits!");
}
else if (Chance == 3)
{
Fine = 600;
Mission::PlayHint("Driver fined for failure to use a seatbelt. You've earned 600 credits!");
}
int NewMoney = Money + Fine;
Mission::SetMoney(NewMoney);

i apologize for asking it here, but how do i add the chase command to the game, im using project reality lights and it of course isnt made for LA MOD v1.9 so how do i add it in?

^you dont hijack the thread, and ask in the thread you already started.

i apologize for asking it here, but how do i add the chase command to the game, im using project reality lights and it of course isnt made for LA MOD v1.9 so how do i add it in?

You need to add the command to all the police cars in the editor.

Exactly what I wanted! I tried the exact something just with a few different patterns with different things for each else if. This is what I have mine set up now. Nothing major... just something for more than just speeding...

Thanks, do you mind if I add these changes to the mod?

  • Author
Thanks, do you mind if I add these changes to the mod?

Of course. I could not find a website that listed the real ticket prices for said violations... :/ But I'd like to add more so it's more realistic when playing.

Well its been awhile since I got a speeding ticket, and the last one I got was BS, but thats another story. I cant speak for LA, but here the system is set up something like this:

1-60 MPH over speed limits is like $75

60-120 MPH over is like $120 and mandatory Defensive Driving.

Something along that lines.

Well its been awhile since I got a speeding ticket, and the last one I got was BS, but thats another story. I cant speak for LA, but here the system is set up something like this:

1-60 MPH over speed limits is like $75

60-120 MPH over is like $120 and mandatory Defensive Driving.

Something along that lines.

I need to move where you live because the last ticket I got was for 15 MPH over the limit and it was $175

If you do add this to the mode make sure that you correct the expired registration hint. It says "expired registration stick". I presume he ment to say "expired registration" or "expired registration sticker".

  • Author

Haha, yeah. I noticed I did that too while playing it one day. I fixed it in my version but was more interested if anyone would catch the typo on here. -gives billyfromhill a cookie.-

Yeah, I really don't think realistic prices will be of any benefit. I mean... We could set tiers like... "Speeding in a School Zone" or "Speeding in a Construction Zone" both of which carry pretty hefty fines (double) where I live.

I need to move where you live because the last ticket I got was for 15 MPH over the limit and it was $175

Well thats been about 6 years ago, so my prices might be off, or they may have gone up since then.

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Reply to this topic...

Configure browser push notifications

Chrome (Android)
  1. Tap the lock icon next to the address bar.
  2. Tap Permissions → Notifications.
  3. Adjust your preference.
Chrome (Desktop)
  1. Click the padlock icon in the address bar.
  2. Select Site settings.
  3. Find Notifications and adjust your preference.