Train Spawning with wagons - Printable Version
+- SA-MP Forums Archive (
https://sampforum.blast.hk)
+-- Forum: SA-MP Scripting and Plugins (
https://sampforum.blast.hk/forumdisplay.php?fid=8)
+--- Forum: Scripting Help (
https://sampforum.blast.hk/forumdisplay.php?fid=12)
+---- Forum: Help Archive (
https://sampforum.blast.hk/forumdisplay.php?fid=89)
+---- Thread: Train Spawning with wagons (
/showthread.php?tid=85783)
Train Spawning with wagons -
Hilax - 09.07.2009
Hey, I have another problem, this time its about trains.
1. Do i need to save the coordinates on the track so the train will spawn there? (on the tracks)
2. How do i attach the wagons to the locomotive? I think i need the AttachTrailerToVehicle command, but where do i have tio put it?
Oh, by the way, I want to spawn a freight train (with freight wagons)
thanks for your answers!
Hilax
Re: Train Spawning with wagons -
Rac3r - 09.07.2009
Basically spawn the train near the tracks and it will auto connect to the rails.
Yes, use AttachTrailerToVehicle to connect them. Make sure both vehicles are in the same world.
Simple.