-
Notifications
You must be signed in to change notification settings - Fork 4.7k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
15 changed files
with
169 additions
and
11 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,34 @@ | ||
import setup_path | ||
import airsim | ||
|
||
|
||
client = airsim.VehicleClient() | ||
client.confirmConnection() | ||
|
||
client.simEnableWeather(True) | ||
|
||
airsim.wait_key('Press any key to enable rain at 25%') | ||
client.simSetWeatherParameter(airsim.WeatherParameter.Rain, 0.25); | ||
|
||
airsim.wait_key('Press any key to enable rain at 75%') | ||
client.simSetWeatherParameter(airsim.WeatherParameter.Rain, 0.75); | ||
|
||
airsim.wait_key('Press any key to enable snow at 50%') | ||
client.simSetWeatherParameter(airsim.WeatherParameter.Snow, 0.50); | ||
|
||
airsim.wait_key('Press any key to enable maple leaves at 50%') | ||
client.simSetWeatherParameter(airsim.WeatherParameter.MapleLeaf, 0.50); | ||
|
||
airsim.wait_key('Press any key to set all effects to 0%') | ||
client.simSetWeatherParameter(airsim.WeatherParameter.Rain, 0.0); | ||
client.simSetWeatherParameter(airsim.WeatherParameter.Snow, 0.0); | ||
client.simSetWeatherParameter(airsim.WeatherParameter.MapleLeaf, 0.0); | ||
|
||
airsim.wait_key('Press any key to enable dust at 50%') | ||
client.simSetWeatherParameter(airsim.WeatherParameter.Dust, 0.50); | ||
|
||
airsim.wait_key('Press any key to enable fog at 50%') | ||
client.simSetWeatherParameter(airsim.WeatherParameter.Fog, 0.50); | ||
|
||
airsim.wait_key('Press any key to disable all weather effects') | ||
client.simEnableWeather(False) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Oops, something went wrong.