8SunTzu8
|
  |
| Joined: 30 Sep 2011 |
| Total Posts: 8199 |
|
|
| 11 Jan 2013 03:46 PM |
http://www.roblox.com/Forum/ShowPost.aspx?PostID=86714771
If this fits you, just post some information about yourself. I don't care where it is posted, or if you send me a message. Just looking for people. (Not offering virtual money, this is for people who might want something to do or to work on something different).
I am also curious as to how I can write a recursive function. (Might be one of the tests I'd do for a scripter, it came to mind).
I've used recursive functions in math last year, but like I can remember that.
The basic set up seemed to be:
f(x) = x[0] + (1.35*x[x+1])
I attempted to make one, but it didn't work as I wanted it to. I thought that perhaps you would run the function again, but in mathematics, that's not the case.
(An example, to search a place for all parts and perform an action, and open all models to find parts stored within them).
"If you want to become a Developer or Innovator for CSA, contact me." |
|
|
| Report Abuse |
|
|
SN0X
|
  |
| Joined: 24 Oct 2011 |
| Total Posts: 7277 |
|
|
| 11 Jan 2013 03:52 PM |
Ally our primarys pls
Also,
local function ActionOnObject(o) --All descendants fire this function with o as the object --code here... end
local function Get(o) -- gets all descendants and fires ActionOnObject for _, v in pairs(o:GetChildren()) do Get(o) end end
Get(Game) |
|
|
| Report Abuse |
|
|
|
| 11 Jan 2013 03:54 PM |
Multiple Ideas hurt my single-core brain.
Please rephrase in a more linear format. |
|
|
| Report Abuse |
|
|
8SunTzu8
|
  |
| Joined: 30 Sep 2011 |
| Total Posts: 8199 |
|
|
| 11 Jan 2013 04:04 PM |
Done.
"If you want to become a Developer or Innovator for CSA, contact me." |
|
|
| Report Abuse |
|
|
booing
|
  |
| Joined: 04 May 2009 |
| Total Posts: 6594 |
|
|
| 12 Jan 2013 10:39 PM |
| You treated x as an array and an integer. |
|
|
| Report Abuse |
|
|
8SunTzu8
|
  |
| Joined: 30 Sep 2011 |
| Total Posts: 8199 |
|
|
| 13 Jan 2013 03:56 AM |
I was just using the [] to show which "x" it was. Normally you'd see "n".
Such as the first x, and then x + 1 would represent the last x and the next x, although, I probably should have done f(x+1). Don't know though, it was a long time ago.
"If you want to become a Developer or Innovator for CSA, contact me." |
|
|
| Report Abuse |
|
|