Darren-NYPD Posted October 20, 2016 Report Share Posted October 20, 2016 Hi, I wanted to add new Police parking bays but In a different place on the map due to the fact of having another small police station. I did search the forum numerous times and there were some topics which served a bit of a guide, (doing what was written, still got errors). I modified the GotoPolicestation.script in the se partsAdded this: const char VO_POLICE09[] = "police_park09";added 19 here: GameObjectList l1, l2, l3, l4, l5, l6, l7, l8, 19; Copied this from an existent and modified it: Game::CollectObstaclesOnVirtualObject(VO_POLICE09, l9, ACTOR_VEHICLE); if(l9.GetNumObjects() == 0) { list1 = Game::GetActors(VO_POLICE09); list2 = Game::GetActors(VO_POLICE_FP2); ParkinglotFound = true; } } if (!ParkinglotFound) { Added this: else if (v.IsCollidingWithVirtualObject(VO_POLICE09)) return; When I send units to Police Station the game pops up and error stating that ther is a problem in line... gameobjects 19 something like that? (I also did the parking bay (virtual object) in map) police_park09 RE: Parking direction that is not a problem I know what to do hehe. Quote Link to comment Share on other sites More sharing options...
itchboy Posted October 20, 2016 Report Share Posted October 20, 2016 Its a typo on your part. The gameobject you added is 19 but the gameobject the park code refers to is l9. Quote Link to comment Share on other sites More sharing options...
Darren-NYPD Posted October 20, 2016 Author Report Share Posted October 20, 2016 Sorry, I didn't understand :(... anything I should fix from those parts? Quote Link to comment Share on other sites More sharing options...
itchboy Posted October 20, 2016 Report Share Posted October 20, 2016 Quote added 19 here: GameObjectList l1, l2, l3, l4, l5, l6, l7, l8, 19; Your mistake is here. You mistyped the 'l9' as '19'. Quote Link to comment Share on other sites More sharing options...
Darren-NYPD Posted October 20, 2016 Author Report Share Posted October 20, 2016 ahhhh....... Worked great now... Thanks a lot Quote Link to comment Share on other sites More sharing options...