|
| 16 Dec 2012 02:25 PM |
Can you tell me how i can get the full name of an object? As example the name of the part is Fullblabla 2 2 1 and i just know Fullbla, how i can remove this? |
|
|
| Report Abuse |
|
|
jelly134
|
  |
| Joined: 25 Aug 2008 |
| Total Posts: 1137 |
|
|
| 16 Dec 2012 02:26 PM |
| Please try to explain that again. |
|
|
| Report Abuse |
|
|
jelly134
|
  |
| Joined: 25 Aug 2008 |
| Total Posts: 1137 |
|
|
| 16 Dec 2012 02:27 PM |
name = "Fullbla"
c = game.Workspace:GetChildren() for i=1, #c do if string.sub(c[i].Name,1,string.len(name)) == name then --do stuff with c[i] end end
|
|
|
| Report Abuse |
|
|
|
| 16 Dec 2012 02:28 PM |
local alliknow = "fullbla"
local found = nil
for _, v in pairs(workspace:children()) do if string.find(string.lower(v.Name), alliknow) then found = v end end
I don't know, that seems like the best way I could think of doing it at the moment. |
|
|
| Report Abuse |
|
|
|
| 16 Dec 2012 02:33 PM |
| I had this. I can't find the post. >_< |
|
|
| Report Abuse |
|
|