added 3 new effects:
new file: Peds/PedsRainingCatsAndDogs.lua new file: Screen/ScreenBlind.lua new file: Screen/ScreenThreeDeeGlasses.lua
This commit is contained in:
45
Peds/PedsRainingCatsAndDogs.lua
Normal file
45
Peds/PedsRainingCatsAndDogs.lua
Normal file
@@ -0,0 +1,45 @@
|
|||||||
|
EffectInfo = {
|
||||||
|
Name = "Its Raining Cats And Dogs",
|
||||||
|
EffectId = "peds_rainingcatsanddogs",
|
||||||
|
TimedType = "Normal",
|
||||||
|
EffectGroup = "_group_spawngeneric",
|
||||||
|
EffectCategory = "None"
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
function OnStart()
|
||||||
|
DisplayHelpText("No animals were harmed in this effect.", 8)
|
||||||
|
test = {"g", "y"}
|
||||||
|
spawned_animals = {}
|
||||||
|
end
|
||||||
|
|
||||||
|
function OnStop()
|
||||||
|
end
|
||||||
|
|
||||||
|
function OnTick()
|
||||||
|
animals = {"a_c_cat_01", "a_c_chop", "a_c_husky", "a_c_poodle", "a_c_pug", "a_c_rottweiler_02", "a_c_retriever", "a_c_westy", "a_c_shepherd", "a_c_rottweiler"}
|
||||||
|
animalModel = GET_HASH_KEY(random_choice(animals))
|
||||||
|
playerPed = PLAYER_PED_ID()
|
||||||
|
heading = GET_ENTITY_HEADING(playerPed)
|
||||||
|
coords = GET_OFFSET_FROM_ENTITY_IN_WORLD_COORDS(playerPed, math.random(75), math.random(75), math.random(75))
|
||||||
|
animal = CreatePoolPed(0, animalModel, coords.x, coords.y, coords.z, heading)
|
||||||
|
SET_ENTITY_INVINCIBLE(animal, true)
|
||||||
|
TASK_REACT_AND_FLEE_PED(animal, playerPed)
|
||||||
|
SET_BLOCKING_OF_NON_TEMPORARY_EVENTS(animal, true)
|
||||||
|
table.insert(spawned_animals, animal)
|
||||||
|
WAIT(math.random(1500, 6000))
|
||||||
|
if #spawned_animals > 50 then
|
||||||
|
for animal in spawned_animals do
|
||||||
|
if DOES_ENTITY_EXIST(animal) then
|
||||||
|
DELETE_ENTITY(Holder(animal))
|
||||||
|
table.remove(spawned_animals, animal)
|
||||||
|
end
|
||||||
|
end
|
||||||
|
end
|
||||||
|
end
|
||||||
|
|
||||||
|
|
||||||
|
function random_choice(p1)
|
||||||
|
choice = p1[math.random(#p1)]
|
||||||
|
return choice
|
||||||
|
end
|
18
Screen/ScreenBlind.lua
Normal file
18
Screen/ScreenBlind.lua
Normal file
@@ -0,0 +1,18 @@
|
|||||||
|
EffectInfo = {
|
||||||
|
Name = "Blindness",
|
||||||
|
EffectId = "screen_blindness",
|
||||||
|
TimedType = "Short",
|
||||||
|
EffectGroup = "_group_shader",
|
||||||
|
EffectCategory = "Shader",
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
function OnStart()
|
||||||
|
end
|
||||||
|
|
||||||
|
function OnStop()
|
||||||
|
end
|
||||||
|
|
||||||
|
function OnTick()
|
||||||
|
DRAW_RECT(0.5, 0.5, 1.0, 1.0, 0, 0, 0, 255)
|
||||||
|
end
|
19
Screen/ScreenThreeDeeGlasses.lua
Normal file
19
Screen/ScreenThreeDeeGlasses.lua
Normal file
@@ -0,0 +1,19 @@
|
|||||||
|
EffectInfo = {
|
||||||
|
Name = "3D Glasses",
|
||||||
|
EffectId = "screen_threedeeglasses",
|
||||||
|
TimedType = "Normal",
|
||||||
|
EffectGroup = "_group_shader",
|
||||||
|
EffectCategory = "Shader",
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
function OnStart()
|
||||||
|
end
|
||||||
|
|
||||||
|
function OnStop()
|
||||||
|
end
|
||||||
|
|
||||||
|
function OnTick()
|
||||||
|
DRAW_RECT(1.0, 0.5, 1.0, 1.0, 0, 0, 255, 168)
|
||||||
|
DRAW_RECT(0.0, 0.5, 1.0, 1.0, 255, 0, 0, 168)
|
||||||
|
end
|
Reference in New Issue
Block a user