Wind
Wind
dataclass
¶
Wind(
velocity: Optional[Union[float, Velocity]] = None,
direction_from: Optional[Union[float, Angular]] = None,
until_distance: Optional[Union[float, Distance]] = None,
*,
max_distance_feet: Optional[
float
] = cMaxWindDistanceFeet,
)
Describe wind in effect over a particular down-range distance.
Attributes:
Name | Type | Description |
---|---|---|
velocity |
Velocity
|
speed of wind |
direction_from |
Angular
|
0 is blowing from behind shooter. 90 degrees is blowing from shooter's left towards right. |
until_distance |
Distance
|
until which distance the specified wind blows |
MAX_DISTANCE_FEET |
float
|
Optional custom max wind distance |
Parameters:
Name | Type | Description | Default |
---|---|---|---|
velocity
|
Optional[Union[float, Velocity]]
|
speed of wind |
None
|
direction_from
|
Optional[Union[float, Angular]]
|
0 is blowing from behind shooter. 90 degrees is blowing from shooter's left towards right. |
None
|
until_distance
|
Optional[Union[float, Distance]]
|
until which distance the specified wind blows |
None
|
max_distance_feet
|
Optional[float]
|
Optional custom max wind distance |
cMaxWindDistanceFeet
|
Example
from py_ballisticcalc import Wind
wind = Wind(
velocity=Unit.FPS(2700),
direction_from=Unit.Degree(20)
)
Source code in py_ballisticcalc/conditions.py
466 467 468 469 470 471 472 473 474 475 476 477 478 479 480 481 482 483 484 485 486 487 488 489 490 491 492 493 494 495 |
|