public class WeatherSystem
System for handling weather mechanics. Systems contain game logic that operates on entities with specific component types.
java.lang.Object > WeatherSystem
Field Summary
forcedWeather
final
String
forcedWeather
Field forcedWeather.
weatherTrackerComponent
final
WeatherTracker
weatherTrackerComponent
Field weatherTrackerComponent.
weatherResource
final
WeatherResource
weatherResource
Field weatherResource.
worldTimeResource
final
WorldTimeResource
worldTimeResource
Field worldTimeResource.
currentHour
final
int
currentHour
Field currentHour.
environmentWeather
final
Int2IntMap
environmentWeather
Field environmentWeather.
random
final
ThreadLocalRandom
random
Field random.
key
final
String
key
Field key.
index
final
int
index
Field index.
weatherForecast
final
IWeightedMap
weatherForecast
Field weatherForecast.
selectedWeatherIndex
final
int
selectedWeatherIndex
Field selectedWeatherIndex.
weatherResource2
final
WeatherResource
weatherResource2
Field weatherResource2.
playerRefComponent
final
PlayerRef
playerRefComponent
Field playerRefComponent.
transformComponent
final
TransformComponent
transformComponent
Field transformComponent.
transitionSeconds
final
float
transitionSeconds
Field transitionSeconds.
Method Detail
WorldAddedSystem
public
public
WorldAddedSystem
()
Method WorldAddedSystem.
onEntityAdd
public
void
onEntityAdd
(@Nonnull final Holder holder, @Nonnull final AddReason reason, @Nonnull final Store store)
Method onEntityAdd.
- Parameters:
@Nonnull final Holderholder@Nonnull final AddReasonreason@Nonnull final Storestore
onEntityRemoved
public
void
onEntityRemoved
(@Nonnull final Holder holder, @Nonnull final RemoveReason reason, @Nonnull final Store store)
Method onEntityRemoved.
- Parameters:
@Nonnull final Holderholder@Nonnull final RemoveReasonreason@Nonnull final Storestore
isParallel
public
boolean
isParallel
(final int archetypeChunkSize, final int taskCount)
Method isParallel.
- Parameters:
final intarchetypeChunkSizefinal inttaskCount
componentType
public
Teleport>
componentType
()
Method componentType.
onComponentAdded
public
void
onComponentAdded
(@NonNullDecl final Ref ref, @NonNullDecl final Teleport component, @NonNullDecl final Store store, @NonNullDecl final CommandBuffer commandBuffer)
Method onComponentAdded.
- Parameters:
@NonNullDecl final Refref@NonNullDecl final Teleportcomponent@NonNullDecl final Storestore@NonNullDecl final CommandBuffercommandBuffer
onComponentSet
public
void
onComponentSet
(@NonNullDecl final Ref ref, @NullableDecl final Teleport oldComponent, @NonNullDecl final Teleport newComponent, @NonNullDecl final Store store, @NonNullDecl final CommandBuffer commandBuffer)
Method onComponentSet.
- Parameters:
@NonNullDecl final Refref@NullableDecl final TeleportoldComponent@NonNullDecl final TeleportnewComponent@NonNullDecl final Storestore@NonNullDecl final CommandBuffercommandBuffer
onComponentRemoved
public
void
onComponentRemoved
(@NonNullDecl final Ref ref, @NonNullDecl final Teleport component, @NonNullDecl final Store store, @NonNullDecl final CommandBuffer commandBuffer)
Method onComponentRemoved.
- Parameters:
@NonNullDecl final Refref@NonNullDecl final Teleportcomponent@NonNullDecl final Storestore@NonNullDecl final CommandBuffercommandBuffer
getDependencies
public
Set>
getDependencies
()
Method getDependencies.
SystemDependency
public
new
SystemDependency
(Order.AFTER, TeleportSystems.PlayerMoveSystem.class)
Method SystemDependency.
- Parameters:
Order.AFTEROrder.AFTERTeleportSystems.PlayerMoveSystem.classTeleportSystems.PlayerMoveSystem.class