How do you create a hud element?
-
As the title suggests, I want to know the function of a hud element in zombies that displays a counter from a variable
-
As the title suggests, I want to know the function of a hud element in zombies that displays a counter from a variable
Vulture Aid You can create it using this:
self.Text = createFontString ("Objective", 1.7); // Only client-- to Server Message use createServerFontString self.Text setPoint ("CENTER", "TOP", 300, "CENTER"); // Position self.Text setText ("Your text here"); // Message -
Vulture Aid You can create it using this:
self.Text = createFontString ("Objective", 1.7); // Only client-- to Server Message use createServerFontString self.Text setPoint ("CENTER", "TOP", 300, "CENTER"); // Position self.Text setText ("Your text here"); // MessageKalitos Can you specify the arguments for
createFontString()andsetPoint()? -
Kalitos Can you specify the arguments for
createFontString()andsetPoint()?Vulture Aid
createFontString(font, fontScale),setPoint(point, relativePoint, x, y).fonthas a few different options like"default", and"objective".fontScaleis self explanatory, it's the scale of the font lol.pointandrelativePointare a bit different though. There's"CENTER", "TOP", "BOTTOM", "LEFT", "RIGHT", "TOPRIGHT", "TOP_RIGHT", "TOPLEFT", "TOP_LEFT", "TOPCENTER", "BOTTOM RIGHT", "BOTTOM_RIGHT", "BOTTOM LEFT", "BOTTOM_LEFT".
You can kind of think of these as anchors. If I made a HUD with points"RIGHT", "RIGHT"and I appended text to it constantly, the HUD would grow to the left to maintain its position on the right.