_=Gigant=_
Well-known member
- Joined
- Mar 21, 2017
- Messages
- 353
- Reaction score
- 16
it requires moonloader v0.26
core:
open&close menu F5
its not finished but you can practice with it idk do what u want :iknowwhatyoudidthere:
k bye
core:
Code:
local imgui = require 'imgui'
local key = require 'vkeys'
local encoding = require 'encoding'
local sampev = require 'lib.samp.events'
require 'lib.moonloader'
local inicfg = require 'inicfg'
encoding.default = 'CP1251'
u8 = encoding.UTF8
function apply_custom_style() -- From FYP example imgui
imgui.SwitchContext()
local style = imgui.GetStyle()
local colors = style.Colors
local clr = imgui.Col
local ImVec4 = imgui.ImVec4
style.WindowRounding = 2.0
style.WindowTitleAlign = imgui.ImVec2(0.5, 0.84)
style.ChildWindowRounding = 2.0
style.FrameRounding = 2.0
style.ItemSpacing = imgui.ImVec2(5.0, 4.0)
style.ScrollbarSize = 13.0
style.ScrollbarRounding = 0
style.GrabMinSize = 8.0
style.GrabRounding = 1.0
-- style.Alpha =
-- style.WindowPadding =
-- style.WindowMinSize =
-- style.FramePadding =
-- style.ItemInnerSpacing =
-- style.TouchExtraPadding =
-- style.IndentSpacing =
-- style.ColumnsMinSpacing = ?
-- style.ButtonTextAlign =
-- style.DisplayWindowPadding =
-- style.DisplaySafeAreaPadding =
-- style.AntiAliasedLines =
-- style.AntiAliasedShapes =
-- style.CurveTessellationTol =
colors[clr.Text] = ImVec4(1.00, 1.00, 1.00, 1.00)
colors[clr.TextDisabled] = ImVec4(0.50, 0.50, 0.50, 1.00)
colors[clr.WindowBg] = ImVec4(0.06, 0.06, 0.06, 0.94)
colors[clr.ChildWindowBg] = ImVec4(1.00, 1.00, 1.00, 0.00)
colors[clr.PopupBg] = ImVec4(0.08, 0.08, 0.08, 0.94)
colors[clr.ComboBg] = colors[clr.PopupBg]
colors[clr.Border] = ImVec4(0.43, 0.43, 0.50, 0.50)
colors[clr.BorderShadow] = ImVec4(0.00, 0.00, 0.00, 0.00)
colors[clr.FrameBg] = ImVec4(0.16, 0.29, 0.48, 0.54)
colors[clr.FrameBgHovered] = ImVec4(0.26, 0.59, 0.98, 0.40)
colors[clr.FrameBgActive] = ImVec4(0.26, 0.59, 0.98, 0.67)
colors[clr.TitleBg] = ImVec4(0.04, 0.04, 0.04, 1.00)
colors[clr.TitleBgActive] = ImVec4(0.16, 0.29, 0.48, 1.00)
colors[clr.TitleBgCollapsed] = ImVec4(0.00, 0.00, 0.00, 0.51)
colors[clr.MenuBarBg] = ImVec4(0.14, 0.14, 0.14, 1.00)
colors[clr.ScrollbarBg] = ImVec4(0.02, 0.02, 0.02, 0.53)
colors[clr.ScrollbarGrab] = ImVec4(0.31, 0.31, 0.31, 1.00)
colors[clr.ScrollbarGrabHovered] = ImVec4(0.41, 0.41, 0.41, 1.00)
colors[clr.ScrollbarGrabActive] = ImVec4(0.51, 0.51, 0.51, 1.00)
colors[clr.CheckMark] = ImVec4(0.26, 0.59, 0.98, 1.00)
colors[clr.SliderGrab] = ImVec4(0.24, 0.52, 0.88, 1.00)
colors[clr.SliderGrabActive] = ImVec4(0.26, 0.59, 0.98, 1.00)
colors[clr.Button] = ImVec4(0.26, 0.59, 0.98, 0.40)
colors[clr.ButtonHovered] = ImVec4(0.26, 0.59, 0.98, 1.00)
colors[clr.ButtonActive] = ImVec4(0.06, 0.53, 0.98, 1.00)
colors[clr.Header] = ImVec4(0.26, 0.59, 0.98, 0.31)
colors[clr.HeaderHovered] = ImVec4(0.26, 0.59, 0.98, 0.80)
colors[clr.HeaderActive] = ImVec4(0.26, 0.59, 0.98, 1.00)
colors[clr.Separator] = colors[clr.Border]
colors[clr.SeparatorHovered] = ImVec4(0.26, 0.59, 0.98, 0.78)
colors[clr.SeparatorActive] = ImVec4(0.26, 0.59, 0.98, 1.00)
colors[clr.ResizeGrip] = ImVec4(0.26, 0.59, 0.98, 0.25)
colors[clr.ResizeGripHovered] = ImVec4(0.26, 0.59, 0.98, 0.67)
colors[clr.ResizeGripActive] = ImVec4(0.26, 0.59, 0.98, 0.95)
colors[clr.CloseButton] = ImVec4(0.41, 0.41, 0.41, 0.50)
colors[clr.CloseButtonHovered] = ImVec4(0.98, 0.39, 0.36, 1.00)
colors[clr.CloseButtonActive] = ImVec4(0.98, 0.39, 0.36, 1.00)
colors[clr.PlotLines] = ImVec4(0.61, 0.61, 0.61, 1.00)
colors[clr.PlotLinesHovered] = ImVec4(1.00, 0.43, 0.35, 1.00)
colors[clr.PlotHistogram] = ImVec4(0.90, 0.70, 0.00, 1.00)
colors[clr.PlotHistogramHovered] = ImVec4(1.00, 0.60, 0.00, 1.00)
colors[clr.TextSelectedBg] = ImVec4(0.26, 0.59, 0.98, 0.35)
colors[clr.ModalWindowDarkening] = ImVec4(0.80, 0.80, 0.80, 0.35)
end
apply_custom_style()
local btn_size = imgui.ImVec2(120, 0)
local main_window_state = imgui.ImBool(false)
local show_mp3 = imgui.ImBool(false)
local show_server_joiner = imgui.ImBool(false)
local show_settings = imgui.ImBool(false)
local show_help = imgui.ImBool(imgui.RenderInMenu)
local set_x, set_y = getScreenResolution()
local show_cursor = imgui.ImBool(imgui.ShowCursor)
local stats_bar = imgui.ImBool(false)
local arial_font = renderCreateFont('Arial', 10, 13)
local checkbox_bool = imgui.ImBool(false)
local gig_pic_credits = nil
local aniki_pic_credits = nil
local salvatore_pic_credits = nil
function imgui.OnDrawFrame()
local _, my_id = sampGetPlayerIdByCharHandle(PLAYER_PED)
local nick = sampGetPlayerNickname(my_id)
local hp = sampGetPlayerHealth(my_id)
local ping = sampGetPlayerPing(my_id)
local armour = sampGetPlayerArmor(my_id)
local score = sampGetPlayerScore(my_id)
local model = getCharModel(PLAYER_PED)
if main_window_state.v then
if imgui.BeginMainMenuBar() then
imgui.Text(u8(string.format('Welcome %s', nick)))
imgui.Text(' ')
if imgui.BeginMenu('Cheats') then
if imgui.BeginMenu('Player Cheats') then
if imgui.Button('God Mode') then
lua_thread.create(function()
while true do
wait (0)
setCharProofs(PLAYER_PED, 1, 1 ,1 ,1 ,1)
printStringNow('Activated', 1000)
end
end)
end
imgui.Button('Infinite Ammo')
imgui.Button('No Spread')
imgui.Button('No Fall')
if imgui.Button('Save Position') then
lua_thread.create(function()
end)
end
imgui.Button('Load Position')
imgui.Button('Fast Walk')
imgui.Button('Fast Deagle')
imgui.Button('Invisible')
imgui.Button('Surfer')
imgui.Button('Airbrk')
imgui.Button('Infinite Run')
imgui.Button('Mega Jump')
imgui.Button('Anti Stun')
imgui.Button('Set Health 95')
if imgui.Button('Jetpack') then
lua_thread.create(function()
end)
end
imgui.Button('Ghost Mode')
imgui.Button('Vehicle Collision')
if imgui.Button('Object Collision') then
lua_thread.create(function()
wait(0)
while true do
local meposX, meposY, meposZ = getCharCoordinates(PLAYER_PED)
local _, find_obj = findAllRandomObjectsInSphere(meposX, meposY, meposZ, 100, 1)
setObjectCollision(find_obj, 0)
end
end)
end
imgui.Button('Fast Deagle')
imgui.Button('Infinite Oxygen')
imgui.Button('Respawn')
imgui.Button('Reconnect')
if imgui.Button('Clear Chat') then
sampAddChatMessage('', -1)
sampAddChatMessage('', -1)
sampAddChatMessage('', -1)
sampAddChatMessage('', -1)
sampAddChatMessage('', -1)
sampAddChatMessage('', -1)
sampAddChatMessage('', -1)
sampAddChatMessage('', -1)
sampAddChatMessage('', -1)
sampAddChatMessage('', -1)
sampAddChatMessage('', -1)
sampAddChatMessage('', -1)
end
imgui.Text('')
imgui.Text('-------------ESP------------')
imgui.Text('')
if imgui.Button('Tracers') then
lua_thread.create(function()
wait (0)
for id= 0, 1000 do
local result = sampIsPlayerConnected(id)
local _, hand = sampGetCharHandleBySampPlayerId(id)
local PedPosX, PedPosY, PedPosZ = getCharCoordinates(hand)
local meposX, meposY, meposZ = getCharCoordinates(PLAYER_PED)
local GET_COORDS_X, GET_COORDS_Y = convert3DCoordsToScreen(PedPosX, PedPosY, PedPosZ)
local GET_COORDS_me_X, GET_COORDS_me_Y = convert3DCoordsToScreen(meposX, meposY, meposZ)
renderDrawLine(GET_COORDS_X, GET_COORDS_Y, GET_COORDS_me_X, GET_COORDS_me_Y, 2, 0xFF00FF00)
end
end)
end
imgui.Button('3D Box')
imgui.Button('2D Box')
imgui.Button('Draw Bones')
imgui.Button('Ping Point')
imgui.Button('Informer')
local drawText = false
if imgui.Button('Self Info Draw') then
drawText = not drawText
if drawText then
lua_thread.create(function()
while drawText do
wait (0)
local _, my_info = sampGetPlayerIdByCharHandle(PLAYER_PED)
local meposX, meposY, meposZ = getCharCoordinates(PLAYER_PED)
local GET_COORDS_X, GET_COORDS_Y = convert3DCoordsToScreen(meposX, meposY, meposZ)
local nick = sampGetPlayerNickname(my_info)
local hp = sampGetPlayerHealth(my_info)
local ping = sampGetPlayerPing(my_info)
local armour = sampGetPlayerArmor(my_info)
local score = sampGetPlayerScore(my_info)
local model = getCharModel(PLAYER_PED)
renderFontDrawText(arial_font, 'Pos X: '..meposX..' Y: '..meposY..' Z: '..meposZ, GET_COORDS_X , GET_COORDS_Y, 0xFF00FF00)
-- first line
renderFontDrawText(arial_font, 'Name: '..nick..' ID: '..my_info..' Skin: '..model, GET_COORDS_X , GET_COORDS_Y + 15, 0xFF00FF00)
-- second line
renderFontDrawText(arial_font, 'Health: '..hp..' Armour: '..armour, GET_COORDS_X, GET_COORDS_Y + 30, 0xFFFFFFFF)
-- third line
renderFontDrawText(arial_font, 'Score: '..score..' Ping: '..ping, GET_COORDS_X, GET_COORDS_Y + 45, 0xFFF0FF0F)
end
end)
end
end
imgui.Button('Weapon Info')
imgui.Button('Draw Skin IDs')
imgui.Text('')
imgui.EndMenu()
end
imgui.Text('')
if imgui.BeginMenu('Player Stats') then
imgui.Text(string.format('Player ID (%d)', my_id))
imgui.Text(string.format('Health (%d)', hp))
imgui.Text(string.format('Armour (%d)', armour))
imgui.Text(string.format('Ping (%d)', ping))
imgui.Text(string.format('Score (%d)', score))
imgui.Text(string.format('Skin (%d)', model))
if imgui.Button('Draw on screen') then
stats_bar.v = not stats_bar.v
end
imgui.EndMenu()
end
imgui.Text('')
if imgui.BeginMenu('Vehicle Cheats') then
imgui.Button('Car God')
imgui.Button('Easy Drive')
imgui.Button('Anti tire pop')
imgui.Button('Current Repair')
imgui.Button('Car Shot')
imgui.Button('BrkDance')
imgui.Button('Fast Exit [N]')
imgui.Button('Speed Car [LALT]')
imgui.Button('Car Jump [B]')
imgui.Button('Cars Info')
imgui.Button('Easy Drive')
imgui.Button('Rainbow')
imgui.Button('Cars IDs')
imgui.Button('Surfer')
imgui.EndMenu()
end
imgui.Text('')
if imgui.BeginMenu('Other Stuff') then
imgui.Button('Clean Screen')
imgui.Button('Radar')
imgui.Button('Hud')
imgui.EndMenu()
end
imgui.EndMenu()
end
if imgui.BeginMenu('Server Joiner') then
if imgui.BeginMenu('Freeroam') then
imgui.Text('Freeroam Servers List')
imgui.Text('')
if imgui.Button('UIF United Islands', btn_size) then
sampConnectToServer('51.254.85.134',7776)
end
if imgui.Button('xSF - Stunt Freeroam', btn_size) then
sampConnectToServer('samp.xsfserver.com',7777)
end
if imgui.Button('GamerX', btn_size) then
sampConnectToServer('188.165.219.63',8800)
end
if imgui.Button('Stunt Evolution Freeroam', btn_size) then
sampConnectToServer('138.201.184.48',7777)
end
if imgui.Button('Crazy Cops and Robbers', btn_size) then
sampConnectToServer('167.114.42.237',7777)
end
if imgui.Button('Los Santon Street Wars', btn_size) then
sampConnectToServer('94.130.79.93',7777)
end
if imgui.Button('Mini Games', btn_size) then
sampConnectToServer('149.202.65.49',7777)
end
if imgui.Button('Zombie Server', btn_size) then
sampConnectToServer('164.132.69.71',7750)
end
if imgui.Button('Impulse 99', btn_size) then
sampConnectToServer('5.135.179.214',7777)
end
if imgui.Button('GTA DayZ - Apocaliptic survival', btn_size) then
sampConnectToServer('145.239.226.55',7777)
end
if imgui.Button('Call Of Duty - Real World at War', btn_size) then
sampConnectToServer('137.74.148.231',7777)
end
if imgui.Button('UG - BASE Cheats Testing Server', btn_size) then
sampConnectToServer('79.133.50.48',7777)
end
imgui.EndMenu()
end
if imgui.BeginMenu('Roleplay') then
imgui.EndMenu()
end
imgui.EndMenu()
end
if imgui.BeginMenu('Teleports') then
imgui.EndMenu()
end
--MenuItem(const char* label, const char* shortcut, bool* p_selected, bool enabled = true);
if imgui.BeginMenu('NOPS') then
if imgui.BeginMenu('Disable Server Packets') then
imgui.EndMenu()
end
imgui.EndMenu()
end
if imgui.BeginMenu('UIF Protect the President Cheats') then
if imgui.BeginMenu('President') then
imgui.EndMenu()
end
if imgui.BeginMenu('Security') then
imgui.EndMenu()
end
if imgui.BeginMenu('Police') then
imgui.EndMenu()
end
if imgui.BeginMenu('Terrorists') then
imgui.EndMenu()
end
imgui.EndMenu()
end
if imgui.BeginMenu('MP3') then
if imgui.BeginMenu('Dance') then
if imgui.Button('Cross Arms') then
lua_thread.create(function()
-- local djcyka = loadAudioStream(getGameDirectory()..\\moonloader\\MultiHack Stuff\\Music\\DJCYKA.mp3)
-- setAudioStreamState(djcyka, 1)
-- setAudioStreamVolume(djcyka, 3.0)
end)
end
imgui.EndMenu()
end
if imgui.BeginMenu('Electro') then
imgui.EndMenu()
end
if imgui.BeginMenu('Relaxing') then
imgui.EndMenu()
end
if imgui.BeginMenu('Rap') then
imgui.EndMenu()
end
imgui.EndMenu()
end
if imgui.BeginMenu('Help') then
imgui.EndMenu()
end
if imgui.BeginMenu('Settings') then
imgui.EndMenu()
end
if imgui.BeginMenu('Animations') then
if imgui.BeginMenu('Player Anims') then
imgui.Button('Cross Arms')
-- bool = imgui.ImBool(false)
--imgui.CheckBox('Sit Boss', bool)
--imgui.CheckBox('Gang Walk 1', checkbox_bool)
--imgui.CheckBox('Gang Walk 2', checkbox_bool)
imgui.EndMenu()
end
imgui.EndMenu()
end
if imgui.BeginMenu('Mod Commads') then
imgui.Text('Clear Char /g.cc')
imgui.Text('Reconnect /g.rc')
imgui.Text('Reset Camera /g.rscam')
imgui.EndMenu()
end
if imgui.BeginMenu('Credits') then
imgui.Text('by _=Gigant=_')
gig_pic_credits = imgui.CreateTextureFromFile(getGameDirectory() .. '\\moonloader\\MultiHack Stuff\\Credits.jpg')
imgui.Image(gig_pic_credits, imgui.ImVec2(96, 96))
imgui.Text('Thanks to BH members')
imgui.Text('Aniki')
aniki_pic_credits = imgui.CreateTextureFromFile(getGameDirectory() .. '\\moonloader\\MultiHack Stuff\\anikii.jpg')
imgui.Image(aniki_pic_credits, imgui.ImVec2(96, 96))
imgui.Text('Salvatore_Ferrari')
salvatore_pic_credits = imgui.CreateTextureFromFile(getGameDirectory() .. '\\moonloader\\MultiHack Stuff\\salvatore.jpg')
imgui.Image(salvatore_pic_credits, imgui.ImVec2(96, 96))
imgui.EndMenu()
end
imgui.Text(' ')
imgui.Text(u8(string.format('%s', os.date())))
imgui.Text(' ')
local framerate = imgui.GetIO().Framerate
imgui.Text(string.format('FPS (%.1f)', framerate))
imgui.EndMainMenuBar()
end
end
if stats_bar.v then
-- imgui.SetNextWindowPos(imgui.ImVec2(set_x / 110, set_y / 2))
imgui.SetNextWindowSize(imgui.ImVec2(100, 120), imgui.Cond.FirstUseEver)
imgui.Begin('', stats_bar, imgui.WindowFlags.NoCollapse + imgui.WindowFlags.NoResize + imgui.WindowFlags.NoTitleBar)
imgui.Text(string.format('Player ID (%d)', my_id))
imgui.Text(string.format('Health (%d)', hp))
imgui.Text(string.format('Armour (%d)', armour))
imgui.Text(string.format('Ping (%d)', ping))
imgui.Text(string.format('Score (%d)', score))
imgui.Text(string.format('Skin (%d)', model))
imgui.End()
end
end
function main()
while true do
wait(0)
if wasKeyPressed(key.VK_F5) then
main_window_state.v = not main_window_state.v
end
imgui.Process = main_window_state.v
end
end
--Commands -----------------------
function cmd_cc()
if not isSampfuncsLoaded() or not isSampLoaded() then return end
while not isSampAvailable() do wait(100) end
sampRegisterChatCommand("g.cc", cmd_clear_chat)
while true do
wait(0)
end
end
function cmd_clear_chat()
sampAddChatMessage('', -1)
sampAddChatMessage('', -1)
sampAddChatMessage('', -1)
sampAddChatMessage('', -1)
sampAddChatMessage('', -1)
sampAddChatMessage('', -1)
sampAddChatMessage('', -1)
sampAddChatMessage('', -1)
sampAddChatMessage('', -1)
sampAddChatMessage('', -1)
sampAddChatMessage('', -1)
sampAddChatMessage('', -1)
sampAddChatMessage('', -1)
sampAddChatMessage('', -1)
end
function cmd_rsc()
if not isSampfuncsLoaded() or not isSampLoaded() then return end
while not isSampAvailable() do wait(100) end
sampRegisterChatCommand("g.rscam", cmd_reset_camera)
while true do
wait(0)
end
end
function cmd_clear_chat()
restoreCameraJumpcut()
end
open&close menu F5
its not finished but you can practice with it idk do what u want :iknowwhatyoudidthere:
k bye