Hey, guys. I am having a problem with my vehicle scripting. I have a jeep, and an actor enters the vehicle as the driver just fine. I have a script set up to drive the jeep to a certain point if a member of the platoon enters a certain zone. I'm using the ProximityPlatoon trigger with a response of "Assign Jeep_Plan to Driver_Team and execute."
Now, the jeep plan has a Speed (8.0 m/s), Path (going in a straight line with no obstructions), and Orientation (facing the direction it will drive). I have also pointed the jeep itself to the direction that it will drive.
The problem is, when I get to the trigger zone, the jeep doesn't budge. The jeep is on a slight hill (maybe 30 degrees?) at the start - would this affect the movement? Any ideas are appreciated!
But what will effect it is that you've assigned the trigger plan to the driver. You need to assign it to the vehicle. You can do this using the ExecutePlanVehicle response, rather than the ExecutePlanTeam response you will currently have... Switch that and, assuming your scriptblock functions correctly, you should find it works.
Incidentally, check (using the Vehicle Editor in Igor) what the max speed of a jeep is - coz I think it's less than 8 m/s. You shouldn't set the vehicle speed in a plan to be greater than the maximum speed of the vehicle - remember also that not explicitly setting a speed for the vehicle will make it move at it's maximum speed by default. If you want to increase the max speed of a vehicle, you'll have to mod the vehicle attributes - I recommend that you save your modded vehicle as another filename however, so that it doesn't alter any missions in the orginal game.
Have a look at what I did with the jeep on the mission I emailed you - I created a new jeep for that one coz I wanted it to be faster.
Thanks, Gav! I used ExecutePlanTeam because I was trying to recreate what we had done in the workshop HHour gave Wednesday night. I'll change it to ExecutePlanVehicle tonight. I'm sure that's the only problem.
Sounds like I should remove the Speed plan from the vehicle as well, unless, like you recommend, I want to mod it. Good stuff.
Normally it is teams that you give trigger plans to, so I can understand why he showed you that, rather than Vehicle. But there's an exception to every rule, and this is it!
I'm fairly sure that's the only thing wrong, from what you described above. Hope it works!
I tried to put two vehicles right next to each other (M35 Truck) and scripted them each to drive in parallel paths. I pointed both of them south, yet they were always facing each other and didn't budge, so I had to space them out a bit. Then they'd drive together. Weird!
Remember that when you place a vehicle (or actor, or anything really), you set an exact point for them as their initial location. But, in reality, the vehicles have a certain size that you have to take into account when placing things, so you have to space them out a bit.
Glad you got it working! You'll normally find that most of your problems like that will be stupid little things that are annoying, but easily fixed once you discover what the problem is! Feel free to post any other questions you might have!