OakBerry
|
  |
| Joined: 18 May 2015 |
| Total Posts: 407 |
|
|
| 12 Sep 2015 06:25 PM |
Which one is better for a hold down script?
A.) Make a boolvalue, make it true.
local a = boolvalue.Value
while a do --script wait() end
In another script, you make a script check if the player let go, if they did the value because false.
When the boolvalue's value becomes false, the loop stops.
or
B.) Make a boolvalue, make it true
repeat -- script until boolvalue.Value = false
Which do you prefer, or is there a better way of doing it? |
|
|
| Report Abuse |
|
|
amanda
|
  |
| Joined: 21 Nov 2006 |
| Total Posts: 5925 |
|
| |
|
OakBerry
|
  |
| Joined: 18 May 2015 |
| Total Posts: 407 |
|
|
| 12 Sep 2015 09:49 PM |
Let's say:
While holding down the mouse button, parts keep spawning.
But when you let go, it stops. |
|
|
| Report Abuse |
|
|
|
| 12 Sep 2015 10:11 PM |
Lag af
They should get destroyed after like 2 seconds if more then 20 has spawned
http://www.roblox.com/Shots-Fired-item?id=168209364 Shots fired, ready for the war. |
|
|
| Report Abuse |
|
|
OakBerry
|
  |
| Joined: 18 May 2015 |
| Total Posts: 407 |
|
| |
|