Csstform, on 15 June 2014 - 04:21 AM, said:
OneOS Version 2 - The All in One Operating System
#461
Posted 15 June 2014 - 05:54 AM
#462
Posted 15 June 2014 - 02:03 PM
Also, some people do use other languages. GravityScore's Brainfuck interpreter, someone made a peripheral for Jython a while back, etc.
#463
Posted 15 June 2014 - 08:39 PM
i tried to install the oneos into the adv computer and it said. check your internet connection. nothing is being blocked.
#464
Posted 15 June 2014 - 09:45 PM
awsmazinggenius, on 15 June 2014 - 02:03 PM, said:
Also, some people do use other languages. GravityScore's Brainfuck interpreter, someone made a peripheral for Jython a while back, etc.
I don't know of anyone who's really made an actual program out of it really. Still, can't hurt to add it.
#465
Posted 16 June 2014 - 12:16 AM
#466
Posted 16 June 2014 - 05:04 AM
awsmazinggenius, on 15 June 2014 - 02:03 PM, said:
Also, some people do use other languages. GravityScore's Brainfuck interpreter, someone made a peripheral for Jython a while back, etc.
#467
Posted 17 June 2014 - 12:33 PM
#470
Posted 21 June 2014 - 11:54 PM
I managed to find a backup somewhere with some newish code, although it doesn't have any OneCode stuff. Because of this I've focused on the actual programs, the API driving everything and their format.
Here is the code for a fairly basic program with a clickable button that changes text when you click on it. In my previous system this would be about 100 - 200 lines, let alone programs in which people had to write their own API, but this is only 14 lines, most of which is actually formatting! If you remove the unneeded lines it's only 7.
OneOS.LoadAPI('/System/API/Bedrock.lua', false) OneOS.LoadAPI('/System/API/Drawing.lua') OneOS.LoadAPI('/System/API/View.lua') OneOS.LoadAPI('/System/API/Button.lua') local program = Bedrock:Initialise() program:ObjectClick('Button1', function(self, event, side, x, y) self.Text = 'Hi' end) program:Run(function() program:LoadView('main') end)
Which creates, when clicked:
In future I'm also looking to remove the loadAPIs (other than Bedrock [the main framework] of course).
This code is loading a view called main, which you'll design with drag and drop, from a file that looks like this:
{ ["Objects"]={ [1]={ ["Y"]=2, ["X"]=2, ["Name"]="Button1", ["Type"]="Button", ["Text"]="A Button" }, }, ["BackgroundColour"]=8192, }
In the designer you'll be able to set a name for each object (e.g. button) which allows you to easily get that object and set what happens when it's clicked etc.
Here is a bit of code and comments showing what you can either do at the moment or will be added very soon.
You'll noticed that there is no while loop or a huge if statement for events.
All events have a function that you can assign which is called when fired If it's a custom event you can use RegsterEvent.
This is all very early stages, I've only just got it working. But essentially I'd like feedback on the style and layout of it. If people don't like how it works they won't use it, which makes the entire thing pointless.
Edited by oeed, 22 June 2014 - 12:18 AM.
#471
Posted 22 June 2014 - 12:36 AM
#472
Posted 22 June 2014 - 02:09 AM
Jiloacom, on 22 June 2014 - 12:36 AM, said:
Thanks!
I should also mention a few other things.
Most importantly, everything is subject to change, even the stuff above is rather out of date. Sometimes I realise that one way of doing something does work as well, so I end up changing huge amounts.
I've also been working speeding up drawing, sometimes it gets really slow. To help with this all objects now cache their drawing, meaning that if it's asked to draw and it already has but the content is still the same it won't have to recalculate a whole ton of stuff. To be honest I don't really know if this will improve the situation (although I presume it will). I'm also looking in to making the buffering system quicker.
This will, yet again, push the 1.2 release forward. I've decided to essentially convert all the programs across to this framework, it'll save a ton of space and allow for easier editing in the future. I haven't decided if OneCode will be included with 1.2 though, that might come 1.3 (which will probably be only a few weeks later).
Edit: So, I've also decided it will be beneficial to move to an inheritance based object model. In English, basically all the on-screen objects (buttons, labels, etc) will inherit one base object which has lots of the base code for initialisation, drawing, etc. Kind of like I intended to do with PearOS (although it's worth noting that it didn't actually work in PearOS as I thought it did, it appeared to but didn't really). This too will save a ton of space, it changes all object files from 80+ lines to in many cases just 10. This is due to the radical reengineering the framework has allowed me to do, objects are no longer initialised with their values (width, position, etc). Instead they are injected from the interface file later.
There's a lot of changes, but I really think this will provide a huge boost in terms of speed of OneOS as well as fixing things and future additions.
Edited by oeed, 23 June 2014 - 09:43 AM.
#473
Posted 24 June 2014 - 02:33 AM
Edited by awsmazinggenius, 24 June 2014 - 02:35 AM.
#474
Posted 24 June 2014 - 04:07 AM
awsmazinggenius, on 24 June 2014 - 02:33 AM, said:
I will definitely make it possible for people to release their programs for CraftOS. I'll make a single file minified version for the API, it will probably be under 100KB
#475
Posted 24 June 2014 - 07:46 PM
#476
Posted 24 June 2014 - 09:44 PM
Agoldfish, on 24 June 2014 - 07:46 PM, said:
Also noticed the 2nd most replied to OS is PearOS
In terms of out of all the forums though many forum games and servers beat all the programs by miles.
#477
Posted 29 June 2014 - 02:01 PM
first of all, I gotta say that this is the best OS I've seen so far for computercraft. Well done.
However, I've got one question: If yes, how can you use external monitors?
- MrStickmanPro1
#478
Posted 30 June 2014 - 05:14 AM
#479
Posted 02 July 2014 - 12:00 PM
Please keep up the good work oeed
-========= MRZOMBIEKINS LUA PROGRAMMER =======-
#480
Posted 03 July 2014 - 11:28 AM
Bios:500: Domain not permittedI got this error just while it was Determining latest Version
2 user(s) are reading this topic
0 members, 2 guests, 0 anonymous users