|
| 11 Aug 2015 10:32 AM |
Localscript:
_G.GlobalFunction(arg1, arg2) -- Where does arg3, 4, 5, and 6 come from? end
GlobalFunction Script:
_G["GlobalFunction"] = function(arg1, arg2) --blahblahblah return{arg3, arg4, arg5, arg6} end |
|
|
| Report Abuse |
|
|
|
| 11 Aug 2015 10:39 AM |
local table = {arg3,arg4,arg5,arg6} return table
VB.NET, C#, C++, PHP and much more |
|
|
| Report Abuse |
|
|
|
| 11 Aug 2015 10:50 AM |
| Hmm... How would the LocalScript access those values? |
|
|
| Report Abuse |
|
|
chimmihc
|
  |
| Joined: 01 Sep 2014 |
| Total Posts: 17143 |
|
| |
|
|
| 11 Aug 2015 11:07 AM |
| well then, got to learn how to use those two.. |
|
|
| Report Abuse |
|
|
|
| 11 Aug 2015 11:17 AM |
"Modules and RemoteEvents." You'll want RemoteFunctions for this. |
|
|
| Report Abuse |
|
|
|
| 11 Aug 2015 11:59 AM |
OK. So I gave ModuleScripts a look. BUT.....?
=================================================== ModuleScript: =================================================== local module = {}
module.returnOtherArgs= function(arg1, arg2) --blahblah return arg3, arg4, arg5 end
return module
=================================================== LocalScript: =================================================== local getmod = require(game.ServerScriptService.Module)
print(getmod.returnOtherArgs(arg1, arg2))
=================================================== Output: =================================================== nil 4 nil 5
How do I use 4, and 5 in the local script? ASDFHUG
|
|
|
| Report Abuse |
|
|
|
| 11 Aug 2015 12:01 PM |
| oops ignore that second nil |
|
|
| Report Abuse |
|
|
|
| 11 Aug 2015 12:13 PM |
| I'm guessing module scripts only return arguments that are passed to the function? |
|
|
| Report Abuse |
|
|