Package zombie

Class GameTime

java.lang.Object
zombie.GameTime

public final class GameTime extends Object
  • Field Details

    • instance

      public static GameTime instance
    • MULTIPLIER

      public static final float MULTIPLIER
      See Also:
    • TimeOfDay

      public float TimeOfDay
    • NightsSurvived

      public int NightsSurvived
    • Calender

      public PZCalendar Calender
    • FPSMultiplier

      public float FPSMultiplier
    • Moon

      public float Moon
    • ServerTimeOfDay

      public float ServerTimeOfDay
    • ServerLastTimeOfDay

      public float ServerLastTimeOfDay
    • ServerNewDays

      public int ServerNewDays
    • lightSourceUpdate

      public float lightSourceUpdate
    • multiplierBias

      public float multiplierBias
    • LastLastTimeOfDay

      public float LastLastTimeOfDay
    • PerObjectMultiplier

      public float PerObjectMultiplier
  • Constructor Details

    • GameTime

      public GameTime()
  • Method Details

    • getInstance

      public static GameTime getInstance()
    • setInstance

      public static void setInstance(GameTime aInstance)
    • syncServerTime

      public static void syncServerTime(long timeClientSend, long timeServer, long timeClientReceive)
    • getServerTime

      public static long getServerTime()
    • getServerTimeMills

      public static long getServerTimeMills()
    • getServerTimeShiftIsSet

      public static boolean getServerTimeShiftIsSet()
    • setServerTimeShift

      public static void setServerTimeShift(long tshift)
    • receiveTimeSync

      public static void receiveTimeSync(ByteBuffer bb, UdpConnection connection)
    • getRealworldSecondsSinceLastUpdate

      public float getRealworldSecondsSinceLastUpdate()
    • getMultipliedSecondsSinceLastUpdate

      public float getMultipliedSecondsSinceLastUpdate()
    • getGameWorldSecondsSinceLastUpdate

      public float getGameWorldSecondsSinceLastUpdate()
    • daysInMonth

      public int daysInMonth(int year, int month)
    • getDeathString

      public String getDeathString(IsoPlayer playerObj)
    • getDaysSurvived

      public int getDaysSurvived()
    • getTimeSurvived

      public String getTimeSurvived(IsoPlayer playerObj)
    • getZombieKilledText

      public String getZombieKilledText(IsoPlayer playerObj)
    • getGameModeText

      public String getGameModeText()
    • init

      public void init()
    • Lerp

      public float Lerp(float start, float end, float delta)
    • RemoveZombiesIndiscriminate

      public void RemoveZombiesIndiscriminate(int i)
    • TimeLerp

      public float TimeLerp(float startVal, float endVal, float startTime, float endTime)
    • getDeltaMinutesPerDay

      public float getDeltaMinutesPerDay()
    • getNightMin

      public float getNightMin()
    • setNightMin

      public void setNightMin(float min)
    • getNightMax

      public float getNightMax()
    • setNightMax

      public void setNightMax(float max)
    • getMinutes

      public int getMinutes()
    • setMoon

      public void setMoon(float moon)
    • update

      public void update(boolean bSleeping)
    • getMinutesStamp

      public long getMinutesStamp()
    • getThunderStorm

      public boolean getThunderStorm()
    • getAmbient

      @Deprecated public float getAmbient()
      Deprecated.
      Returns:
      the Ambient
    • setAmbient

      public void setAmbient(float Ambient)
      Parameters:
      Ambient - the Ambient to set
    • getAmbientMax

      public float getAmbientMax()
      Returns:
      the AmbientMax
    • setAmbientMax

      public void setAmbientMax(float AmbientMax)
      Parameters:
      AmbientMax - the AmbientMax to set
    • getAmbientMin

      public float getAmbientMin()
      Returns:
      the AmbientMin
    • setAmbientMin

      public void setAmbientMin(float AmbientMin)
      Parameters:
      AmbientMin - the AmbientMin to set
    • getDay

      public int getDay()
      Returns:
      the Day
    • getDayPlusOne

      public int getDayPlusOne()
    • setDay

      public void setDay(int Day)
      Parameters:
      Day - the Day to set
    • getStartDay

      public int getStartDay()
      Returns:
      the StartDay
    • setStartDay

      public void setStartDay(int StartDay)
      Parameters:
      StartDay - the StartDay to set
    • getMaxZombieCountStart

      public float getMaxZombieCountStart()
      Returns:
      the MaxZombieCountStart
    • setMaxZombieCountStart

      public void setMaxZombieCountStart(float MaxZombieCountStart)
      Parameters:
      MaxZombieCountStart - the MaxZombieCountStart to set
    • getMinZombieCountStart

      public float getMinZombieCountStart()
      Returns:
      the MinZombieCountStart
    • setMinZombieCountStart

      public void setMinZombieCountStart(float MinZombieCountStart)
      Parameters:
      MinZombieCountStart - the MinZombieCountStart to set
    • getMaxZombieCount

      public float getMaxZombieCount()
      Returns:
      the MaxZombieCount
    • setMaxZombieCount

      public void setMaxZombieCount(float MaxZombieCount)
      Parameters:
      MaxZombieCount - the MaxZombieCount to set
    • getMinZombieCount

      public float getMinZombieCount()
      Returns:
      the MinZombieCount
    • setMinZombieCount

      public void setMinZombieCount(float MinZombieCount)
      Parameters:
      MinZombieCount - the MinZombieCount to set
    • getMonth

      public int getMonth()
      Returns:
      the Month
    • setMonth

      public void setMonth(int Month)
      Parameters:
      Month - the Month to set
    • getStartMonth

      public int getStartMonth()
      Returns:
      the StartMonth
    • setStartMonth

      public void setStartMonth(int StartMonth)
      Parameters:
      StartMonth - the StartMonth to set
    • getNightTint

      public float getNightTint()
      Returns:
      the NightTint
    • setNightTint

      public void setNightTint(float NightTint)
      Parameters:
      NightTint - the NightTint to set
    • getNight

      public float getNight()
      Returns:
      the NightTint
    • setNight

      public void setNight(float NightTint)
      Parameters:
      NightTint - the NightTint to set
    • getTimeOfDay

      public float getTimeOfDay()
      Returns:
      the TimeOfDay
    • setTimeOfDay

      public void setTimeOfDay(float TimeOfDay)
      Parameters:
      TimeOfDay - the TimeOfDay to set
    • getStartTimeOfDay

      public float getStartTimeOfDay()
      Returns:
      the StartTimeOfDay
    • setStartTimeOfDay

      public void setStartTimeOfDay(float StartTimeOfDay)
      Parameters:
      StartTimeOfDay - the StartTimeOfDay to set
    • getViewDist

      public float getViewDist()
      Returns:
      the ViewDist
    • getViewDistMax

      public float getViewDistMax()
      Returns:
      the ViewDistMax
    • setViewDistMax

      public void setViewDistMax(float ViewDistMax)
      Parameters:
      ViewDistMax - the ViewDistMax to set
    • getViewDistMin

      public float getViewDistMin()
      Returns:
      the ViewDistMin
    • setViewDistMin

      public void setViewDistMin(float ViewDistMin)
      Parameters:
      ViewDistMin - the ViewDistMin to set
    • getYear

      public int getYear()
      Returns:
      the Year
    • setYear

      public void setYear(int Year)
      Parameters:
      Year - the Year to set
    • getStartYear

      public int getStartYear()
      Returns:
      the StartYear
    • setStartYear

      public void setStartYear(int StartYear)
      Parameters:
      StartYear - the StartYear to set
    • getNightsSurvived

      public int getNightsSurvived()
      Returns:
      the NightsSurvived
    • setNightsSurvived

      public void setNightsSurvived(int NightsSurvived)
      Parameters:
      NightsSurvived - the NightsSurvived to set
    • getWorldAgeHours

      public double getWorldAgeHours()
    • getHoursSurvived

      public double getHoursSurvived()
      Returns:
      the HoursSurvived
    • setHoursSurvived

      public void setHoursSurvived(double HoursSurvived)
      Parameters:
      HoursSurvived - the HoursSurvived to set
    • getHour

      public int getHour()
    • getCalender

      public PZCalendar getCalender()
      Returns:
      the Calender
    • setCalender

      public void setCalender(PZCalendar Calender)
      Parameters:
      Calender - the Calender to set
    • updateCalendar

      public void updateCalendar(int year, int month, int dayOfMonth, int hourOfDay, int minute)
    • getMinutesPerDay

      public float getMinutesPerDay()
      Returns:
      the MinutesPerDay
    • setMinutesPerDay

      public void setMinutesPerDay(float MinutesPerDay)
      Parameters:
      MinutesPerDay - the MinutesPerDay to set
    • getLastTimeOfDay

      public float getLastTimeOfDay()
      Returns:
      the LastTimeOfDay
    • setLastTimeOfDay

      public void setLastTimeOfDay(float LastTimeOfDay)
      Parameters:
      LastTimeOfDay - the LastTimeOfDay to set
    • setTargetZombies

      public void setTargetZombies(int TargetZombies)
      Parameters:
      TargetZombies - the TargetZombies to set
    • isRainingToday

      public boolean isRainingToday()
      Returns:
      the RainingToday
    • getMultiplier

      public float getMultiplier()
      Returns:
      the Multiplier
    • getTimeDelta

      public float getTimeDelta()
    • getAnimSpeedFix

      public static float getAnimSpeedFix()
    • setMultiplier

      public void setMultiplier(float Multiplier)
      Parameters:
      Multiplier - the Multiplier to set
    • getServerMultiplier

      public float getServerMultiplier()
    • getUnmoddedMultiplier

      public float getUnmoddedMultiplier()
    • getInvMultiplier

      public float getInvMultiplier()
    • getTrueMultiplier

      public float getTrueMultiplier()
    • save

      public void save()
    • save

      public void save(DataOutputStream output) throws IOException
      Throws:
      IOException
    • save

      public void save(ByteBuffer output) throws IOException
      Throws:
      IOException
    • load

      public void load(DataInputStream input) throws IOException
      Throws:
      IOException
    • load

      public void load(ByteBuffer input) throws IOException
      Throws:
      IOException
    • load

      public void load()
    • getDawn

      public int getDawn()
    • setDawn

      public void setDawn(int dawn)
    • getDusk

      public int getDusk()
    • setDusk

      public void setDusk(int dusk)
    • getModData

      public se.krka.kahlua.vm.KahluaTable getModData()
    • isThunderDay

      public boolean isThunderDay()
    • setThunderDay

      public void setThunderDay(boolean thunderDay)
    • saveToPacket

      public void saveToPacket(ByteBuffer bb) throws IOException
      Throws:
      IOException
    • getHelicopterDay1

      public int getHelicopterDay1()
    • getHelicopterDay

      public int getHelicopterDay()
    • setHelicopterDay

      public void setHelicopterDay(int day)
    • getHelicopterStartHour

      public int getHelicopterStartHour()
    • setHelicopterStartHour

      public void setHelicopterStartHour(int hour)
    • getHelicopterEndHour

      public int getHelicopterEndHour()
    • setHelicopterEndHour

      public void setHelicopterEndHour(int hour)
    • isGamePaused

      public static boolean isGamePaused()