AntiFiter
|
  |
| Joined: 14 May 2009 |
| Total Posts: 12290 |
|
|
| 06 Sep 2014 02:14 PM |
I am going to make a script to spawn cars in around a city. What I need to know is how do I check if a car that was spawned 5 minutes ago hasn't been used yet, so I don't spawn another right on top of it.
On a sidenote, I also want to de-spawn cars. Like before, I need to check if it hasn't been used for, let's say, 10 minutes. Has roblox made a argument for this? |
|
|
| Report Abuse |
|
|
AntiFiter
|
  |
| Joined: 14 May 2009 |
| Total Posts: 12290 |
|
| |
|
AntiFiter
|
  |
| Joined: 14 May 2009 |
| Total Posts: 12290 |
|
| |
|
AntiFiter
|
  |
| Joined: 14 May 2009 |
| Total Posts: 12290 |
|
|
| 06 Sep 2014 04:54 PM |
| and if nothing is in the spot of where I want to spot a car |
|
|
| Report Abuse |
|
|
AntiFiter
|
  |
| Joined: 14 May 2009 |
| Total Posts: 12290 |
|
| |
|
AntiFiter
|
  |
| Joined: 14 May 2009 |
| Total Posts: 12290 |
|
| |
|
maxomega3
|
  |
| Joined: 11 Jun 2010 |
| Total Posts: 10668 |
|
|
| 06 Sep 2014 05:52 PM |
| Have a script inside the car, where if it has someone driving it (which you can find out with the SeatWeld), then signal the spawn script to spawn where it was created. |
|
|
| Report Abuse |
|
|
AntiFiter
|
  |
| Joined: 14 May 2009 |
| Total Posts: 12290 |
|
| |
|
maxomega3
|
  |
| Joined: 11 Jun 2010 |
| Total Posts: 10668 |
|
| |
|
AntiFiter
|
  |
| Joined: 14 May 2009 |
| Total Posts: 12290 |
|
|
| 06 Sep 2014 05:58 PM |
I think seatweld dissapears so I'd have to make a boolvalue to see if someone has ever used it
but still they might of only sat in it, and the car could still be there |
|
|
| Report Abuse |
|
|
maxomega3
|
  |
| Joined: 11 Jun 2010 |
| Total Posts: 10668 |
|
| |
|
AntiFiter
|
  |
| Joined: 14 May 2009 |
| Total Posts: 12290 |
|
|
| 06 Sep 2014 06:24 PM |
Yep.
I may have to use Magnitude (or whatever the argument was) to make sure the already spawned car isn't right on the "spawn zone". |
|
|
| Report Abuse |
|
|
| |
|
AntiFiter
|
  |
| Joined: 14 May 2009 |
| Total Posts: 12290 |
|
| |
|