vehicle falls off and penetrates the map, what's the problem? #5442
Unanswered
phoenixsfly
asked this question in
Q&A
Replies: 3 comments
-
Please attach the code too. |
Beta Was this translation helpful? Give feedback.
0 replies
-
import carla
import random
client = carla.Client('localhost', 2000)
world = client.get_world()
maplst = client.get_available_maps()
# Load my map
client.load_world(maplst[-1])
# Reload current map and reset state
client.reload_world()
world.get_names_of_all_objects()
vehicle_bps = world.get_blueprint_library().filter('*vehicle*')
vehicle_bp = random.choice(vehicle_bps)
spawn_point = random.choice(world.get_map().get_spawn_points())
ego_vehicle=world.spawn_actor(vehicle_bp, spawn_point)
|
Beta Was this translation helpful? Give feedback.
0 replies
-
If you go by random choice then it would happen. You have to choose location and spawn the vehicle on that particular location. |
Beta Was this translation helpful? Give feedback.
0 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
I try to spwan a vehicle, but it falls off and penetrates the map, what's the problem?
The Map was generated by Roadrunner and ingested in Carla packages by Docker
Beta Was this translation helpful? Give feedback.
All reactions