-
Автор темы
- #1
Сделаю фулл нл пак для любителей нла когда мне купят доширак
JavaScript:
//
UI.AddCheckbox(["Visuals", "World", "General"], "Hot-Keys");
UI.AddCheckbox(["Visuals", "World", "General"], "Spectator-List");
UI.AddColorPicker(["Visuals", "World", "General"], "Header Text Color");
UI.AddColorPicker(["Visuals", "World", "General"], "Active Text Color");
UI.AddColorPicker(["Visuals", "World", "General"], "Logo Color");
UI.AddColorPicker(["Visuals", "World", "General"], "Top Bar Color");
UI.AddColorPicker(["Visuals", "World", "General"], "Bottom Bar Color");
UI.SetColor(["Visuals", "World", "General", "Bottom Bar Color"], [2, 23, 37, 255 ]);
UI.SetColor(["Visuals", "World", "General", "Top Bar Color"], [4, 13, 25, 255 ]);
UI.SetColor(["Visuals", "World", "General", "Logo Color"], [45, 121, 126, 255]);
UI.SetColor(["Visuals", "World", "General", "Active Text Color"], [255, 255, 255, 255]);
UI.SetColor(["Visuals", "World", "General", "Header Text Color"], [255, 255, 255, 255]);
//
const Binds_x = UI.AddSliderInt(["Visuals", "World", "General"], "Binds_x", 0, Render.GetScreenSize()[0])
const Binds_y = UI.AddSliderInt(["Visuals", "World", "General"], "Binds_y", 0, Render.GetScreenSize()[0])
const Bindss_x = UI.AddSliderInt(["Visuals", "World", "General"], "Bindss_x", +40, Render.GetScreenSize()[0])
const Bindss_y = UI.AddSliderInt(["Visuals", "World", "General"], "Bindss_y", +40, Render.GetScreenSize()[1])
UI.SetEnabled(["Visuals", "World", "General", "Binds_x"], 1)
UI.SetEnabled(["Visuals", "World", "General", "Binds_y"], 1)
UI.SetEnabled(["Visuals", "World", "General", "Bindss_x"], 1)
UI.SetEnabled(["Visuals", "World", "General", "Bindss_y"], 1)
var screensize = Render.GetScreenSize();
//
function in_bounds(vec, x, y, x2, y2)
{
return (vec[0] > x) && (vec[1] > y) && (vec[0] < x2) && (vec[1] < y2)
}
function values(name) {
var value = UI.GetValue(["Visuals", "World", "General", name]);
return value;
}
function HotkeyersXD() {
const x = UI.GetValue(["Visuals", "World", "General", "Binds_x"]),
y = UI.GetValue(["Visuals", "World", "General", "Binds_y"]);
//Color
Color = UI.GetColor(["Visuals", "World", "General", "Header Text Color"]);
Color2 = UI.GetColor(["Visuals", "World", "General", "Active Text Color"]);
ColorLogo = UI.GetColor(["Visuals", "World", "General", "Logo Color"]);
ColorTop = UI.GetColor(["Visuals", "World", "General", "Top Bar Color"]);
ColorBottom = UI.GetColor(["Visuals", "World", "General", "Bottom Bar Color"]);
var h = [];
if (UI.GetValue(["Rage", "Anti Aim", "Key assignment", "Slow walk"])) {
h.push("Slow walk")
}
if (UI.GetValue(["Rage", "Anti Aim", "Key assignment", "Fake duck"])) {
h.push("Fake Duck")
}
if (UI.GetValue(["Misc.", "Keys", "General", "Key assignment", "Auto peek"])) {
h.push("Auto peek")
}
if (UI.GetValue(["Rage", "Anti Aim", "Key assignment", "AA Direction inverter"])) {
h.push("Anti-Aim invert")
}
if (UI.GetValue(["Rage", "General", "Key assignment", "Force safe point"])) {
h.push("Safe point override")
}
if (UI.GetValue(["Rage", "General", "Key assignment", "Force body aim"])) {
h.push("Force body aim")
}
if (UI.GetValue(["Rage", "Exploits", "Keys", "Key assignment", "Double tap"])) {
h.push("Doubletap")
}
if (UI.GetValue(["Rage", "Exploits", "Keys", "Key assignment", "Hide shots"])) {
h.push("Hide shots")
}
if (UI.GetValue(["Legit", "General", "Key assignment", "Triggerbot activation"])) {
h.push("Triggerbot")
}
if (UI.GetValue(["Misc.", "Keys", "General", "Key assignment", "Thirdperson"])) {
h.push("3rd View")
}
if (UI.GetValue(["Rage", "Anti Aim", "Key assignment", "Left direction"])) {
h.push("Left direction")
}
if (UI.GetValue(["Rage", "Anti Aim", "Key assignment", "Back direction"])) {
h.push("Back direction")
}
if (UI.GetValue(["Rage", "Anti Aim", "Key assignment", "Right direction"])) {
h.push("Right direction")
}
if (!UI.GetValue(["Visuals", "World", "General", "Hot-Keys"]))
return;
//Light bottom
Render.FilledRect(x + 78, y + 26, 250, 60 + 30 * (h.length - 1), ColorBottom);
//Dark Top rectangle
Render.FilledRect( x + 78, y + 26, 250, 30, ColorTop );
//Logo
Render.Circle( x + 94, y + 39, 6, ColorLogo );
Render.Circle( x + 94, y + 39, 9, ColorLogo );
Render.Circle( x + 94, y + 39, 3, ColorLogo );
//Line top
Render.Line( x + 93, y + 30, x + 93, y + 36, ColorLogo);
Render.Line( x + 94, y + 30, x + 94, y + 36, ColorLogo);
Render.Line( x + 95, y + 30, x + 95, y + 36, ColorLogo);
//Line bottom
Render.Line( x + 95, y + 42, x + 95, y + 48, ColorLogo);
Render.Line( x + 94, y + 42, x + 94, y + 48, ColorLogo);
Render.Line( x + 93, y + 42, x + 93, y + 48, ColorLogo);
//line left
Render.Line( x + 85, y + 38, x + 91, y + 38, ColorLogo);
Render.Line( x + 85, y + 39, x + 91, y + 39, ColorLogo);
Render.Line( x + 85, y + 40, x + 91, y + 40, ColorLogo);
//Line Right
Render.Line( x + 97, y + 38, x + 103, y + 38, ColorLogo);
Render.Line( x + 97, y + 39, x + 103, y + 39, ColorLogo);
Render.Line( x + 97, y + 40, x + 103, y + 40, ColorLogo);
//Binds text
Render.String(x + 110, y + 33, 0, "Binds", Color, 4, 3);
//Logo ENd
//Render Active Keybind
for (i = 0; i < h.length; i++) {
Render.String(x + 80, y + 65 + 25 * i, 0, h[i], Color2,4, 3);
Render.String(x + 273, y + 65 + 25 * i, 0, "toggled", Color2,4, 3);
}
//Move menu
if (Global.IsKeyPressed(1)) {
const mouse_pos = Global.GetCursorPosition();
if (in_bounds(mouse_pos, x, y, x + 320, y + 110)) {
if (UI.IsMenuOpen( ) == false)
return;
UI.SetValue(["Visuals", "World", "General", "Binds_x"], mouse_pos[0] - 200);
UI.SetValue(["Visuals", "World", "General", "Binds_y"], mouse_pos[1] - 60);
}
}
}
function get_spectators() {
var specs = [];
const players = Entity.GetPlayers();
for (i = 0; i < players.length; i++) {
const cur = players[i];
if (Entity.GetProp(cur, "CBasePlayer", "m_hObserverTarget") != "m_hObserverTarget") {
const obs = Entity.GetProp(cur, "CBasePlayer", "m_hObserverTarget")
if (obs === Entity.GetLocalPlayer())
{
const name = Entity.GetName(cur);
specs.push(name);
}}}
return specs;
}
function Spectatorss() {
const names = get_spectators();
const x = UI.GetValue(["Visuals", "World", "General", "Bindss_x"]),
y = UI.GetValue(["Visuals", "World", "General", "Bindss_y"]);
//Color
Color = UI.GetColor(["Visuals", "World", "General", "Header Text Color"]);
Color2 = UI.GetColor(["Visuals", "World", "General", "Active Text Color"]);
ColorLogo = UI.GetColor(["Visuals", "World", "General", "Logo Color"]);
ColorTop = UI.GetColor(["Visuals", "World", "General", "Top Bar Color"]);
ColorBottom = UI.GetColor(["Visuals", "World", "General", "Bottom Bar Color"]);
if (!UI.GetValue(["Visuals", "World", "General", "Spectator-List"]))
return;
//Light bottom
Render.FilledRect(x + 78, y + 26, 125, 60 + 30 * (names.length - 1), ColorBottom);
//Dark Top rectangle
Render.FilledRect( x + 78, y + 26, 125, 30, ColorTop );
//Logo
Render.Circle( x + 94, y + 39, 6, ColorLogo );
Render.Circle( x + 94, y + 39, 9, ColorLogo );
Render.Circle( x + 94, y + 39, 3, ColorLogo );
//Line top
Render.Line( x + 93, y + 30, x + 93, y + 40, ColorLogo);
Render.Line( x + 94, y + 30, x + 94, y + 40, ColorLogo);
Render.Line( x + 95, y + 30, x + 95, y + 40, ColorLogo);
//Line bottom
Render.Line( x + 95, y + 42, x + 95, y + 48, ColorLogo);
Render.Line( x + 94, y + 42, x + 94, y + 48, ColorLogo);
Render.Line( x + 93, y + 42, x + 93, y + 48, ColorLogo);
//line left
Render.Line( x + 85, y + 38, x + 91, y + 38, ColorLogo);
Render.Line( x + 85, y + 39, x + 91, y + 39, ColorLogo);
Render.Line( x + 85, y + 40, x + 91, y + 40, ColorLogo);
//Line Right
Render.Line( x + 97, y + 38, x + 103, y + 38, ColorLogo);
Render.Line( x + 97, y + 39, x + 103, y + 39, ColorLogo);
Render.Line( x + 97, y + 40, x + 103, y + 40, ColorLogo);
//Spectators text
Render.String(x + 120, y + 33, 0, "Spectators", Color, 4, 3);
//Logo ENd
//Render Active Keybind
for (i = 0; i < names.length; i++){
Render.String(x + 80, y + 65 + 25 * i, 0, names[i], [255, 255, 255, 255],4, 3);
}
//Move menu
if (Global.IsKeyPressed(1)) {
const mouse_pos = Global.GetCursorPosition();
if (in_bounds(mouse_pos, x + 50, y + 20, x + 220, y + 60)) {
if (UI.IsMenuOpen( ) == false)
return;
UI.SetValue(["Visuals", "World", "General", "Bindss_x"], mouse_pos[0] - 140);
UI.SetValue(["Visuals", "World", "General", "Bindss_y"], mouse_pos[1] - 35);
}
}
}
Global.RegisterCallback("Draw", "Spectatorss");
Global.RegisterCallback("Draw", "HotkeyersXD");