Page 1 of 1

My monumentally EPIC idea.

Posted: Tue Aug 25, 2009 5:03 pm
by ibly31
Okay. So I was sitting there and BAM! This amazing idea popped into my head. I immediately began writing it down and this is what I came up with:

A scripting platform for the iPhone/ iPod Touch.

I have no idea if this has been created or is in development, but I think it could change everything. So this "iCode" platform, or rather a series of tools, would be basically an iPhone application, a desktop editor(I'm fairly proficient in Visual Basic, and have no experience with Mac programming, and have absolutely no access to a Linux computer), and a website, that is written(hopefully) in PHP, which I guess I could say I'm proficient in. It would have a database of user's scripts that people could share, rate, comment, download, and all that jazz. You could also share scripts directly if you are on the same network as someone. These scripts could be anything from games(OpenGL enhanced, none of that Quartz/ CoreGraphics stuff), to utilities, and even, if I ever get around to it, people could create their own User interfaces using actual UI objects.

This is just an idea, and most likely won't get anywhere, but if it did, I think it could change everything. I don't want to use an already built scripting language such as Lua, because I think it would be too heavy for a mobile platform( I am 90% sure I am wrong), and I think it would be a good learning experience to write my own text parser that parses the scripts and acts dynamically during run-time of the script.

Basic functions would be stuff like:
orientation("Right" or "Left" or "Portrait") -- for changing (0,0) to be in the bottom left corner depending on the iPhone's orientation.
pixelOn(X, Y, R, G, B) -- Turn a pixel on at a certain point.
pixelOff(X, Y) -- Short for pixelOn(X,Y, 0,0,0) for black
apply_image(X, Y, image) -- apply an image, obviously
load_image(imageCode, imageSlot) -- I think i would use numbers for the image names like OpenGL does. look down underneath this block for more info on imageCode.
getAllTouches() -- get the current touch locations
getAccelData() -- gets the current accelerometer X, Y, Z values to detect movement and stuff.
setAccelSpeed() -- this would set how many times a second the accelerometer refresh would be.
setFPS(number)
and so on.

I would probably have my website as a host for all the images. You would use a form on my website to upload an image, and it would give you a code for the image.

This is waaaay beyond my programming skills, and any help would be appreciated. Right now, I'm just trying to understand basic compiler theory. I know it wouldnt be a "compiler" but the same aspect of pasrsing the text for code would be similar. I think the basic idea would be to use strtok(CodeString, ";") to seperate the lines.

My made-up scripting language would be called "ibly". :D

Thank you for reading and enduring my rant. :D

Re: My monumentally EPIC idea.

Posted: Tue Aug 25, 2009 5:39 pm
by Falco Girgis
ibly wrote:I don't want to use an already built scripting language such as Lua, because I think it would be too heavy for a mobile platform( I am 90% sure I am wrong),
100% wrong. If Lua is in use for consoles such as the Dreamcast, PS2, and PSP generation with 200, 300, and 330 mhz respectively, I'm pretty damn sure that Lua is going to be lightweight enough to run on an iPhone's 600mhz processor.

Lua is the most lightweight mainstream scripting language that I have ever seen or used. No offense, but if you think that you are going to develop something more lightweight than Lua, you might need to do a little bit more learning.

The idea (as I interpret it) just seems like an open-source App-store where all programs are written in the same scripting language. It would definitely be fun for hobbyists to screw around with, but I really doubt you would be able to develop such a thing. There's probably something that Apple has done to prohibit such a thing.

Re: My monumentally EPIC idea.

Posted: Tue Aug 25, 2009 6:19 pm
by ibly31
Hah, I knew right after I said it that saying Lua is too heavy for the iPhone was the wrong thing to say. And the thought that apple would make this very hard to do, legally, crossed my mind, but I still think that its possible, I don't see what Apple could turn me down for? Replicating iPhone features?

Re: My monumentally EPIC idea.

Posted: Tue Aug 25, 2009 7:12 pm
by M_D_K
So basically it's LuaPlayer for the iPhone/iTouch. Except with a different scripting language.

And Apple might turn you down for giving people the ability to bypass their app store.

Re: My monumentally EPIC idea.

Posted: Tue Aug 25, 2009 9:04 pm
by ibly31
never heard of LuaPlayer. but I guess.

Re: My monumentally EPIC idea.

Posted: Tue Aug 25, 2009 10:19 pm
by Falco Girgis
Doesn't Apple have some sort of restriction on networking like this? Or some sort of store?

And I'm sure they would murder you if they thought that this conflicted in any way with the app store. ;)

Re: My monumentally EPIC idea.

Posted: Wed Aug 26, 2009 5:46 pm
by ibly31
Forget what I said right here if you have already read it. I'll figure it out by myself, and ask specific questions as I need to.

One thing that makes me sad: I read somewhere that a Lua interpreter in xCode cannot accept arbitrary Lua files and interpret them at runtime. Is that the same for all Lua projects on any OS, or just for the iPhone?

Re: My monumentally EPIC idea.

Posted: Wed Aug 26, 2009 6:46 pm
by andrew
ibly31 wrote:One thing that makes me sad: I read somewhere that a Lua interpreter in xCode cannot accept arbitrary Lua files and interpret them at runtime. Is that the same for all Lua projects on any OS, or just for the iPhone?
Commodore64 iPhone app finished, denied by Apple

The legally licensed project (which has been in development for over a year) was denied due to a clause in the iPhone SDK agreement which states, "an Application may not itself install or launch other executable code by any means."

If this is even relevant to the topic, I would say iPhone only.

Re: My monumentally EPIC idea.

Posted: Wed Aug 26, 2009 9:21 pm
by Falco Girgis
It's this kind of thing that convinces me that Apple is actually far worse than Microsoft.

Re: My monumentally EPIC idea.

Posted: Wed Aug 26, 2009 10:48 pm
by ibly31
Damn. Well. That COMPLETELY destroys my idea. Unless I decided to create apps for Jail Broken iPods, I'm completely screwed.

Re: My monumentally EPIC idea.

Posted: Thu Aug 27, 2009 12:08 pm
by gordon
GyroVorbis wrote:It's this kind of thing that convinces me that Apple is actually far worse than Microsoft.
With regards to DRM and such they really are.