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: function?

Previous Thread :: Next Thread 
kjh45 is not online. kjh45
Joined: 15 Feb 2009
Total Posts: 256
14 Jun 2013 04:05 PM
Ok so I am writing a Plugin I have all the Buttons(3) working but I need 3 Functions
1. A function that makes a script and has some custom code in there (for example instead of print 'Hello, World!', it would say what ever i choose such as print 'Thanks for helping').
2. Same as above but as a Local Script.
3. A function that makes a Backpack and a Configuration (exmple: it makes somthing like this
FolderI (Backpack)
>Settings Folder (Configuration) and I can set that how ever I like. )
Report Abuse
kjh45 is not online. kjh45
Joined: 15 Feb 2009
Total Posts: 256
14 Jun 2013 05:18 PM
Ok I got this:
local script = Instance.new("Script")
script.Name = "Test"
script.Parent = game.Workspace
but how do I have it have custom code inside when it is created?
Report Abuse
PyroInfinity is not online. PyroInfinity
Joined: 05 Oct 2012
Total Posts: 243
14 Jun 2013 06:54 PM
local script = Instance.new('Script',Game.Workspace)
script.Name = 'Test'
script.Source = [[

--Source here

]]
Report Abuse
kjh45 is not online. kjh45
Joined: 15 Feb 2009
Total Posts: 256
14 Jun 2013 07:02 PM
Thank you Pyro.
Report Abuse
kjh45 is not online. kjh45
Joined: 15 Feb 2009
Total Posts: 256
14 Jun 2013 07:06 PM
Although you do not capatilize game in game.workspace
Report Abuse
kjh45 is not online. kjh45
Joined: 15 Feb 2009
Total Posts: 256
14 Jun 2013 07:09 PM
Hmm it did not work.
Report Abuse
PyroInfinity is not online. PyroInfinity
Joined: 05 Oct 2012
Total Posts: 243
14 Jun 2013 07:23 PM
kjh yes you do, I am ROBLOX 3rd best free-scripter (someone who scripts for fun) I know my capitalizations.
Report Abuse
Azarth is not online. Azarth
Joined: 17 Aug 2012
Total Posts: 2760
14 Jun 2013 07:24 PM
@pyro lol'd

and you don't even need game. You can just do Workspace.
Report Abuse
CodyTheBuildingKid is not online. CodyTheBuildingKid
Joined: 13 Dec 2011
Total Posts: 4399
14 Jun 2013 07:28 PM
@Pyro, you're funny. :P
Report Abuse
ZekeZakKaz is not online. ZekeZakKaz
Joined: 31 Mar 2012
Total Posts: 13907
14 Jun 2013 08:08 PM
[ Content Deleted ]
Report Abuse
darkggod is not online. darkggod
Joined: 04 Feb 2011
Total Posts: 8316
14 Jun 2013 08:28 PM
I'm pretty sure script.Source is locked, without like level 5ish access..

~LS Emperor Darkggod~
Report Abuse
kjh45 is not online. kjh45
Joined: 15 Feb 2009
Total Posts: 256
14 Jun 2013 08:37 PM
Well how do I unlock it?
Report Abuse
darkggod is not online. darkggod
Joined: 04 Feb 2011
Total Posts: 8316
14 Jun 2013 08:51 PM
Become an admin and work for ROBLOX, or you know.. xploitz11

~LS Emperor Darkggod~
Report Abuse
CodyTheBuildingKid is not online. CodyTheBuildingKid
Joined: 13 Dec 2011
Total Posts: 4399
14 Jun 2013 08:55 PM
Plugins have access to the script's source I believe.
Report Abuse
jbjgang2 is not online. jbjgang2
Joined: 07 Feb 2010
Total Posts: 8948
14 Jun 2013 11:15 PM
no. you have it all wrong. first you need to re-calibrate the Positron Emitting Navigation Increment System, Then proceed with extra coding of the Damage Inverted Calibration Kortex. I hope that this is helpful and does you good :)
                             ~ jbjgang2
Report Abuse
ArbiterOfDeath is not online. ArbiterOfDeath
Joined: 20 Jun 2011
Total Posts: 1458
15 Jun 2013 12:35 AM
local function CreateScript (source, bool)
local NewScript = Instance.new(bool and "LocalScript" or "Script");
NewScript.Name = "Custom Script";
NewScript.Source = source;
NewScript.Parent = Workspace;

--[[
void function CreateScript ( source, [bool = false])
This function will create a LocalScript if bool is false, nil, or not given and a regular Script otherwise with the same source code as source.
]]
Report Abuse
kjh45 is not online. kjh45
Joined: 15 Feb 2009
Total Posts: 256
15 Jun 2013 06:29 AM
so I replace the source part with what I want correct?
Report Abuse
Unsubstantial is not online. Unsubstantial
Joined: 11 Sep 2012
Total Posts: 872
15 Jun 2013 07:40 AM
@jbj LOL
Report Abuse
kjh45 is not online. kjh45
Joined: 15 Feb 2009
Total Posts: 256
15 Jun 2013 12:33 PM
arbiter it did not work....
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