generic image
Processing...
  • Games
  • Catalog
  • Develop
  • Robux
  • Search in Players
  • Search in Games
  • Search in Catalog
  • Search in Groups
  • Search in Library
  • Log In
  • Sign Up
  • Games
  • Catalog
  • Develop
  • Robux
   
ROBLOX Forum » Game Creation and Development » Scripting Helpers
Home Search
 

Re: Trying to learn how to script?

Previous Thread :: Next Thread 
FabulousHarley is not online. FabulousHarley
Joined: 09 Nov 2013
Total Posts: 19
08 Dec 2013 02:59 AM
I tried using this script and it didn't work. There was no script errors on Studio but it still didn't work. Help please!

local Message = Instance.new("Message") -- Defines a new instance of a message for the entire script
Message.text = "Hello World" -- Sets text in message
Message.Parent = game.Workspace -- Our message is now inside Workspace
wait(5) --Waits 5 seconds
Message:Remove() --Removes message
Report Abuse
FreeScriptMaker is not online. FreeScriptMaker
Joined: 29 Nov 2013
Total Posts: 2275
08 Dec 2013 03:02 AM
local Message = Instance.new("Message", game.Workspace) --instead of setting its parent later we can set it now
Message.text = "Hello World" --Lua is case sensitive so it must be Text not text
wait(5)
Message:Destroy() --You should use Destroy not Remove
Report Abuse
KEVEKEV77 is not online. KEVEKEV77
Joined: 12 Mar 2009
Total Posts: 6961
08 Dec 2013 03:06 AM
and it's remove()
nor Remove

and it should be .Text, make sure to check for caps and stuff
Report Abuse
FreeScriptMaker is not online. FreeScriptMaker
Joined: 29 Nov 2013
Total Posts: 2275
08 Dec 2013 03:07 AM
@KEVEKEV77
remove and Remove are the same thing but neither should be used. Instead you should use Destroy
Report Abuse
wazap is not online. wazap
Joined: 29 Jun 2007
Total Posts: 23234
08 Dec 2013 03:08 AM
Or instead of wait(5) Message:Destroy() you can combine it into one line using this

game.Debris:AddItem(Message, 5) --This makes Message Disappear in 5 seconds.
Report Abuse
brinkokevin is not online. brinkokevin
Joined: 25 Jul 2012
Total Posts: 1673
08 Dec 2013 03:32 AM
local Message = Instance.new("Message",game.Workspace) -- you can do it like this to do it faster
Message.Text = "Hello World" -- Text not text
wait(5) --Waits 5 seconds
Message:remove() --idk why but i like remove :D
Report Abuse
vlekje513 is not online. vlekje513
Joined: 28 Dec 2010
Total Posts: 9057
08 Dec 2013 06:41 AM
I also like remove, hate it that it is decrated -- or a word that looks alike it
Report Abuse
TheRobloxian909 is not online. TheRobloxian909
Joined: 08 Aug 2013
Total Posts: 2444
08 Dec 2013 07:17 AM
If it still won't work, try using 'destroy()'

//:Future ROBLOX Moderator or Administrator:\\
Report Abuse
KEVEKEV77 is not online. KEVEKEV77
Joined: 12 Mar 2009
Total Posts: 6961
09 Dec 2013 07:43 PM
actually, I think this wpuld be better wazap, this is a function

game:GetService("Debris"):AddItem(message,5)
Report Abuse
Previous Thread :: Next Thread 
Page 1 of 1
 
 
ROBLOX Forum » Game Creation and Development » Scripting Helpers
   
 
   
  • About Us
  • Jobs
  • Blog
  • Parents
  • Help
  • Terms
  • Privacy

©2017 Roblox Corporation. Roblox, the Roblox logo, Robux, Bloxy, and Powering Imagination are among our registered and unregistered trademarks in the U.S. and other countries.



Progress
Starting Roblox...
Connecting to Players...
R R

Roblox is now loading. Get ready to play!

R R

You're moments away from getting into the game!

Click here for help

Check Remember my choice and click Launch Application in the dialog box above to join games faster in the future!

Gameplay sponsored by:
Loading 0% - Starting game...
Get more with Builders Club! Join Builders Club
Choose Your Avatar
I have an account
generic image