#module breaks when player dies

1 messages · Page 1 of 1 (latest)

elder forum
#

i have a bunch of functions in a module that are connected mostly under runservice.renderstepped

#

it works when you spawn for the first time

#

but if you die each function "disconnects" and wont activate again

#

before converting stuff to modules i would use a playeradded and characteradded connection in localscripts which worked fine

crimson bane
#

where have you put the local scripts ?

#

i had the same problem when i had the local scripts on startegui but when i put it on starterCharacter it fixed

elder forum
#

theyre module scripts

#

i have them in starterplayerscripts

crimson bane
#

ok

elder forum
#

@fickle elbow would you be able to help me with this?

#

or are you busy

daring spoke
#

the script has to do with the player character, also can you show the error message

daring spoke
#

Roblox automatically disconnects all events if the instance is destroyed.

elder forum
#

it was just me explaining it

#

there is no error message, and also nothing is getting destroyed

daring spoke
#

Wait

#

Where did you put the local script (not the module)

elder forum
#

starterplayerscripts

#

it might be because of that actually

#

I'll try putting it in startercharacterscripts when I get back from school

elder forum
#

that was the issue yeah

#

sorry for the late response

#

module breaks when player dies (solved)

#

module breaks when player dies

elder forum
#

only some of the things work properly