#how to make a area that heals all players inside of it?

1 messages · Page 1 of 1 (latest)

hexed siren
#

trying to make a lobotomy coorporation game.. which in the healing areas every few seconds it does one burst of healing to people inside

tawny geodeBOT
#

studio** You are now Level 6! **studio

potent frigate
#

make a big part Non-Collidable and check wehn a player Touches/Untouches the Part if they touch it make them heal, if they untouch it stop the heal

hexed siren
potent frigate
hexed siren
reef mason
#

or just like

potent frigate
#

table with the key being the player id

reef mason
#
local peopleinregion = {}

part.touched bla bla
table.insert(peopleinregion,player)

part untouched 
table.remove(peopleinregion,player)


while task.wait(1) do
  for _.v in peopleinregion do 
    heal
  end
#

pseudocode

mental sedge
#

the character is made up of multiple parts, each part can individually trigger .touched

hexed siren
mental sedge
#

could use zonesplus module instead which does all the hard stuff for you

#

also kinda depends if the area can move

potent frigate
#

maybe even add another loop which checks if people are still inside cause Untouched isn't really trustworthy sometimes

potent frigate
#

or check before every heal

potent frigate
mental sedge
#

its fine if you use it properly

potent frigate
mental sedge
potent frigate
#

op?

mental sedge
#

no debounce etc

#

yeah go figure, if you use something wrong, it doesn't work properly, i know, shocker.

potent frigate
#

oh thats what you mean

#

if you add a debounce to untouch wouldn't that just mean you can untouch -> touch -> untouch it fast to go around it 😭?

mental sedge
#

who'dve thought if you don't use it properly it doesn't work properly. truly an insight that needed to be said

mental sedge
potent frigate
#

how would that look like

mental sedge
#

if you were putting a classic / newbie debounce in touchended i mean that's probably why touchended didnt work for you

potent frigate
#

I just explained why that would be bad why should I have done that

fallow tangle
#

u can make a a part of the airspace, and a part when they exit. when they join the game, disable the built in roblox healing system, when they are in the airspace, enable it, when they touch the exit, disable it

potent frigate
#

alr i changed my mind, maybe it is trustworthyThumbs

hexed siren