#beginner needs help with scripting gui !!
1 messages · Page 1 of 1 (latest)
ok let me grab the scripts
the player has is given 3 charges of their ability at the start in this code
this is what's inside of StarterGUI and handles the white fill parts of the three star shaped charges on the screen
only problem is idk how to actually make the visiblity false
the original starburst script does have the attribrute
use part.AttributeChanged to detect when the charge amount is increased or decreased
its pretty simple once u got it lmao
my brian
brain
is Melted
i dont know where to even put that
or what "part" is supposed to be
part is whatever the attribute is on
so the "starburst" script
** You are now Level 1! **
and u would want to place the detection in the gui script
outside of the function just do
part.AttributeChanged:Connect(setChargeAmountGUI)
i literally don't know what im doing
** You are now Level 12! **
whenever an attribute on "part" is changed, it will send a signal to the function to start working
the part is a script though
its fine
it was taken from an example using a part
well this isn't working
but it just requires an instance
wait
put it below the function
its startercharacterscripts
not starterplayer whoops
ok it looks like this
i get no errors but the gui doesnt change
look for the scripts in player.Character
the original attribute does change because when i tell it to print it prints the new attribute value
any scripts that are in StarterCharacterScripts will need to be found on the actual character when u start ur game
same goes for starterplayerscripts
yeah?
well they're there
There aren’t any scripts in starterplayerscripts
I don’t even know what that’s for
change ur "starburst" variable to be player.Character.Starburst.Starburst
Woah that did something
** You are now Level 2! **
i have the starburst gui to have only two of the white parts filled
now when i press Shift in game it fills to 3
but it wont go back down to 2 or 1
even though pressing shift once sets the attribute to 2
so if i set them all invisible, they become visible once the attribute changes
it looks like in ur Starburst script ur only decreasing the charges
every press of shift uses one charge
ahh
but this is not reflected in the gui for some reason
so put local chargeamount = starburst:GetAttribute("chargeamount") inside of the "setChargeAmountGUI" function
at the top
for your first time every trying to script you are doing a really good job btw. i didnt learn about set and get attribute until i was scripting for over 6 months... i used boolValues and intValues for most of that time
that results in this error
LOL thanks
these two scripts are actually the first ones ive written that i didn't just copy
wait
i misunderstood you
misunderstood 🙏
coolio
omg thank you so much !!!!!