question_score
stringclasses
21 values
title
stringlengths
6
119
question_userid
stringlengths
4
10
question_user
stringlengths
3
20
question_user_score
stringclasses
496 values
question_datetime
stringdate
2014-02-01 23:57:31
2023-04-02 01:40:15
question
stringlengths
0
11k
question_id
stringlengths
1
6
answer_count
stringclasses
8 values
answer_id
stringlengths
0
6
answer_score
stringclasses
18 values
answer_userid
stringclasses
946 values
answer_user
stringclasses
963 values
answer_user_score
stringclasses
692 values
answer_datetime
stringlengths
0
19
answer
stringlengths
0
10.7k
0
How do I change the Walkspeed of the Player?
35675621
FastSnail5
8
2014-11-04 01:27:49
<p>I can't figure out how to make a Player walk slower or faster than normal. I don't think I need a script I just can't figure out if I need to change something or what?</p>
12184
1
15201
3
2267870
Redbullusa
1580
2014-11-04 03:01:51
<p>The walkspeed property can be adjusted in the "Humanoid" object. The humanoid is in every player.</p> <p>If you're in a server, then your walkspeed should be here:</p> <p>game &lt; Workspace &lt; FastSnail5 &lt; Humanoid &lt; Walkspeed &lt; Value</p> <p>game &lt; Workspace &lt; [Model] &lt; [Object] &lt; [Property] ...
0
How to make script to change intValue of DNA in Dinosaur simulator?
1715522570
BeautifulAuraLover
371
2020-10-19 11:12:52
<p>Hello, I am beginner in scripting, like I just started, already made only one simple script on one game, but I would like to make script on dinosaur simulator to play admin dinosaurs or to change DNA. I used dex and remote spy to know game functions and these. Tried to make a script for trading too, but failed also....
114559
0
JumpPad works in Roblox Studios but not in the Roblox App itself?
167536064
MelodicSea5914
21
2020-07-24 19:15:30
<p>Hi there, I hope you have a great day. Ok So I have a working JumpPad script with a Debounce variable that once touched will make the players JumpPower increase to 184 and then it goes back to the original JumpPower (which is 93). It works fine in Roblox Studios(most of the time) but only works like half of the time...
109863
0
Keeping NPC's from attacking eachother?
491486
firedum
5
2014-04-13 00:03:29
<p>I have two NPC's down on the level and they attack eachother as soon as I run it.</p> <pre class='brush: lua'>local larm = script.Parent:FindFirstChild("Left Arm") local rarm = script.Parent:FindFirstChild("Right Arm") function findNearestTorso(pos) local list = game.Workspace:children() local torso = nil ...
1262
0
KeyDowns and MouseClick1Downs help?
56633716
attackonkyojin
135
2015-05-01 23:50:59
<p>What are the differences between KeyUp and KeyDown?</p> <p>And what is the difference between Mouse1Click and And Mouse1ClickHold Vise versa?</p>
17180
2
20580
1
41100413
BSIncorporated
640
2015-05-02 00:01:41
<p><code>KeyUp</code> and <code>KeyDown</code> (as you probably know) have to do with keyboard keys. The difference between them is that if I were to press k down then that triggers the <code>KeyDown</code> <code>Event</code> and then when I unclick the key (when i bring my finger back up) It will trigger the event: <c...
0
For some reason my script identifies my tools parent as a player, yet it is not. Any advice?
215833213
Stiles8353
35
2022-10-17 00:48:04
<p>This part of my local script here, (tool is defined as script.Parent), sends a signal to a remote function,</p> <pre class="brush: lua">script.Parent.Equipped:Connect(function() game.ReplicatedStorage.equipstatus:FireServer(tool) script.Parent.equip.Value = 1 idleanim.Priority = Enum.AnimationPriority.Ac...
131947
0
How do i put badges in my zombie map that are given when a certain round is reached
21886467
abcdbag123
10
2014-02-19 20:28:25
<p>like the ones in Der Reise http://www.roblox.com/Der-Riese-v0-2-New-Sounds-place?id=17888427</p>
110
2
206
1
19566737
Unclear
1776
2014-02-19 20:37:01
<p>The first thing you want to do is figure out when to award badges. You can do this by integrating the badge awarding process directly in the loop controlling the progression of rounds, and checking whether the round matches the required round to award the badge for.</p> <p>You can use the <a target="_blank" href="ht...
0
What is RBXScriptSignal:ConnectParallel() and RBXScriptSignal:Once(), and how do you use them?
559514967
T3_MasterGamer
2189
2022-08-17 10:43:40
<p>I was just making a RemoteEvent, when I noticed that the Event has the functions <code>:ConnectParallel()</code> and <code>:Once()</code> and I wonder what they do. They don’t have a documentation in the wiki. I checked the DevForum and there are not much posts about them. I read the posts and I still don’t understa...
131263
1
118558
2
158443324
xXMadonXx
190
2022-08-17 12:21:57
<p>Because you did not understand the Forum, i am going to try and make this as descriptive as i can. It may cause that there is a lot of information you already know.</p> <p>I am also referring to CPU Cores but with that mean threads. (To make it simpler)</p> <p><strong>:Once()</strong></p> <p>Basically :Connect() but...
0
Why does this script not continue on from line 7 when fired from a remote event?
59833205
bailley5
114
2022-01-08 05:59:17
<p>Server Script: (the one where it stops at line 7)</p> <pre class='brush: lua'>game.ReplicatedStorage.IceFire.OnServerEvent:Connect(function(plr) local icering = game.ReplicatedStorage.IceRing:Clone() icering:SetPrimaryPartCFrame(plr.Character.HumanoidRootPart.CFrame) -- teleporting the icering to the player ...
128773
1
116604
1
71530978
enes223
312
2022-01-08 07:36:12
<p>I told this on another question too, you need to use the built-in function named "SetPrimaryPartCFrame" on the character as you used it on ice ring, just do this instead of setting the CFrame by yourself:</p> <pre class='brush: lua'>plr.Character:SetPrimaryPartCFrame(icering.PlayerTp.CFrame) </pre>
0
ClearAllChildren is not valid member of RBXScriptSignal?
1072875657
RexPROGaming09
0
2021-10-01 00:51:43
<p>So im not the best scripter but i tried rewriting this 2 times still same error</p> <p>I started working on game on roblox and i needed this script to work for me to go forward in project.</p> <p>Got stuck on this script which is called Activated, it tool script for it to fire event when tool is activated, please no...
127762
1
I used a local script to move my part but it doesn&rsquo;t work?
102544472
CedCed6
30
2020-11-22 00:54:48
<p>I want to move my part when a player joins. I used a local script and I used this code:</p> <pre class='brush: lua'>local part = script.Parent repeat wait() until game:IsLoaded() part.Position = 60, 120, 4 </pre>
116132
4
106575
1
9542689
Vathriel
510
2020-11-22 01:02:25
<p>Position is a Vector3 value, you need to use:</p> <pre class='brush: lua'>part.Position = Vector3.new(60,120,4) </pre> <p>For future reference most of the time things like this can be caught in the output window.</p> <p>Good luck!</p>
0
How can I get a ModuleScript to return a value?
25516360
Zerio920
285
2015-04-13 01:28:32
<p>I've got this simple child-picker in one ModuleScript:</p> <pre class='brush: lua'>function pick(model) local children = model:GetChildren() local number = math.random(1,#children) local child = children[number] end return pick </pre> <p>I'm not sure how to get this to return the child that's chosen, for...
16652
0
How do i script an Automatic Sliding Door?
43751253
Xianon
105
2014-04-26 18:56:24
<p>I'm triying to make an automatic sliding door using Cframe and also that lets detect an Humanoid so it activates, but i don't know how to use Cframe on a script yet can somebody help me?</p>
3617
1
5021
0
18697683
ChipioIndustries
454
2014-04-26 19:19:06
<pre class='brush: lua'>local running=false function onTouch(hit) if running==false then if hit.Parent:findFirstChild("Humanoid") then running=true for I=1, 100 do script.Parent.CFrame=script.Parent.CFrame+Vector3.new(0.1,0,0) wait() end wait(3) for I=1, 100 do script.Parent.CFrame=script.Parent.CFrame-Vector3.new(0.1,...
1
TextButton MouseButton1Click not registering.
21682877
GoldenPhysics
474
2014-02-27 01:56:00
<p>Frame > TextButton > script</p> <p>Frame > Interface</p> <p>That's the relevant hierarchy.</p> <p>When I click the TextButton nothing happens. I haven't been able to figure out why so I'm asking the community. Any suggestions? Sorry, it's not much information.</p> <pre class="brush: lua">script.Parent.MouseButton1Cl...
322
1
591
0
31265920
Azarth
3141
2014-02-27 02:05:30
<p>Line 10, you misspelled BackgroundTransparency.</p>
0
Can I make this pinsetter function the same way without writing this much code?
308572986
bittyboy1234
91
2021-01-21 14:05:20
<p>local pinsetter = script.Parent.Parent.Pinsetter1 local sweeper = script.Parent.Parent.Sweep1 local pins = script.Parent.Parent.BowlingPins1 local ballreturn = script.Parent.Parent.BallReturn1 local BackupPins = pins:Clone() local DB = false local Running = true local Sweep_Y_Axis = Vector3.new(0,3.79,0) local Sweep...
119012
2
Making Said Model float above right arm
8282651
sketchy54
22
2014-03-02 23:17:32
<p>I've been trying and trying but I can't get <a target="_blank" href="http://www.roblox.com/Space-Cube-item?id=147754516">Space Cube</a> to float above my right arm and follow it. Any suggestions/help?</p>
454
16
What does all these different types of functions do?
96188844
LightYagamiTheKira
116
2018-06-06 15:04:22
<p>Hi everyone. So I have been looking at different codes written by different people and I am seeing different types of functions. I know the normal function is written as either</p> <pre class='brush: lua'>function func (...) --Do Stuff end; </pre> <p>or</p> <pre class='brush: lua'>local function func (...) -...
59764
4
58105
10
39250676
ScriptGuider
5640
2018-06-06 17:25:36
<h2>Functions are Functions</h2> <p>There are no different <em>types</em> of functions in Lua. Functions are their own data type just like how <code>numbers</code>, <code>booleans</code>, <code>tables</code>, and so on, are also their own data types. Most of the examples you've provided differ in how <em>functions are ...
0
What would I use to make an automatic door?
12014954
Tempestatem
884
2014-06-04 19:33:46
<p><em>I am not asking for a script (Though one would be a nice suprise)</em></p> <p><strong>But I want to know what I would use to make an automatic door.</strong></p> <p>I know how to make the brick move and stuff, i am just confused on how to make it, if the player is near the door, it opens.</p> <p><strong>Thanks!<...
6165
1
8182
0
13273324
Chili1924
150
2014-06-04 19:47:05
<p>You could place an invisible brick near each side of the door to serve as 'trigger bricks', so that when a player comes in contact with one of the 'trigger bricks', the automatic door opens.</p>
0
Why is this gun not damaging other players?
1544724616
sidb0102
17
2021-07-12 11:46:51
<p>I was trying to create a gun that would damage the other team's players. I created a SMGLocalScript inside the gun:</p> <pre class="brush: lua">local remoteEvent = ReplicatedStorage:WaitForChild('FiringSMGEvent') local shooting = false local equipped = false local player = game.Players.LocalPlayer local mouse = play...
125261
1
114033
0
1400234436
KoalaKo_XD
27
2021-07-12 16:58:45
<p>Try this for your Server Script:</p> <pre class="brush: lua">local ReplicatedStorage = game:GetService("ReplicatedStorage") local FiringEvent = ReplicatedStorage:WaitForChild("FiringSMGEvent") FiringEvent.OnServerEvent:Connect(function(Player, TeamColor, GunPosition, GunOrientation, MousePosition) local Bullet =...
3
Local and Normal Scripts
57592236
handofconnor
20
2014-03-20 18:00:09
<p>What is the difference between a Local script and a normal scirpt?</p>
821
2
Teleport GUI?
51440452
masterhalo55
75
2014-03-16 10:42:47
<p>I want to know how to make a teleport GUI that takes the players from game to game.</p>
725
0
How can I create a dummy with a HumanoidDescription? (solved)
29596046
fathawks
4
2020-03-27 21:42:04
<p>I know how to load a player with a HumanoidDescription but I don't know how I could load a dummy with one. Help?</p>
97277
0
How can i make a roblox badge counter leaderboard?
947893431
cocajola3
6
2021-02-21 20:48:36
<p>Ok, so I understand the basic leaderboard scripts. BUT I have no clue on how to make a badge counter! I need someone who can explain a leaderboard script to me!</p>
120479
0
how to fix the sound play on the all players?
119762485
MiniMopsik
5
2020-08-01 08:26:22
<p>Hello! I have 2 almost identical scripts, but one of them work incorrectly. The meaning of scripts: when you step on a part, the local player plays a sound. Problem: the first script works correctly, but the second does not, he just plays for all the players</p> <p>Script:</p> <p>1-st</p> <pre class='brush: lua'>loc...
110448
0
im getting &quot;Player is not a valid member of Player &quot;Players.Wolverine132416&quot; error?
859415155
Wolverine132416
2
2023-01-18 04:19:22
<p>so im trying to make it where when you click the part you die but it keeps saying players inst a valide meber of players heres the code:</p> <p>local ClickDetector = script.Parent</p> <p>function onClicked(mouse) local player = mouse.Player local humanoid = player.Character:FindFirstChild("Humanoid") if humanoid the...
132883
1
120011
1
245864252
xInfinityBear
1711
2023-01-18 06:07:05
<blockquote> <p>Player is not a valid member of Player "Players.Wolverine132416"</p> </blockquote>
0
How can I make a models parts change?
325817366
Mastically
0
2021-06-11 14:45:45
<p>How can I make every part in a model move, rotate and change the transparency level?</p> <p>Here's what I tried:</p> <p>local prompt = script.Parent</p> <p>prompt.Triggered:Connect(function(player) print("hi you triggered me i guess") for i,v in pairs(workspace.Everything.OrganizedThings.Useables.OpenandShut.Vault.D...
124279
4
why isn't my raycasting detecting anything?
1222281551
botw_legend
452
2020-06-26 20:02:55
<p>so this is the code for my raycast</p> <pre class='brush: lua'>local ray = Ray.new(char:FindFirstChildOfClass("Tool").tool.barrel.Position,(pos).Unit *5)--starts the ray local hit = game.Workspace:FindPartOnRay(ray) if hit then print(hit," yay!") else print(hit," awww") end </pre> <p>it always prints nil aww...
107522
2
98875
1
9552668
SteamG0D
1489
2020-06-26 23:04:12
<p>So this script basically gets the position from the camera to the point in world space and then makes a new ray from your gun barrel to where ever the click location is at. I have explained a bit more with comments.</p> <pre class='brush: lua'>local tool = script.Parent local UserInputService = game:GetService("User...
0
Does anyone know how to make it so a dialogue option kicks a player from the game?
308549733
kickincaleb246
0
2021-05-04 06:46:30
<p>I'm making an npc for my game and I'm trying to make it so the player will be kicked if they choose a mean answer, I'm really new to scripting so if someone could just tell me the script that would help a lot! Tysm in advance</p>
123078
0
How to freeze Local player instead of freezing all Players?
63254693
M9F
94
2019-06-09 20:56:33
<p>I'm trying to freeze a single player that steps on a platform but it freezes all players, I can't seem to get it working.</p> <pre class='brush: lua'>local Players = game:GetService("Players") local LocalPlayer = Players.LocalPlayer --testing workspace.TestPad.Touched:Connect(function(hit) LocalPlayer.HumanoidR...
81477
1
75798
0
96317377
CaptainAlien132
225
2019-06-09 21:08:22
<p>Server scripts can't use LocalPlayer since they are server sided and not client sided. Instead of using LocalPlayer.</p> <p>We can find the player by using what put in the parentheses after the .Touched function.</p> <p>Make sure this is in a server script in either the Workspace or ServerScriptService.</p> <pre cla...
0
How would I go about this GUI chat?
42370295
kay980
0
2014-07-11 03:46:23
<p>I'm wondering how I would go about making a chat gui like the one found in Wizard101 where when you talk to a humanoid it responds with dialog below. <em>I'm a novice at scripting</em> so how would I go about this. Thanks.</p>
7923
0
How do you detect if you are in a certain Pointlight?
1392128777
fiddyfiddler
18
2022-06-21 15:56:40
<p>Hi, I've been wondering the same question for about a year now. How do you detect if a player hits a certain pointlight, spotlight, etc.</p> <p>Any help would be appreciated!</p> <p>(Also, I'm not looking for how to determine whether the player is in just general light, or not.)</p>
130439
0
What is the difference between pairs and ipairs?
10908590
ghostblocks
74
2015-07-05 19:54:31
<p>I'm making scripts that are testing around with arrays and reading a bit of the wiki said that you should use ipairs instead of pairs. Unfortunately, the articles for ipair and pair aren't very detailed and don't really help me understand what they are actually used for/ what is the difference between the two? Anyon...
19360
0
What are some tips on optimizing a gun system?
304082137
teamlate
0
2021-04-07 03:03:50
<p>To not bore you people with the details, I'm working on a gun system with a server sided script in server-script-service. The issue is that traces occasionally just refuse to appear. The way the gun system works is that there is a single remote-event in replicated-storage, that event is fired by all the guns when be...
122095
1
how do i reset the repeated functions?
95639712
proROBLOXkiller5
29
2021-04-08 02:24:53
<p>this is kinda hard to make a question about cuz i dont really know what the question should be but heres the context. im trying to make a model rotate left when left shift is pressed and when left shift is pressed again it turns right and it repeats kind of like left right left right left right</p> <p>this is the co...
122137
1
Find player when they click on a SurfaceGUI
20802498
PartynaderNo7
15
2014-02-23 13:18:26
<p>I'm trying to make a script in which when you click on a SurfaceGUI button, it makes the "box" belong to that player. To do this I need to change some values to equal the player's name. The only problem is finding the player. I'm not sure how to find the player after clicking (You might've seen my (player) After the...
253
3
466
0
14520421
juzzbyXfalcon
155
2014-02-23 16:04:56
<p>I suppose you do not wish to make these GUIs local (Meaning that if you change the text, other players would not be able to see changes made to them)</p> <p>In that case it is not possible to get the player from a click on the button.</p> <p>Your only option would be to make a local script that checks if the player ...
0
BrickColor isn't a valid member of Part?
13093293
Orian2
5
2015-05-17 09:16:21
<p>Hey, so I'm a newbie Lua scripter, and I'm trying to get a platform to move when I click a button. I managed to make it move 100 studs and return very easily, but if someone clicked the button while the platform was still moving it'd screw everything up, the velocity the platform had for people not to fall off, woul...
17612
1
21055
1
1002773
Spongocardo
1991
2015-05-17 10:06:50
<p>In ROBLOX Lua, everything is case sensitive. That means if one thing is not capitalized correctly, the whole script will break. To fix this, you need to make Brickcolor on lines 4, 5 and 20 <code>BrickColor</code>.</p> <pre class='brush: lua'>p=game.Workspace.Bridge.Part Button=game.Workspace.Bridge.Button function...
1
TweenPosition isn't working when a TextButton is clicked?
1319896863
ZombieApocalypz3
35
2020-09-11 18:06:22
<p>Ok, so I was trying to make it so when you click the button, the frame comes out of the screen smoothly by using TweenPosition.</p> <p>It somehow shows an error in this simple script.</p> <pre class='brush: lua'>local mainround = script.Parent.Parent.Parent.Parent.MainRoundify script.Parent.MouseButton1Click:Connect...
113031
2
103751
0
79300081
CaioAlpaca
342
2020-09-11 18:23:36
<p>Hello there.</p> <p>Alright so there are a few errors in your script.</p> <p><strong>.1</strong> You dont use scripts for Client side, instead use local scripts.</p> <p><strong>.2</strong> Your setting the time first, and thats wrong, do this instead:</p> <pre class='brush: lua'>mainround:TweenPosition(UDim2.new(-3....
0
How do I make a floating Brick?
43663944
LILZKIIL
0
2014-04-15 06:10:09
<p><strong>Im talking about the floating bricks that bounce up and down while in the air, please help me.</strong></p>
1541
0
How do I make it so only one frame can be open at a time?
1193954971
spuerno
0
2022-08-02 21:44:19
<p>So if someone try's to open the shop and settings the shop will close?</p>
131073
0
Why is Player Get Children returning 0?
57974758
littlemanrules426
0
2020-04-26 02:22:29
<p>I am making a for loop to filter through the players character. It wasn't working. I figured out why. I put the players Children in a variable called d. #d returns 0. This is the code I use to get D:</p> <pre class='brush: lua'>local player = game.Players.LocalPlayer local d player.CharacterAdded:Connect(function() ...
100750
1
How would I make it so that my Script creates a leaderboard so it can add 1 to one of its stats?
1546980603
Jakob_Cashy
67
2020-07-21 02:41:27
<pre class='brush: lua'>game.Players.PlayerAdded:Connect(function(plr) local stats = Instance.new("Folder") stats.Name = "leaderstats" stats.Parent = plr local DP = Instance.new("IntValue") DP.Name = "Points" DP.Parent = stats local DR = Instance.new("IntValue") DR.Name = "Dice Rolls" ...
109582
1
100705
1
566296650
raid6n
2326
2020-07-21 03:02:34
<p>Hey! I believe I found your issue. The problem is that you're changing the leader stats value in a local script.</p> <p>Before we begin, please make a RemoteEvent in ReplicatedStorage, and call it RemoteEvent</p> <p>The local script:</p> <pre class='brush: lua'>script.Parent.MouseButton1Click:Connect( function()...
0
I keep getting the error &quot;end:4: Expected function call arguments after '('&quot;. What?
1287381014
RFL890
4
2020-11-24 16:10:49
<pre class='brush: lua'>while true do for _, v in pairs(game.Workspace:GetChildren()) do if v:WaitForChild("Part") or v.Name == "Part" then v:Destroy end end </pre> <p>This is a workspace cleaner. Every time it returns: end:4: Expected function call arguments after '(' What does this even mean?<...
116263
1
106684
4
443643048
Soban06
410
2020-11-24 16:13:25
<p>You are missing an end and the brackets of Destroy. Change your code to this:</p> <pre class='brush: lua'>while true do for _, v in pairs(game.Workspace:GetChildren()) do if v:WaitForChild("Part") or v.Name == "Part" then v:Destroy() -- You also need to add brackets. end end end </pre...
0
How do I make a script that will save players stats? (Leaderboard, etc.)
17996581
UngracefulUnicorn
40
2014-04-26 18:11:42
<p>I've been wondering how to save leaderboard stats for awhile now. I want to know because I've wanted to make a game where people can earn money, leave, and come back with the same amount of money. Any feedback would be helpful. Thanks! (P.S.) I'm not sure how to use Data Persistence or any of that complicated stuff....
3612
1
5016
2
3289648
YaYaBinks3
110
2014-04-26 18:15:42
<p>DataPersistence isn't actually complicated. For stuff like money, you can just do this:</p> <p>player:SaveNumber("cash",leaderboard.Cash.Value) player:LoadNumber("cash")</p> <p>And also, somehow I doubt you know how to script. It's quite easy to do DataPersistence.</p>
0
Animations, Localscript or ServerScript?
79451355
SurVur
86
2015-03-13 22:10:36
<p>Would you run an animation from a localscript or server script? And my animations seem to not be playing anyway.</p>
15735
0
How can I debounce this? Not really good with them?
32130096
Azuc
112
2017-11-03 06:18:11
<pre class='brush: lua'>local state = false script.Parent.ClickDetector.mouseClick:connect(function(touched) state = not state if state then script.Parent.Sound:Play() wait(1) script.Parent.Off.Windows:Play() game.Workspace.KEYBASE.Material = ("Neon") wait(3) else ...
49094
2
49236
1
386632990
gmatchOnRoblox
98
2017-11-03 06:55:49
<pre class='brush: lua'><br />-- Assuming state is the value you want to debounce local state = false script.Parent.ClickDetector.mouseClick:connect(function(touched) state = not state if state then state = true script.Parent.Sound:Play() wait(1) script.Parent.Off.Windows:Play() ...
0
What does fromEulerAngles do?
90063206
HackTheUniverse
50
2016-02-19 02:21:11
<p>I have looked this up and have found nothing. please explain what this is.</p>
27600
2
31113
2
15833027
nighttimeninja314
120
2016-02-19 02:50:52
<p>This is the equivalent of > CFrame.Angles.</p> <p>Euler angles are all about orientation. The three input values it takes are</p> <blockquote> <p>RX RY and RZ</p> </blockquote> <p>The "R" stands for <strong>radians</strong>. A radian is essentially just an angle but in a different format in which one radian is the d...
3
Where's the best spot to keep ModuleScripts?
2282833
chomboghai
2044
2018-06-29 21:07:32
<p>So I'm a big fan of modules, I use them practically anywhere I can, I like to keep everything neat and organized. However, I recently came up with an issue:</p> <p>Originally, I kept all my scripts in ServerScriptService unless required to be in PlayerGui or a specific model. I have one script that I just realized s...
61426
3
59800
5
8451
amanda
1059
2018-06-29 21:53:15
<p>Here are your three primary containers for <code>ModuleScripts</code>:</p> <ol> <li><code>ServerScriptService</code> <ul> <li>Place module scripts here whenever they are only used by the <code>Server</code>.</li> </ul></li> <li><code>StarterPlayerScripts</code> <ul> <li>Place module scripts here whenever they are on...
0
There is this error that I cant fix how do I fix it? I'm trying to make a sprint script.
1659997192
CMB1048
25
2021-07-30 18:17:49
<p>Error: 14:14:51.507 Players.CMB1048.PlayerScripts.LocalScript:22: Expected 'end' (to close 'then' at line 13), got &lt;eof>; did you forget to close 'then' at line 18? - Studio - LocalScript:22 btw sorry i had to repeat this</p> <pre class='brush: lua'>UserInputService = game:GetService("UserInputService") loca...
125883
0
More efficient way to script directional controls?
927725246
minker36
2
2020-09-13 04:21:16
<p>I have the player as a ball, and I'm currently scripting the controls. When a WASD key is held the velocity is changed so that the ball moves correspondingly. I currently have multiple while-statements that run when a single key is held, or when a combination of keys are held(WA, SD)</p> <p>></p> <pre class="brush: ...
113102
0
Hi Why does the then in my script get underlined??
433962773
theking66hayday
501
2022-09-05 01:14:58
<p>Hi, then is for some reason underlined in my script what am I doing wrong and how could I fix this?? I just started scripting with Lua and I am still learning it so it could be an easy fix. Code:</p> <pre class='brush: lua'>script.Parent.ProximityPrompt.Triggered:Connect(function(plr) plr.PlayerGui.TPGUI.Enabled...
131515
2
118790
1
1507353142
Bloxyses
54
2022-09-05 14:25:20
<p>You have to first check if the GUI is enabled using an if statement. To use the if statement, it goes like this:</p> <pre class='brush: lua'>script.Parent.ProximityPrompt.Triggered:Connect(function(plr) if plr.PlayerGui.TPGUI.Enabled == false then plr.PlayerGui.TPGUI.Enabled = true end end) </pre> <p...
2
How do I make it so when you say something in chat a sound will play?
1723050796
RenDevelopment
15
2020-06-27 22:49:30
<p>Sorry I can't make a script, I know nothing on how to make a sound play when you say something in chat.</p>
107616
3
98943
0
81101377
peytonallen920
66
2020-06-28 00:54:41
<p>Under the script is instructions on how to set it up</p> <pre class='brush: lua'>local Sound = workspace.Sound function onChatted(msg, recipient, speaker) local playertalking = string.lower(speaker.Name) msg = string.lower(msg) local message = Instance.new("StringValue") message.Parent = workspace message.Value = "p...
1
How to save an inventoryGUI after a player dies?
61716444
theking48989987
2141
2018-09-16 23:53:06
<p>so I have a survival style inventory system, and I wonder how I could preserve all of the inventory slots in the inventory gui after the player dies in game.</p> <pre class='brush: lua'>--variables local currentweight = 0 local inv = {} local plr = game.Players.LocalPlayer --guis local plrgui = plr:WaitForChild("Pla...
67520
1
64938
1
142366479
the8bitdude11
324
2018-09-19 02:57:25
<p>set the gui's ResetOnSpawn property to false</p>
1
What Is The Replacement String Syntax?
60261990
Benbebop
963
2021-02-21 17:47:04
<p>Pattern Strings are well documented on the API Reference but it seems that Replacement Strings aren't mentioned anywhere. Replacement Strings are used for the third value of string.gsub and I'm guessing not much else.</p> <blockquote> <p>string.gsub("string", "pattern string", "replacement string")</p> </blockquote>...
120471
2
109852
2
73170429
imKirda
2659
2021-02-21 19:06:00
<p>The <code>%</code> in last argument must be used in cooperation with the second argument which is the pattern, this operator lets you get the match that has been found in cases where you for example use <code>%d</code>, you know it's some number but what number exactly? Or where you match multiple letters. I of cour...
0
why do i get a lot of Client-Sided Errors?
1224124949
Hamoodiyt
11
2021-09-29 15:57:01
<p>Most of it :</p> <p><code>It happens everywhere so I am Pretty sure it's Client-Sided</code></p> <pre class='brush: lua'>20:26:37.057 Requested module was required recursively - Server 20:26:37.057 Stack Begin - Studio 20:26:37.057 Script 'cloud_144950355.Building Tools.Libraries.Cheer', Line 32 - function Lo...
127745
0
Enable localscript when equipping tool?
367225191
Tony_maestropokemon5
0
2021-02-22 01:49:05
<p>Hi, its me... again</p> <p>Well, basically, i have a torso follow mouse script, but my playerbase said its uncomfortable and hard to control in mobile. So i wanted to make it just work when equipping a weapon.</p> <p>However, my script isnt working, although there are no errors.</p> <p>Here´s the localscript in the ...
120492
0
How to give an npc or model an R6 animation?(SOLVED)
92872759
yayimstrongforever
0
2020-11-04 19:10:37
<p>Is there a certain script I have to use in order to give an npc the R6 animation? Sort of like the all the R6 animations but its on a model or a npc?</p> <p>For example, the day the noobs took over roblox 2. Where they have npcs that have the R6 animation, or they use the R6 animation. Hopefully I explained this rig...
115342
0
How do you edit a data store for players?
520105079
RainbowBeastYT
85
2018-07-25 13:09:57
<p>I have written two scripts for a data store, but what if I want to edit other people's data, how do I do that?</p> <p>script 1</p> <pre class='brush: lua'>local DataStore = game:GetService("DataStoreService") local ds = DataStore:GetDataStore("CashSaveSystem") game.Players.PlayerAdded:connect(function(player) local...
63680
0
How do I make it so that an audio plays at random times?
161355579
K7qk
0
2021-05-02 04:43:33
<p>I have this script in my game that's supposed to play audio at a random time then at another random time so on so forth What it's doing is only playing the audio once which is as soon as the player logs into the game and then never playing the audio again. It ignores the math command thing for some reason and just p...
123016
0
How to tell when a sound stops.
25691148
FromLegoUniverse
264
2014-03-26 01:20:35
<p>About 8 hours ago, the sound engine was updated. How does one detect that a sound has stopped, if there is a way? I am totally stumped.</p> <p>The info of the update was on developer.roblox.com.</p>
911
1
1388
4
15049169
DragonSkyye
517
2014-03-26 02:39:11
<p>I suppose you could use <code>isPlaying</code> from the sound to check if it is playing or not.</p> <p>Ex.</p> <pre class='brush: lua'>Sound = script.Sound Sound:Play() if sound.isPlaying == false then --Code end </pre>
0
How to erase places made with the CreatePlace and SavePlace services?
36797975
jBuildz17
20
2014-03-04 13:23:25
<p>I have a small Game (made with Universes) and I am using the CreatePlace and SavePlace services to make personal tycoons for players to play in.</p> <p>I used my own player for the testing, and at about halfway during development, I changed the place that is created for every new player.</p> <p>However, I had alread...
482
0
Attempt to index number with 'MouseButton1Click' can someone help me with this error?
1316144154
Altbotnot
0
2021-06-07 19:42:37
<p>I'm making a shop GUI so players can buy swords and weapons. But an error appeared on the output saying "attempt to index number with 'MouseButton1Click'". and I tried everything that I could think of to fix this and it still doesn't work. I've tried finding online solutions but nothing helped. So I came here. Here'...
124176
0
how do i do instance.new(&quot;boolvalue&quot; players[i])?
821459157
TemaTechYT
2
2021-10-03 07:10:22
<p>how do i do instance.new("boolvalue" players[i])? i want to make a value to a players in the table, but thats not working. why?</p>
127787
1
115845
0
110029109
lua_exception
125
2021-10-03 19:24:00
<p>Hiya, welcome to Scripting Helpers. I don't want to be the sour jelly bean but please try attempt making this your self.</p> <p>For this script, you can use: <a target="_blank" href="https://education.roblox.com/en-us/resources/pairs-and-ipairs-intro">Pairs an iPairs (Roblox Resource)</a> to iterate over the players...
0
Why is the view port frame not displaying anything?[SOLVED]
357035682
mikey2019d
38
2020-08-01 06:43:15
<p>Basically I have two buttons that if you click a gun preview will appear on the viewport. Except it does not display the gun. I have the camera and everything set up and working. I got no errors and I checked to make sure it was going in the viewport and It was.</p> <p>Here is my code</p> <pre class='brush: lua'>--A...
110442
1
What does ~= do in Lua?... See it everywhere but still confused on what it does
241762828
andyad13
74
2018-06-02 11:17:54
<p>Hello, I have a question. What does this do? ~=</p> <p>Looks like an arithmetic operator, but not sure.</p> <p>I've seen it used like this before.</p> <pre class='brush: lua'>local exampleVarriable = "Example" if exampleVarriable ~= nil then print("Something...") end </pre>
59483
4
57822
4
450123979
Sharkeedub
179
2018-06-02 11:25:50
<p>The <strong>~=</strong> symbol means <strong>not equal</strong></p> <p>So basically saying</p> <p>if exampleVarriable is <strong>not equal to</strong> nil then print("something...")</p>
1
Script works in 'Run' but not 'Play Solo'? [ANSWERED]
46382260
SpazzMan502
133
2014-11-28 22:25:03
<p>So I have a script inside of a Monster NPC that does stuff when it dies. (it's health get lowered when it touches a block called 'IceCube'. It worked in a different place, and when I tried it out in 'Run' mode it also worked. I even named a part 'IceCube' and killed him with that and everything worked</p> <p>Then wh...
12832
2
15872
1
17514438
TheeDeathCaster
2368
2014-11-28 23:10:54
<p>The problem is that <code>Torso</code>, and <code>Humanoid</code> has not loaded yet, so when the script fired, it did not find <code>Torso</code> or <code>Humanoid</code>, I have remade your script with some-what explanations, you could simply use the <a target="_blank" href="http://wiki.roblox.com/index.php?title=...
0
How do you remove everything in a player's backpack?
103518855
Cyrellejheff
11
2019-05-23 11:26:56
<p>So this is my script this is a rebirth now if you see in the code theres a child:remove() When i tested it it doesnt remove the child like how plz help im a nub at scripting :)</p> <pre class="brush: lua">local replicatedStorage = game:GetService("ReplicatedStorage") local StarterRebirthAmount = 60000 local player =...
80608
1
75013
0
164884514
mc3334
649
2019-05-23 14:58:45
<p>add in this:</p> <pre class="brush: lua">player.Backpack:ClearAllChildren() for _,v in pairs(player.Character:GetChildren()) do if v:IsA("Tool") then v:Destroy() end end) </pre> <p>The first line clears the backpack/inventory Anything following that will work to clear what's in the player's hand. Jus...
1
unpack() printing out only first word?
110029109
loowa_yawn
383
2020-05-01 21:46:00
<p>I've been attempting to make my own /name script. It's been going fine until this happened: https://gyazo.com/eb1732b08734164f26089b2fd6d2190a</p> <p>Here's the line of code that changes the text:</p> <pre class='brush: lua'>local function NameChange(player, text) local character = player.Character character...
101517
1
93796
1
16908742
animorphs30
300
2020-05-01 22:57:03
<p>This isn't an issue with the script, but actually with how unpack works...</p> <p>Essentially, for a lot of functions in roblox, they can have multiple returns, such as game.Workspace:FindPartOnRay(...), which returns a part, a hit position, and a part normal.</p> <p>This works on a very similar concept. Essentially...
0
Is there a way to copy a terrian and paste in somewhere else?
276280154
danglt
185
2017-12-25 01:20:55
<p>I have a game and there is terrian i need to transfer to another game</p>
50881
0
Discord Webhooks not working ingame?
1399623678
EmJay10101
7
2022-10-05 10:02:55
<p>They work in roblox studio perfectly, sending through the feedback to discord but ingame (In Roblox, not in Roblox Studio) it doesn't seem to send through. Can someone help me?</p> <p>I have tried using different URLs and have enabled HTTP services</p>
131806
0
How can I make Theatre Curtains open and close like in a real theatre?
17543550
ThatTheatrePerson
10
2014-02-19 22:42:21
<p>How can you make a theatre curtain? Like in shows?</p>
134
3
263
1
1546726
nate890
495
2014-02-19 23:09:17
<pre class='brush: lua'>function moveCurtains(curtain1, curtain2, v, n, t) for i = 1, n do curtain1.CFrame = curtain1.CFrame + v curtain2.CFrame = curtain2.CFrame - v wait(t) end end --Open curtains moveCurtains( workspace.CurtainOne, workspace.CurtainTwo, Vector3.new(0.1, 0, 0), 100, 0....
0
I am currently making a game, does anybody know how I can make team avatars?
1314599390
NuggetHasJoined
7
2021-02-26 11:07:53
<p>I am currently making a game, and have two teams, however, I am unsure how I can make it so that when someone is on the green team, their character changes, but when they're on the blue team, their character is a noob. I have already made the avatars, but am unsure how to make them show up. Does anybody know how?</p...
120698
0
Help checking if enemy is on player's screen?
140399066
Uniplier
83
2023-01-19 18:42:03
<p>I'm trying to make a script that plays a sound when the player looks at a monster. After some research, I have this script here:</p> <pre class='brush: lua'>local Camera = workspace.Camera local part = workspace.Enemies.Chaser.UpperTorso local _, withinScreenBounds = Camera:WorldToScreenPoint(part.Position) while wa...
132895
0
How do I make a shop GUI appear after talking to an NPC?
74114385
Zephyrnite
0
2015-02-23 04:23:22
<p>So a basic conversation with the NPC would look like this:</p> <p>NPC - What can I do for you? You - I'd like to see your wares, please. NPC - Certainly. --- this is where GUI would appear.</p> <p>Anyone know how to make this possible?</p>
15240
0
MeshPart to Special Mesh?
16377650
script_ing
43
2018-07-24 19:36:20
<p>How would I convert a MeshPart to a Special Mesh? I have split MeshParts that must be positioned EXACTLY where they are in the beginning. I tried the following script and they won't keep their position:</p> <pre class='brush: lua'>for i, v in next, workspace.MyMesh:GetChildren() do if v:IsA("Model") then ...
63632
0
How Can You Make A Scrolling Frame Go Forever?
551769533
CodedStars
47
2020-07-06 20:48:06
<p>So I have a Custom Backpack Gui that has a scrolling frame, but it doesn't go forever, like. When somebody buys a weapon from my Weapon-Gui-Shop, it'll get added, It goes for about 50 weapons, (<em>Size of the icons are a decent size</em>). And I see like 5 more weapons but I can't reach them, could somebody help me...
108377
1
99589
1
190357083
THUNDER_WOW
149
2020-07-06 22:13:14
<p>Change the size of the canvas int he Scrolling Frame properties.</p>
0
How do I clone a model onto a character more than once?
13467289
VeteranHawk
5
2014-06-03 07:39:23
<p>Example: I want this NVG (http://www.roblox.com/IBH-item?id=132352515) to clone onto my character whenever I touch the giver. A guy told me I need to add in Fire then Spread script into the Head (Giver). It only gives once. How do I make it give more than once? I used this in the Spread script:</p> <pre class='brush...
6105
3
8108
1
65394358
RM0d
305
2014-06-03 11:53:09
<p><strong>> BEFORE</strong></p> <pre class='brush: lua'>function Spread(part) check = part:findFirstChild("Fire") if check == nil then-- if nil create fire script.Parent:Clone().Parent = part elseif check ~= nil then check.Size = check.Size +1000000 check.Heat = check.Heat +1000000 ...
0
How do i change the skybox in a script?
106396567
ment34591
20
2018-05-03 15:36:40
<p>So i'm making a script for void script builder and it needs to change the skybox and replace it with some Fairly Odd Parents decal.</p> <p>Script Below</p> <pre class="brush: lua">s = Instance.new("Sky",game.Lighting) s.SkyboxBk,s.SkyboxDn,s.SkyboxFt,s.SkyboxLf,s.SkyboxRt,s.SkyboxUp = "rbxassetid://201208408...
57876
0
attempt to perform arithmetic (add) on Instance and number? (line 13)
206143181
Philipceo90
13
2020-10-17 15:44:42
<pre class='brush: lua'>local HolderBG = script.Parent.HolderBG local Holder = script.Parent.HolderBG.Holder local RedeemBG = script.Parent.HolderBG.Holder.RedeemBG local RedeemButton = script.Parent.HolderBG.Holder.RedeemBG.Redeem local CodeBox = script.Parent.HolderBG.Holder.CodeBox local CloseButton = script.Parent....
114479
0
Mouse is nil. Need help with a proper algorithm for this. Help?
695213
Ripull
45
2014-04-26 00:19:16
<p>Interaction method, when you mouse over something, a function is fired. Having trouble with the mouse being nil.</p> <p>Problem: <strong>Players.Player1.PlayerGui.LocalPlayerScripts.Interaction:276: attempt to index field 'Target' (a nil value)</strong></p> <p>Problematic code section:</p> <pre class='brush: lua'>--...
3548
0
Is it possible to use module script to change screen gui?
146050688
chronusq
3
2021-05-16 09:26:42
<p>I'm new to programming and I am trying to change the screen GUI when another script activating,so here's what I am trying to accomplish.</p> <p>I first coded a program for my character to dash, and what I imagine is when my character dash,it will change the size of the screen GUI. Here's the program of my dash.</p> ...
123484
1
112566
0
307321409
TheBigBro122
427
2021-05-16 09:44:53
<p>at line 8... Just change</p> <pre class='brush: lua'>local module = require(game.StarterGui.ScreenGui["Energy(Back)"].EnergyBar.ModuleCostEnergy) </pre> <p>to</p> <pre class='brush: lua'>local module = require(plr.PlayerGui.ScreenGui["Energy(Back)"].EnergyBar.ModuleCostEnergy) </pre> <p>because the GUIs that are ins...
1
[SOLVED] Why is this line throwing an error?
11141840
trogyssy
221
2014-06-11 16:30:18
<pre class='brush: lua'>--Seconds, Minutes, and Goal are IntValues --IsRunning is a BoolValue local seconds=Workspace.Timer.Seconds.Value local minutes=Workspace.Timer.Minutes.Value local started=false local running if Workspace.Timer.IsRunning.Value==true then running="Counting..." else if started then ...
6511
1
8625
2
386992
BlueTaslem
18071
2014-06-11 17:56:27
<p>You cannot use <code>tostring</code> as a method of numbers; numbers do not have members.</p> <p><code>a:b()</code> is sugar for <code>a.b(a)</code>, and <code>(5).tostring</code> is clearly not valid.</p> <p>Replace those uses of <code>value:tostring()</code> with <code>tostring(value)</code>.</p> <hr /> <p>It shou...
0
Why BasePart:ApplyImpulse applys after the character jump?
851245927
TerranRecon
39
2021-05-03 23:11:40
<p>its local script,and no need to be serverscript. HumanoidRootPart:ApplyImpulse(Vector3.new(0,1000,0)) it actives after the character jump or falling. Why this happens,and what can be the solutions?</p>
123068
0
How do I make the block go into the correct place? [SOLVED]
306251570
A_thruZ
29
2019-06-11 00:14:02
<p>I'm building a Minecraft Spin-off for Roblox, and I have a working 4-block grid placement system, but most of the time the blocks are off by one snapping point. Although it depends on where on the block you tap, click, it sometimes, only sometimes goes to the incorrect block. Here's a snippet of code showing the bui...
81536
0
How do i make a Team click door?
676578669
fdfdfdfdfHAU
2
2021-07-31 14:06:45
<p>I have no idea how to make a click door for a certain team. I am making a prison game</p>
125908
0
I made a kill npc for cash script but it only works if I use the classic sword? help.
1511098728
trimsofpower1234
2
2021-04-18 14:34:29
<p>I have this one problem that I don't know how to fix. I'm trying to make a script were you kill an npc and it gives you money. But it only works if you use a classic sword, and I want it to work with my custom katana.</p> <p>Here's my local script inside of my npc that supposed to give you cash when you kill the npc...
122522
0
Why is this not working? I thought I did everything right... (Edited)
14411926
Anciteify
70
2015-05-03 03:02:34
<p>I'm trying to modify CloneTroopers Chat Script so it can show ranks on the side, so I thought I could take a bit of the code from ChatRecorder and merge it together but it does not want to work what am I doing wrong here?</p> <p>I also have no errors right so ever...</p> <p>The section I thought would work from Chat...
17231
4
I've heard about Encryption
35339312
ImageLabel
1541
2014-03-11 01:37:20
<blockquote> <p>"Lua code" Encryption</p> </blockquote> <p>How would one go about doing such a thing!</p>
623
2
979
3
17676687
MunimR
125
2014-03-11 01:40:43
<p>Pretty much impossible most people just overuse the term over obfuscation. Obfuscation is just when you hide how the code looks then run it (most people turn a script into a string then loadstring it). This doesn't really do anything since most exploiters use cheat engine (which read memory or something like that, I...
0
How do I name a Folder something with code in it and stuff in &quot;&quot;?
64239721
KoalaTech
6
2021-05-04 23:53:49
<p>So i made a script to make a folder in <code>SoundService</code>. Its erroring with</p> <blockquote> <p>ServerScriptService.OnJoining.Script:7: attempt to call a string value></p> </blockquote> <p>Im pretty sure its something simple</p> <p>The script is in <code>ServerScriptService</code></p> <pre class='brush: lua'...
123107
2
112180
0
291424954
NGC4637
227
2021-05-05 00:14:24
<p>you had one tiny error. You forgot to add text wrapping when mixing strings together. what I mean is the ". ." in between plr.Name and " Sounds"</p> <p>here is the fixed script in case you still don't know what I mean:</p> <pre class='brush: lua'>local Players = game:GetService("Players") local SoundService = game:G...
0
How do i make blue and red with color3?
16642148
DragonOfWar900
397
2014-04-26 18:48:16
<pre class='brush: lua'>script.Parent.MouseButton1Click:connect(function () script.Parent.Parent.Parent.IsPlaying.Value = true end) r = 1 g = 1 b = 1 script.Parent.MouseEnter:connect(function () script.Parent.TextStrokeColor3 = Color3.new(r/0, g/0, b/255) -- i want to be blue end) script.Parent.MouseLeave:con...
3615
1
5018
1
644283
AmericanStripes
610
2014-04-26 18:58:03
<pre class='brush: lua'>local colorRed = BrickColor.Red() local colorBlue = BrickColor.Blue() local colorRedVal = colorRed.Color local ColorBlueVal = colorBlue.Color script.Parent.TextStrokeColor3 = colorRedVal -- OR script.Parent.TextStrokeColor3 = colorBlueVal </pre>
1
More reliable method than onTouched?
37085603
flamethower2002
50
2021-04-08 02:15:39
<p>Made a big brick that destroys certain parts it touches - I.E. a part with a specific name. It works wonders when destroying a players limbs and torso, but doesn't consistently work when destroying other parts; it may destroy a part near the player, or one the player is standing on, but it's inconsistent and never d...
122136
2
111282
0
121672610
Speedmask
80
2021-04-09 02:15:35
<p>a region3 basically gets two points, the bottom left corner and the top right corner, to make a cube which you can use to detect things. try this thing I cooked up.</p> <pre class='brush: lua'>local brickODoom = Instance.new("Part", workspace) brickODoom.Position = Vector3.new(5, 5, 5) brickODoom.Size = Vector3.new(...
1
Why doesn't ChatMakeSystemMessage work inside PlayerAdded Events?
443643048
Soban06
410
2020-07-15 16:39:17
<p>My question is very simple. Whenever I (the admin) of the game join, I the want the server to write the message in the chatbox "The Admin Has Joined The Game".</p> <p><strong><em>1st Step</em></strong></p> <p>I tried to make a simple ChatMakeSystemMessage inside StarterPlayer --> StarterPlayerScripts --> LocalScript...
109133
0
How to obtain a list of all items hit by a ray?
126891094
oggy521
72
2018-10-24 11:04:21
<p>Is it possible to use a raycast from one point to another, and then making a table of all objects which the ray has passed through, rather than just returning the first object hit?</p>
69404
3
66360
2
209708098
ABK2017
406
2018-10-24 11:51:33
<p>I dont know if there’s a more effiecient way, but you can repeatedly GetAllParts and then add them to the ignore list until it returns nothing (nil).</p> <pre class='brush: lua'>local function GetAllParts(Ray) local Parts = {} local Last repeat Last = workspace:FindPartOnRayWithIgnoreList(Ray, Pa...
0
How to make it so that when a brick not associated with the model is touched the model will move?
548866567
noahimhere
0
2020-08-01 04:31:34
<p>So what i want to do is when somebody decides to be a jerk and jumps on the train track, I want a train to come out of nowhere and hit them. (this might be a bit of a weird question) So, if the code works right, when i jump on the tracks it should launch the train to me, hitting me. How do i do this?</p>
110440
0
Door hinge keeps rotating the wrong way?
140399066
Uniplier
83
2023-01-14 18:39:37
<p>I have this door attached to a hinge with hingeconstraints. When I rotate it in server view, all is working fine. But when I tween the hinges orientation using a script, the hinge rotates the complete wrong way. Even when the tween doesn't change the orientation, it still rotates completely wrong. Here's a <a target...
132835
0
Making a local npc have idle animations?
18689091
iipartyhat
25
2017-12-11 15:25:31
<p>I have a script where it clones an npc from replicatedstorage to the players camera, which makes it so that only the player can see the npc. But the problem is, the npc does not have idle animations (like as if its breathing or something) since it is local. How could i make it so that it does have idle animations?</...
50199
0
script keep spawning objects when i only want it to spawn one, what should i do?
454915
nick2222
9
2020-07-14 05:10:47
<p>im having a lot of trouble with this statement. I basically want it so when the wave reaches "2" a boss will spawn in. i have this coded so far</p> <pre class='brush: lua'>while wait do if game.ReplicatedStorage.Values.Wave.Value == 2 then game.ReplicatedStorage.BOSS.Zombie:Clone().Parent = game.Workspac...
109016
0
How could you give all players different numbers for matchmaking?
5474129
anthonypjo
5
2019-02-06 04:41:48
<p>So basically I am trying to set up do a matchmaking that will give each players a target. So basically they hunt each others.</p> <p>So far I have come up with this:</p> <pre class='brush: lua'><br />local players = {} local alive = {} local dead = {} -------------------------- game.Players.PlayerAdded:connect(funct...
75788
1
How do i find the &quot;pitch&quot; angle of a CFrame/vector?
929847335
TheDude646
72
2022-03-05 19:19:39
<p>i'm trying to simulate bullets using several raycasts chained together and i handle the bullet drop by storing a separate value for downwards speed. the problem is i need to figure out how long to make the raycast and i'm planning on using the cosine law but that requires an angle</p>
129203
1
116901
1
260954816
ThatDevTim
188
2022-03-05 20:24:45
<p>https://developer.roblox.com/en-us/api-reference/datatype/CFrame</p> <p>or</p> <p>https://devforum.roblox.com/t/how-to-get-a-cframes-angles/238958/2</p> <p>might help</p>
0
Why Won't Damage Code Work Inside This Attack's Script?
58556863
Wolf5429
15
2018-04-20 00:05:00
<p>So I've been trying to get this attack of mine to do damage. The script creates a long cylinder as if its a "beam" and the goes through some loops to keep it centered with the characters HumanoidRootPart. I went and tried to add damage so that it would do about 5 damage every 1 second that it is touched but no damag...
57108
0
Get data client data from server?
1322411011
Bin_Latin
2
2021-01-12 22:13:38
<p>Is there a way to get data that's stored on the client from the server without having any scripts on the client that would send it? I know the simple way would be to use remote events, but in my case, I cannot. Is there a way to cross the replicated boundary some other way perhaps using metatables and whatnot?</p>
118610