Skip to content

Commit

Permalink
Update Source Code.lua
Browse files Browse the repository at this point in the history
  • Loading branch information
SimonBestia committed Jan 8, 2023
1 parent e38cd20 commit 326f6bc
Showing 1 changed file with 62 additions and 91 deletions.
153 changes: 62 additions & 91 deletions Scripts/Source Code.lua
Original file line number Diff line number Diff line change
Expand Up @@ -360,89 +360,52 @@ end

function SetupRoof()

local function CreatePersistentEntityAndInsert(model, x, y, z, r, a)
local PropID, PropPool = CreatePersistentEntity(model, x, y, z, r, a)
table.insert(TblRoofTopProps, {ID = PropID, Pool = PropPool})
end
-- Rooftop models
PropID, PropPool = CreatePersistentEntity('SC1b_fence_d', 186.021, -73.3169, 35.3693, 0, 0)
table.insert(TblRoofTopProps, {ID = PropID, Pool = PropPool})
PropID, PropPool = CreatePersistentEntity('SC1d_lad04', 190.857, -73.0157, 35.4244, 0, 0)
table.insert(TblRoofTopProps, {ID = PropID, Pool = PropPool})
PropID, PropPool = CreatePersistentEntity('SC1d_bldgmain_A', 191.754, -73.3854, 51.0535, 0, 0)
table.insert(TblRoofTopProps, {ID = PropID, Pool = PropPool})
PropID, PropPool = CreatePersistentEntity('SC_FanBlade03', 178.574, -73.157, 23.2994, 0, 0)
table.insert(TblRoofTopProps, {ID = PropID, Pool = PropPool})
PropID, PropPool = CreatePersistentEntity('SC_FanBlade02', 178.57, -73.1494, 23.1368, 0, 0)
table.insert(TblRoofTopProps, {ID = PropID, Pool = PropPool})
PropID, PropPool = CreatePersistentEntity('FGRD_SC1b20', 186.239, -73.3414, 34.9336, 0, 0)
table.insert(TblRoofTopProps, {ID = PropID, Pool = PropPool})
PropID, PropPool = CreatePersistentEntity('SC1d_bldgmain_wtr01', 186.087, -73.4308, 23.9015, 0, 0)
table.insert(TblRoofTopProps, {ID = PropID, Pool = PropPool})
PropID, PropPool = CreatePersistentEntity('SC1d_roofsteps', 195.981, -79.7682, 43.6757, 0, 0)
table.insert(TblRoofTopProps, {ID = PropID, Pool = PropPool})
PropID, PropPool = CreatePersistentEntity('DL_SC1d_L', 189.734, -72.4095, 33.7901, 0, 0)
table.insert(TblRoofTopProps, {ID = PropID, Pool = PropPool})
PropID, PropPool = CreatePersistentEntity('PR_AlleyLamp', 182.208, -67.7659, 29.8164, 0, 0)
table.insert(TblRoofTopProps, {ID = PropID, Pool = PropPool})
PropID, PropPool = CreatePersistentEntity('pxLad3M', 181.94, -64.992, 23.2626, 0, 0)
table.insert(TblRoofTopProps, {ID = PropID, Pool = PropPool})
PropID, PropPool = CreatePersistentEntity('pxLad4M', 186.38, -66.1529, 26.0975, 90, 0)
table.insert(TblRoofTopProps, {ID = PropID, Pool = PropPool})
PropID, PropPool = CreatePersistentEntity('Ladder_5M', 184.314, -80.2621, 35.6872, 90, 0)
table.insert(TblRoofTopProps, {ID = PropID, Pool = PropPool})
PropID, PropPool = CreatePersistentEntity('pxLad5M', 204.592, -67.2104, 30.3007, 0, 0)
table.insert(TblRoofTopProps, {ID = PropID, Pool = PropPool})
PropID, PropPool = CreatePersistentEntity('Scaffold', 178.173, -73.1613, 40.1403, 0, 0)
table.insert(TblRoofTopProps, {ID = PropID, Pool = PropPool})
PropID, PropPool = CreatePersistentEntity('Scaffold', 178.173, -73.1613, 35.2763, 0, 0)
table.insert(TblRoofTopProps, {ID = PropID, Pool = PropPool})
PropID, PropPool = CreatePersistentEntity('Scaffold', 178.173, -73.1613, 30.5194, 0, 0)
table.insert(TblRoofTopProps, {ID = PropID, Pool = PropPool})
PropID, PropPool = CreatePersistentEntity('Ladder_3M', 181.94, -65.028, 23.2625, 0, 0)
table.insert(TblRoofTopProps, {ID = PropID, Pool = PropPool})
PropID, PropPool = CreatePersistentEntity('Ladder_4M', 186.435, -66.1529, 26.0975, 90, 0)
table.insert(TblRoofTopProps, {ID = PropID, Pool = PropPool})
PropID, PropPool = CreatePersistentEntity('pxLad5M', 184.349, -80.2622, 35.6869, -90, 0)
table.insert(TblRoofTopProps, {ID = PropID, Pool = PropPool})
PropID, PropPool = CreatePersistentEntity('Ladder_5M', 204.592, -67.2498, 30.301, 0, 0)
table.insert(TblRoofTopProps, {ID = PropID, Pool = PropPool})
PropID, PropPool = CreatePersistentEntity('Ladder_4M', 186.002, -81.7648, 23.2896, 0, 0)
table.insert(TblRoofTopProps, {ID = PropID, Pool = PropPool})
PropID, PropPool = CreatePersistentEntity('pxLad4M', 186.002, -81.78, 23.2896, 180, 0)
table.insert(TblRoofTopProps, {ID = PropID, Pool = PropPool})
PropID, PropPool = CreatePersistentEntity('pxLad3M', 197.356, -81.2369, 29.6798, 90, 0)
table.insert(TblRoofTopProps, {ID = PropID, Pool = PropPool})
PropID, PropPool = CreatePersistentEntity('Ladder_3M', 197.398, -81.2371, 29.6798, 90, 0)
table.insert(TblRoofTopProps, {ID = PropID, Pool = PropPool})
PropID, PropPool = CreatePersistentEntity('pxLad3M', 199.835, -80.9096, 32.6819, 180, 0)
table.insert(TblRoofTopProps, {ID = PropID, Pool = PropPool})
PropID, PropPool = CreatePersistentEntity('Ladder_3M', 199.835, -80.881, 32.6818, 0, 0)
table.insert(TblRoofTopProps, {ID = PropID, Pool = PropPool})
PropID, PropPool = CreatePersistentEntity('SCBell', 197.159, -75.7203, 46.4597, 0, 0)
table.insert(TblRoofTopProps, {ID = PropID, Pool = PropPool})
PropID, PropPool = CreatePersistentEntity('SCBell', 191.725, -75.7203, 46.4597, 0, 0)
table.insert(TblRoofTopProps, {ID = PropID, Pool = PropPool})
PropID, PropPool = CreatePersistentEntity('SCBell', 191.725, -73.4447, 46.4597, 0, 0)
table.insert(TblRoofTopProps, {ID = PropID, Pool = PropPool})
PropID, PropPool = CreatePersistentEntity('SCBell', 186.275, -73.4447, 46.4597, 0, 0)
table.insert(TblRoofTopProps, {ID = PropID, Pool = PropPool})
PropID, PropPool = CreatePersistentEntity('SCBell', 186.275, -71.1643, 46.4597, 0, 0)
table.insert(TblRoofTopProps, {ID = PropID, Pool = PropPool})
PropID, PropPool = CreatePersistentEntity('BrickPile', 203.279, -66.6406, 30.7234, 0, 0)
table.insert(TblRoofTopProps, {ID = PropID, Pool = PropPool})
PropID, PropPool = CreatePersistentEntity('BrickPile01', 204.748, -77.8347, 36.1466, 0, 0)
table.insert(TblRoofTopProps, {ID = PropID, Pool = PropPool})
PropID, PropPool = CreatePersistentEntity('BrickPile02', 186.117, -79.5076, 36.1196, 0, 0)
table.insert(TblRoofTopProps, {ID = PropID, Pool = PropPool})
PropID, PropPool = CreatePersistentEntity('WALKTschoolRoofOP', 186.462, -73.2229, 37.8194, 0, 0)
table.insert(TblRoofTopProps, {ID = PropID, Pool = PropPool})
PropID, PropPool = CreatePersistentEntity('SCBell2', 197.159, -73.4447, 46.4597, 0, 0)
table.insert(TblRoofTopProps, {ID = PropID, Pool = PropPool})
PropID, PropPool = CreatePersistentEntity('SCBell2', 197.159, -71.1643, 46.4597, 0, 0)
table.insert(TblRoofTopProps, {ID = PropID, Pool = PropPool})
PropID, PropPool = CreatePersistentEntity('SCBell2', 191.722, -71.1643, 46.4597, 0, 0)
table.insert(TblRoofTopProps, {ID = PropID, Pool = PropPool})
PropID, PropPool = CreatePersistentEntity('SCBell2', 186.275, -75.7203, 46.4597, 0, 0)
table.insert(TblRoofTopProps, {ID = PropID, Pool = PropPool})
PropID, PropPool = CreatePersistentEntity('NOGO_tschoolRoofOP', 186.462, -73.2229, 30.3808, 0, 0)
table.insert(TblRoofTopProps, {ID = PropID, Pool = PropPool})
CreatePersistentEntityAndInsert('SC1b_fence_d', 186.021, -73.3169, 35.3693, 0, 0)
CreatePersistentEntityAndInsert('SC1d_lad04', 190.857, -73.0157, 35.4244, 0, 0)
CreatePersistentEntityAndInsert('SC1d_bldgmain_A', 191.754, -73.3854, 51.0535, 0, 0)
CreatePersistentEntityAndInsert('SC_FanBlade03', 178.574, -73.157, 23.2994, 0, 0)
CreatePersistentEntityAndInsert('SC_FanBlade02', 178.57, -73.1494, 23.1368, 0, 0)
CreatePersistentEntityAndInsert('FGRD_SC1b20', 186.239, -73.3414, 34.9336, 0, 0)
CreatePersistentEntityAndInsert('SC1d_bldgmain_wtr01', 186.087, -73.4308, 23.9015, 0, 0)
CreatePersistentEntityAndInsert('SC1d_roofsteps', 195.981, -79.7682, 43.6757, 0, 0)
CreatePersistentEntityAndInsert('DL_SC1d_L', 189.734, -72.4095, 33.7901, 0, 0)
CreatePersistentEntityAndInsert('PR_AlleyLamp', 182.208, -67.7659, 29.8164, 0, 0)
CreatePersistentEntityAndInsert('pxLad3M', 181.94, -64.992, 23.2626, 0, 0)
CreatePersistentEntityAndInsert('pxLad4M', 186.38, -66.1529, 26.0975, 90, 0)
CreatePersistentEntityAndInsert('Ladder_5M', 184.314, -80.2621, 35.6872, 90, 0)
CreatePersistentEntityAndInsert('pxLad5M', 204.592, -67.2104, 30.3007, 0, 0)
CreatePersistentEntityAndInsert('Scaffold', 178.173, -73.1613, 40.1403, 0, 0)
CreatePersistentEntityAndInsert('Scaffold', 178.173, -73.1613, 35.2763, 0, 0)
CreatePersistentEntityAndInsert('Scaffold', 178.173, -73.1613, 30.5194, 0, 0)
CreatePersistentEntityAndInsert('Ladder_3M', 181.94, -65.028, 23.2625, 0, 0)
CreatePersistentEntityAndInsert('Ladder_4M', 186.435, -66.1529, 26.0975, 90, 0)
CreatePersistentEntityAndInsert('pxLad5M', 184.349, -80.2622, 35.6869, -90, 0)
CreatePersistentEntityAndInsert('Ladder_5M', 204.592, -67.2498, 30.301, 0, 0)
CreatePersistentEntityAndInsert('Ladder_4M', 186.002, -81.7648, 23.2896, 0, 0)
CreatePersistentEntityAndInsert('pxLad4M', 186.002, -81.78, 23.2896, 180, 0)
CreatePersistentEntityAndInsert('pxLad3M', 197.356, -81.2369, 29.6798, 90, 0)
CreatePersistentEntityAndInsert('Ladder_3M', 197.398, -81.2371, 29.6798, 90, 0)
CreatePersistentEntityAndInsert('pxLad3M', 199.835, -80.9096, 32.6819, 180, 0)
CreatePersistentEntityAndInsert('Ladder_3M', 199.835, -80.881, 32.6818, 0, 0)
CreatePersistentEntityAndInsert('SCBell', 197.159, -75.7203, 46.4597, 0, 0)
CreatePersistentEntityAndInsert('SCBell', 191.725, -75.7203, 46.4597, 0, 0)
CreatePersistentEntityAndInsert('SCBell', 191.725, -73.4447, 46.4597, 0, 0)
CreatePersistentEntityAndInsert('SCBell', 186.275, -73.4447, 46.4597, 0, 0)
CreatePersistentEntityAndInsert('SCBell', 186.275, -71.1643, 46.4597, 0, 0)
CreatePersistentEntityAndInsert('BrickPile', 203.279, -66.6406, 30.7234, 0, 0)
CreatePersistentEntityAndInsert('BrickPile01', 204.748, -77.8347, 36.1466, 0, 0)
CreatePersistentEntityAndInsert('BrickPile02', 186.117, -79.5076, 36.1196, 0, 0)
CreatePersistentEntityAndInsert('WALKTschoolRoofOP', 186.462, -73.2229, 37.8194, 0, 0)
CreatePersistentEntityAndInsert('SCBell2', 197.159, -73.4447, 46.4597, 0, 0)
CreatePersistentEntityAndInsert('SCBell2', 197.159, -71.1643, 46.4597, 0, 0)
CreatePersistentEntityAndInsert('SCBell2', 191.722, -71.1643, 46.4597, 0, 0)
CreatePersistentEntityAndInsert('SCBell2', 186.275, -75.7203, 46.4597, 0, 0)
CreatePersistentEntityAndInsert('NOGO_tschoolRoofOP', 186.462, -73.2229, 30.3808, 0, 0)

Wait(1500)

Expand Down Expand Up @@ -844,7 +807,7 @@ KartChase = function()
TextPrintString('Quick! After him!', 2, 1)
F_ToggleHUDElements(true)
Wait(3500)
TextPrintString('HINT: Quickly press the ~x~ and ~o~ buttons to go faster.', 5, 1)
TextPrintString('HINT: Quickly press the ~x~ and ~s~ buttons to go faster.', 5, 1)
Wait(6000)

T_KartChaseConversation = CreateThread('T_KartChaseConversation')
Expand Down Expand Up @@ -1095,12 +1058,11 @@ BossBattle = function()
GameSetPedStat(Gary3, 4, 400)
PedSetHealth(Gary3, 400)
GameSetPedStat(Gary3, 5, 300) -- Refer to https://derpy54320.github.io/Bully-LUA-Reference/script/stats.html for these stats
GameSetPedStat(Gary3, 8, 800)
GameSetPedStat(Gary3, 12, 500)
GameSetPedStat(Gary3, 13, 60)
GameSetPedStat(Gary3, 20, 165)
GameSetPedStat(Gary3, 31, 10)
GameSetPedStat(Gary3, 63, 1)
GameSetPedStat(Gary3, 20, 165)
PedSetDamageGivenMultiplier(Gary3, 2, 1.1) -- Multiplies Gary's melee damage by 1.1
AddBlipForChar(Gary3, 0, 34, 4)
PedAttack(Gary3, gPlayer, 2) -- Self-explanatory, 2 sets the ped to ALWAYS attack a specific ped, even if another ped attacks him.
Expand Down Expand Up @@ -1165,11 +1127,22 @@ T_BossFightChecks = function()
end
PedGrappledByJimmy = PedGetGrappleTargetPed(gPlayer)
PedGrappledByGary = PedGetGrappleTargetPed(Gary)
if (PedIsValid(PedGrappledByJimmy) or PedIsValid(PedGrappledByAimingPed)) then
--TextPrintString("-DEBUG-\nSomeone's being grappled!\nGary Speed: "..GameGetPedStat(Gary, 20).."\nJimmy Speed: "..GameGetPedStat(gPlayer, 20), 1, 2)
--[[if DebugOn then
TextPrintString("-DEBUG-\nGary Stats:\n"..
"5: "..GameGetPedStat(Gary, 5)..
"\n8: "..GameGetPedStat(Gary, 8)..
"\n12: "..GameGetPedStat(Gary, 12)..
"\n13: "..GameGetPedStat(Gary, 13)..
"\n20: "..GameGetPedStat(Gary, 20)..
"\n31: "..GameGetPedStat(Gary, 31)..
"\n63: "..GameGetPedStat(Gary, 63)..
"\nHealth: "..PedGetHealth(Gary)..
"\n\nJimmy's:\n8: "..GameGetPedStat(gPlayer, 8)..
"\n20: "..GameGetPedStat(gPlayer, 20), 1, 2)
end]]
if (PedIsValid(PedGrappledByJimmy) or PedIsValid(PedGrappledByGary)) then
GameSetPedStat(Gary, 20, 130)
else
--TextPrintString("-DEBUG-\nNo one's grappling anyone!\nGary Speed: "..GameGetPedStat(Gary, 20).."\nJimmy Speed: "..GameGetPedStat(gPlayer, 20), 1, 2)
GameSetPedStat(Gary, 20, GaryOrigSpeed)
end
if F_PlayerIsDead() then
Expand Down Expand Up @@ -1356,12 +1329,11 @@ BossBattlePT2 = function()
PedSetInfiniteSprint(Gary4, true)
PedSetHealth(Gary4, 650)
GameSetPedStat(Gary4, 4, 650)
GameSetPedStat(Gary4, 8, 900)
GameSetPedStat(Gary4, 12, 400)
GameSetPedStat(Gary4, 13, 60)
GameSetPedStat(Gary4, 20, 170)
GameSetPedStat(Gary4, 31, 11)
GameSetPedStat(Gary4, 63, 1)
GameSetPedStat(Gary4, 20, 170)
PedSetPedToTypeAttitude(Gary4, 13, 2)
PedSetDamageGivenMultiplier(Gary4, 2, 1.35)
PedSetDamageTakenMultiplier(Gary4, 0, 0) -- Invulnerable to Projectiles
Expand Down Expand Up @@ -1526,7 +1498,6 @@ T_JohnnyDarbyGhosts = function()
PedSetAITree(Ghost.ped, Ghost.ai, Ghost.aifile..'.act')
EffectCreate('BottleRocketExplosion', X, Y, Z + 0.5)
GameSetPedStat(Ghost.ped, 20, 135)
GameSetPedStat(Ghost.ped, 8, 900)
GameSetPedStat(Ghost.ped, 62, 0)
PedSetDamageGivenMultiplier(Ghost.ped, 2, 1.35)
PedRecruitAlly(Gary4, Ghost.ped)
Expand Down

0 comments on commit 326f6bc

Please sign in to comment.