|
| 18 Mar 2017 07:57 PM |
while wait() do Power = script.Parent.Configuration.Power.Value script.Parent.BodyGyro.Power = float.new(Power) end
--------------------------------------------
I don't know what the problem is. I'm using a brick with BodyGyro and I want to be able to edit the P thing with the value in the configuration folder.. But it's not working. Why?
Is there a different way to write the script to make it work? |
|
|
| Report Abuse |
|
|
AxonMega
|
  |
| Joined: 29 Aug 2014 |
| Total Posts: 2403 |
|
| |
|
|
| 18 Mar 2017 08:00 PM |
| I'm using the float property it says on BodyGyro wiki it says float thing... |
|
|
| Report Abuse |
|
|
| |
|
AxonMega
|
  |
| Joined: 29 Aug 2014 |
| Total Posts: 2403 |
|
|
| 18 Mar 2017 08:03 PM |
| A float is a just number that I think has between 1 and 6 digits after the decimal place. Examples: 0.666 ### 4.020 9.11 |
|
|
| Report Abuse |
|
|
|
| 18 Mar 2017 08:03 PM |
So what do I do so that it works with P and D?..
Can you at least tell me what to rewrite to make it work |
|
|
| Report Abuse |
|
|
|
| 18 Mar 2017 08:03 PM |
i think you need a
brain.new()
ROASTED
20,383 |
|
|
| Report Abuse |
|
|
|
| 18 Mar 2017 08:04 PM |
Power = script.Parent.Configuration.Power.Value script.Parent.BodyGyro.Power = Power
Just use the defined variable, no need to get fancy (even if the syntax worked that way) |
|
|
| Report Abuse |
|
|
|
| 18 Mar 2017 08:07 PM |
| It didn't work... Can you help me |
|
|
| Report Abuse |
|
|
| |
|
AxonMega
|
  |
| Joined: 29 Aug 2014 |
| Total Posts: 2403 |
|
|
| 18 Mar 2017 08:11 PM |
| Do you even have the output tab open? |
|
|
| Report Abuse |
|
|
|
| 18 Mar 2017 08:13 PM |
| Yes I do, it doesn't show any error thingy |
|
|
| Report Abuse |
|
|
AxonMega
|
  |
| Joined: 29 Aug 2014 |
| Total Posts: 2403 |
|
|
| 18 Mar 2017 08:19 PM |
| Try putting BodyGyro.P instead of BodyGyro.Power |
|
|
| Report Abuse |
|
|
|
| 18 Mar 2017 08:22 PM |
function change() Power = script.Parent.Configuration.Power.Value script.Parent.BodyGyro.P = Power end change() script.Parent.Configuration.Power.Changed:connect(change)
Assuming you want the gyro's power to always be set to Power, and all the other objects are in place, this is an alternative. |
|
|
| Report Abuse |
|
|
|
| 18 Mar 2017 08:23 PM |
| @Axon, can you go to team create on my game? I invited you |
|
|
| Report Abuse |
|
|
|
| 18 Mar 2017 08:24 PM |
| NVM IT WORKED THANK YOU SO MUCH |
|
|
| Report Abuse |
|
|
|
| 18 Mar 2017 08:33 PM |
| ints are implicitly cast into floats on roblox |
|
|
| Report Abuse |
|
|