#New to LUA need help with a loop

1 messages · Page 1 of 1 (latest)

pliant stump
#

Hello im trying to make a functional lever on something that when I turn it on or off it enables or disables something. I need help with the loop

#

my loop

#

here is the lever

#

i clicked it and it changed to running

#

even though there is a loop running

#

i clicked it again and it didnt change to the other thing

#

oh wait I think I see a possible fix

#

oh wait

#

i will use

#

if debounce then return end

#

YOOOO

#

I DID IT

#

here is the script i used if anybody is wondering

#

finally

#

i figured it out

#

i just used else and it worked

tawny bone
pliant stump
clever gulchBOT
#

studio** You are now Level 1! **studio

pliant stump
#

new issue

#

where is the text thing 😭

#

@tawny bone come back and help please 🙏

#

ok i need to ping someone random

pliant stump
#

bro this is painful

pliant stump
# pliant stump

@patent coral so so so sorry for ping but do u know the reason for this

patent coral
#

The box where the text goes is missing?

#

Have you tried deleting and creating a new text box or are all of your text labels doing that?

pliant stump
patent coral
#

You could probably brute force it by finding the text label with a script and changing it with a variable

#

If you know how to do that

#

Oh damn I think my nose is bleeding XD

pliant stump
#

yeah I do but I need to do it manually

#

i dont want it to be named what it currently is

lucid shuttle
pliant stump
#

while in studio

lucid shuttle
#

it's useless

pliant stump
#

oh fr

#

samn

#

damb

lucid shuttle
#

it just break the code

#

tbh

pliant stump
#

but

#

question is

#

okay well other than that the most pressing issue

#

that I pinged for

pliant stump
lucid shuttle
#

it will make your script create more and more connections each time the loop restart

tawny bone
lucid shuttle
#

u just need one connection

tawny bone
#

I believe clickdetector has an active button

patent coral
#

@lucid shuttle Do you know anyone that might need a slave I mean coding intern for their game?

patent coral
#

dang, alright, I'm out

tawny bone
pliant stump
#

fr im making a functional soviet RBMK-1000 nuclear core as my first mini project

tawny bone
#

Doesnt even have to be a functional game

#

Could easily be a function OF a game

pliant stump
#

or somebody

#

idk

patent coral
# tawny bone Why dont u make ur own mini projects

I could, but then I looked back at when I tried learning another coding language for Garry's Mod and realised I do better when I'm learning from people I can interact with than watching videos or reading guides. I don't want to clog this dudes thread though, so you can ping me in general or smthn'

pliant stump
#

so happy we all decided to talk about something completely unrelated to my question

pliant stump
lucid shuttle
#

🙏

pliant stump
#

ok mb mb

pliant stump
clever gulchBOT
#

studio** You are now Level 2! **studio

pliant stump
#

PLEASE 😭

patent coral
#

Bruh you're probably gonna get in trouble if you keep pinging random people

hollow iris
#

dk

shy grail
#

It’s a simple fix

pliant stump
#

im not asking

#

about the loop

#

ive said this 30 times

#

its this im asking about

#

where is the box to edit text?

shy grail
shy grail
pliant stump
#

THERS NO WAY

#

THAT WAS THE ISSUE

#

tysm bro

shy grail
#

😭 😭

#

Yw

pliant stump
#

i was on that for like half an hour

hollow iris
crude elm
pliant stump
crude elm
#

anyways

#

whats the problem?

crude elm
crude elm
pliant stump
crude elm
#

okay

shy grail
hollow iris