Chrapnel
|
  |
| Joined: 01 Feb 2014 |
| Total Posts: 951 |
|
|
| 30 Dec 2014 08:17 AM |
blue1 = colordropper.blues.blue1 blue2 = colordropper.blues.blue2
blue2.Name = "blue1"
even though i change blue2's name to blue1, the script still thinks it is blue2.
how do i fix this? |
|
|
| Report Abuse |
|
|
|
| 30 Dec 2014 08:20 AM |
um... variables dont have names as far as I know... try this instead
blue1 = colordropper.blues.blue1 blue2 = colordropper.blues.blue2
blue2 = blue1
-- are you trying to assign blue2 to the blue1 variable or trying to assign blue 2 to the string "blue1" |
|
|
| Report Abuse |
|
|
Chrapnel
|
  |
| Joined: 01 Feb 2014 |
| Total Posts: 951 |
|
|
| 30 Dec 2014 08:24 AM |
both, i want blue2's name to change to blue1 and also be called with 'blue1', not 'blue2'
but i'll try your method, thanks!!! |
|
|
| Report Abuse |
|
|
|
| 30 Dec 2014 08:27 AM |
| im not quite sure if you can change a variable name... I'll investigate that |
|
|
| Report Abuse |
|
|
|
| 30 Dec 2014 08:28 AM |
dont think you can, you can only assign the value of a variable to another variable
http://wiki.roblox.com/index.php?title=Variable |
|
|
| Report Abuse |
|
|
eLunate
|
  |
| Joined: 29 Jul 2014 |
| Total Posts: 13268 |
|
|
| 30 Dec 2014 08:28 AM |
| Eh what -exactly- are you trying to do? Since there are very limited practical applications in scripting for what I think you're attempting |
|
|
| Report Abuse |
|
|
Chrapnel
|
  |
| Joined: 01 Feb 2014 |
| Total Posts: 951 |
|
|
| 30 Dec 2014 08:35 AM |
imagine a cup dispenser that holds 5 cups at any one time the cups are labelled 1-5, 1 being the bottommost cup when someone takes cup 1, it disappears from the game. the 4 remaining cups move down and now cup 2 is the bottommost cup.
i want cup 2 to inherit cup1's properties, name, variable path etc.
basically i want cup 1 to always be the cup at the bottom, and i've been trying to switch variables so that happens. |
|
|
| Report Abuse |
|
|
Chrapnel
|
  |
| Joined: 01 Feb 2014 |
| Total Posts: 951 |
|
| |
|