script_author("egor")
require "lib.moonloader"
local encoding = require 'encoding'
encoding.default = 'CP1251'
--func = require 'module' -- подключить модуль
local function codinat()
local res = isCharInAnyCar(PLAYER_PED) -- 00DF: actor $PLAYER_ACTOR driving
if res
then local car = storeCarCharIsIn(PLAYER_PED)
local x, y, z = getCarCoordinates(car) -- 00AA: store_car 0@ position_to 3@ 4@ 5@
else
local x, y, z = getCharCoordinates(PLAYER_PED) -- получить координаты cj
return x,y,z
end
end
local function zomb(ped)
taskKillCharOnFoot(ped, PLAYER_PED) -- 05E2: AS_actor 65@ kill_actor 50@
shutCharUpForScriptedSpeech(ped, 1) -- 0A09: set_actor 0@ muted 1
--setCharDecisionMaker(ped, 32) -- 060B: set_actor 0@ decision_maker_to 32
--setAnimGroupForChar(ped, "OLDMAN")--0245: set_actor 0@ walk_style_to "OLDMAN"
-- giveWeaponToChar(ped, 0,0) -- 01B2: give_actor 0@ weapon 0 ammo 0
-- removeAllCharWeapons(ped) -- 048F: actor 0@ remove_weapons
end
function main()
while true do
wait(0)
res = testCheat("mn")--0ADC: test_cheat "BLOWUP"
if res
then printStringNow("star", 1000)-- вывод текста
while isPlayerPlaying(PLAYER_HANDLE) or res1 do wait(100)-- отключить если игрок умер или чит no
x,y,z = codinat()
res1 = testCheat("no")--выключить зомби
if res1
then printStringNow("end", 1000)
break
else res, ped = findAllRandomCharsInSphere(x,y,z, 40.3, 0, 1) -- 0AE1: $actor = random_actor_near_point 0@ 1@ 2@ in_radius 10.0 find_next 1 pass_deads 1
zomb(ped)
end end
break
end end
end