Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- //Read More @ http://www.nextgenupdate.com/forums/showthread.php?t=732747
- public class HudStruct
- {
- public static uint
- ElemIndex = Offsets.G_HudElems,
- HudsLength = 0x88,
- X = 0x00,
- Y = 0x04,
- Z = 0x08,
- FontSize = 0xC,
- fromFontScale = 0x10,
- fontScaleStartTime = 0x14,
- color = 0x18,
- fromColor = 0x1C,
- fadeStartTime = 0x20,
- scaleStartTime = 0x24,
- fromX = 0x28,
- fromY = 0x2C,
- moveStartTime = 0x30,
- time = 0x34,
- duration = 0x38,
- value = 0x3C,
- sort = 0x40,
- glowColor = 0x44,
- fxBirthTime = 0x48,
- flags = 0x4C,
- targetEntNum = 0x50,
- fontScaleTime = 0x52,
- fadeTime = 0x54,
- label = 0x56,
- Width = 0x58,
- Height = 0x5A,
- fromWidth = 0x5C,
- fromHeight = 0x5E,
- scaleTime = 0x60,
- moveTime = 0x62,
- text = 0x64,
- fxLetterTime = 0x66,
- fxDecayStartTime = 0x68,
- fxDecayDuration = 0x6A,
- fxRedactDecayStartTime = 0x6C,
- fxRedactDecayDuration = 0x6E,
- type = 0x70,
- Font = 0x71,
- alignOrg = 0x72,
- alignScreen = 0x73,
- materialIndex = 0x74,
- offscreenMaterialIndex = 0x75,
- fromAlignOrg = 0x76,
- fromAlignScreen = 0x77,
- soundID = 0x78,
- ui3dWindow = 0x79,
- flag2 = 0x7A,
- clientOffset = 0x7C,
- team = 0x80,
- abilityFlag = 0x84;
- }
- public static UInt32 GetLevelTime()
- {
- public static uint
- level_locals_t = 0x1608100,
- LevelTime = level_locals_t + 0x798;
- return Lib.ReadUInt32(LevelTime);
- }
- public static int SetTimer(UInt32 elemIndex, Int32 Time = 60, String Direction = "Up", Boolean Tenths = true)
- {
- if (Lib.ReadByte(elemIndex + HudStruct.type) != 0x8 && Direction == "Up" && !Tenths)
- { Lib.WriteByte(elemIndex + HudStruct.type, 0xA); }
- if (Lib.ReadByte(elemIndex + HudStruct.type) != 0x8 && Direction == "Up" && Tenths)
- { Lib.WriteByte(elemIndex + HudStruct.type, 0xC); }
- if (Lib.ReadByte(elemIndex + HudStruct.type) != 0x8 && Direction == "Down" && !Tenths)
- { Lib.WriteByte(elemIndex + HudStruct.type, 0x9); }
- if (Lib.ReadByte(elemIndex + HudStruct.type) != 0x8 && Direction == "Down" && Tenths)
- { Lib.WriteByte(elemIndex + HudStruct.type, 0xB); }
- if (Direction == "Up")
- { Lib.WriteInt32(elemIndex + HudStruct.time, (Int32)GetLevelTime() - (Time * 1000)); return (Int32)GetLevelTime() - (Time * 1000); }
- if (Direction == "Down")
- { Lib.WriteInt32(elemIndex + HudStruct.time, (Int32)GetLevelTime() + (Time * 1000)); return (Int32)GetLevelTime() + (Time * 1000); }
- return 0;
- }
- public static int SetClock(UInt32 elemIndex, Int32 Duration = 60, Int32 Time = 60, String Direction = "Up")
- {
- if (Lib.ReadByte(elemIndex + HudStruct.type) != 0x1 && Direction == "Up")
- { Lib.WriteByte(elemIndex + HudStruct.type, 0xE); }
- if (Lib.ReadByte(elemIndex + HudStruct.type) != 0x1 && Direction == "Down")
- { Lib.WriteByte(elemIndex + HudStruct.type, 0xD); }
- if (Direction == "Up")
- {
- Lib.WriteInt32(elemIndex + HudStruct.duration, Duration * 1000);
- Lib.WriteInt32(elemIndex + HudStruct.time, (Int32)GetLevelTime() - (Time * 1000));
- return (Int32)GetLevelTime() - (Time * 1000);
- }
- if (Direction == "Down")
- {
- Lib.WriteInt32(elemIndex + HudStruct.duration, Duration * 1000);
- Lib.WriteInt32(elemIndex + HudStruct.time, (Int32)GetLevelTime() + (Time * 1000));
- return (Int32)GetLevelTime() + (Time * 1000);
- }
- return 0;
- }
Advertisement
Add Comment
Please, Sign In to add comment