|
| 12 Sep 2011 05:01 PM |
Script:
shirtid = "http://www.roblox.com/asset/?id=59644693" game.Players.PlayerAdded:connect(function(p) if p['Shirt Graphic']Graphic == shirtid then local s = Instance.new("Sparkles", p.Torso) wait(5) s:Remove() end end)
Output:
Workspace.VIP Script:3: 'then' expected near 'Graphic'
|
|
|
| Report Abuse |
|
|
|
| 12 Sep 2011 05:02 PM |
Do this instead:
if p['Shirt Graphic'].Graphic == shirtid then
|
|
|
| Report Abuse |
|
|
|
| 12 Sep 2011 05:05 PM |
It says:
Shirt Graphic is not a valid member of Player |
|
|
| Report Abuse |
|
|
| |
|
|
| 12 Sep 2011 05:06 PM |
| I think ShirtGraphic is only there is the player is wearing a T-Shirt. |
|
|
| Report Abuse |
|
|
|
| 12 Sep 2011 05:07 PM |
No you don't put a space there -_-
It's wort of like this:
game.Workspace['Example Brick']Transparency
You don't need the periods. |
|
|
| Report Abuse |
|
|
|
| 12 Sep 2011 05:07 PM |
if p['Shirt Graphic'].Graphic == shirtid then
-[::ƧѡÎḾḠΰῩ::]- -[::Maker of stuff and breather of air::]- |
|
|
| Report Abuse |
|
|
|
| 12 Sep 2011 05:08 PM |
| You need 1. I bet you don't know how to index tables. |
|
|
| Report Abuse |
|
|
|
| 12 Sep 2011 05:08 PM |
| Wait, yeah there is a space in 'Shirt Graphic'. :P |
|
|
| Report Abuse |
|
|
|
| 12 Sep 2011 05:09 PM |
| @swimguy it doesn't work. And you don't use a period. |
|
|
| Report Abuse |
|
|
|
| 12 Sep 2011 05:10 PM |
| @stuntkid: Do you know what the script is even doing when you put []? |
|
|
| Report Abuse |
|
|
|
| 12 Sep 2011 05:11 PM |
@stunt
Yes you do.
workspace['part'].Transparency = .2
No . between workspace and [, but you DO have a . after ] and before Transparency.
-[::ƧѡÎḾḠΰῩ::]- -[::Maker of stuff and breather of air::]- |
|
|
| Report Abuse |
|
|
|
| 12 Sep 2011 05:15 PM |
Yes I do, when you have a space in a name you have to put ['Example Name'] And the brackets are used as periods. Try this and try to prove me wrong :P Insert a brick in workspace. Name it Example Brick And insert this script under workspace:
game.Workspace['Example Brick']Transparency = 0.5
And try to prove me wrong XP |
|
|
| Report Abuse |
|
|
|
| 12 Sep 2011 05:17 PM |
I will. You use []'s when you locate an element in a table that has a string for an index. The []'s are NOT substitutes for periods, which is why you use one after the ] if you need to access something within the object you specified.
-[::ƧѡÎḾḠΰῩ::]- -[::Maker of stuff and breather of air::]- |
|
|
| Report Abuse |
|
|
|
| 12 Sep 2011 05:17 PM |
LOLOK You proved me wrong XD
But I done that before in other scripts I've made and it worked fine!
But the script still doesn't work. |
|
|
| Report Abuse |
|
|
|
| 12 Sep 2011 05:18 PM |
Not just for a string as an index, ATable[1] will work just fine if there is an index of 1.
-[::ƧѡÎḾḠΰῩ::]- -[::Maker of stuff and breather of air::]- |
|
|
| Report Abuse |
|
|
|
| 12 Sep 2011 05:18 PM |
@stunt: U Fail so much...
When you put square brackets, you are indexing a table.
t = {h={x={"yo"}}}
print(t[h].x) -> "yo"
And I will prove you wrong also. |
|
|
| Report Abuse |
|
|
|
| 12 Sep 2011 05:19 PM |
| OK I GET IT! NOW FIX THIS SCRIPT! |
|
|
| Report Abuse |
|
|
| |
|
|
| 12 Sep 2011 05:21 PM |
Ok, I just did this in a script:
print(workspace['Base'].Transparency) --Using a .
>0
Then I did this:
print(workspace['Base']Transparency) --No .
>Mon Sep 12 17:19:58 2011 - Workspace.Script:3: ')' expected near 'Transparency'
You use a . End of discussion
-[::ƧѡÎḾḠΰῩ::]- -[::Maker of stuff and breather of air::]- |
|
|
| Report Abuse |
|
|
|
| 12 Sep 2011 05:22 PM |
| I DON'T CARE ANYMORE! FIX THIS SCRIPT OR GET OUT! |
|
|
| Report Abuse |
|
|
|
| 12 Sep 2011 05:22 PM |
Wow I can't believe I just noticed you are trying to access a shirt graphic of a player.
It's in the character. |
|
|
| Report Abuse |
|
|
|
| 12 Sep 2011 05:23 PM |
I'm done.
<--THREAD CLOSED-->
I can't take you people. |
|
|
| Report Abuse |
|
|
|
| 12 Sep 2011 05:24 PM |
| Well that's bad for you, because I know how to fix it. But wutever, ur choice. |
|
|
| Report Abuse |
|
|
|
| 12 Sep 2011 05:25 PM |
You're getting all mad at US because you made a mistake? Seriously, I make mistakes every day and I don't ragequit when someone else tells me what I'm doing wrong...
-[::ƧѡÎḾḠΰῩ::]- -[::Maker of stuff and breather of air::]- |
|
|
| Report Abuse |
|
|