Jump to content




Mimic - ComputerCraft Web Emulator (HTML5)



196 replies to this topic

#21 SuicidalSTDz

    Permutator of Strings

  • Members
  • 1,308 posts
  • LocationPennsylvania

Posted 20 March 2014 - 01:24 AM

This is pretty neat, but I do have one question. Do you plan on history support, like the native lua prompt provides?

Edit: Already asked, whoops ^_^

Edited by SuicidalSTDz, 20 March 2014 - 01:25 AM.


#22 Cranium

    Ninja Scripter

  • Moderators
  • 4,031 posts
  • LocationLincoln, Nebraska

Posted 20 March 2014 - 01:25 AM

This is actually really, really nice. Totally +1'ed.
I effectively had to stop writing CC programs because I didn't have an emulator to test on at work, and having an easily accessed web based emulator is just the best for me.
I expect great things here.

EDIT: also, where are files stored locally? Chrome informed me that it wanted my permission to save files locally.

Edited by Cranium, 20 March 2014 - 01:26 AM.


#23 theoriginalbit

    Semi-Professional ComputerCrafter

  • Moderators
  • 7,332 posts
  • LocationAustralia

Posted 20 March 2014 - 01:40 AM

View PostCranium, on 20 March 2014 - 01:25 AM, said:

EDIT: also, where are files stored locally? Chrome informed me that it wanted my permission to save files locally.
I'd assume its in Chromes application data. I had a quick Google and couldn't find a path its stored, if you want to take a look yourself I'd assume they're using HTML5 Permanent Storage.

#24 1lann

  • Members
  • 516 posts
  • LocationSeattle

Posted 20 March 2014 - 06:19 AM

Yep, indeed it is HTML5 permanent storage. We're also planning to allow you download the computer as a zip through JS.

Although I haven't been working on this lately, as I had lots of school work. On the weekends I'll be more determined to work on it, but if I can't then It'll most probably be finished on my term break (A month away)

#25 Cranium

    Ninja Scripter

  • Moderators
  • 4,031 posts
  • LocationLincoln, Nebraska

Posted 20 March 2014 - 01:41 PM

I see. But I meant if I decide to create a file via the fs api, can I pull it up and edit it?

#26 GravityScore

  • Members
  • 796 posts
  • LocationLand of Meh

Posted 20 March 2014 - 02:35 PM

Another sneak peak version coming. Improvements:
  • Images instead of fonts, so no anti-aliasing on the text now :D
  • Supposedly working FS API (not very well tested). If the computer hangs, check the JS console. Note you have to run fs.makeDir('/') first
  • Improved Lua prompt, with command history and arrow key movement working
  • Added os.reboot and os.shutdown
  • A half implemented too long without yielding (a simple while true do end will not trigger it, but something like while true do term.write('blah') end will)
  • In progress GUI
  • Safari Support! :D
If it doesn't work at first, try refreshing the page a couple of times just to refresh the browser cache.

#27 1lann

  • Members
  • 516 posts
  • LocationSeattle

Posted 20 March 2014 - 02:38 PM

View PostCranium, on 20 March 2014 - 01:41 PM, said:

I see. But I meant if I decide to create a file via the fs api, can I pull it up and edit it?
Oh that, no it's not stored on your computer's filesystem, it's stored in Chrome's storage. So you can't pull it up with your favourite text editor and edit it like that :( You'll have to use the in-browser Ace editor if you want to edit files live (Which I have to admit is pretty nice). However, we may release a standalone version that allows you to do this with node-webkit.

#28 InputUsername

  • Members
  • 231 posts
  • LocationThe Netherlands

Posted 20 March 2014 - 04:30 PM

Looking forward to this being completed! Looking nice so far.

#29 MostwantedRBX

  • Members
  • 29 posts
  • LocationWell. I suppose between here and there.

Posted 20 March 2014 - 08:22 PM

Yay, arrow key suport. :D (+1nd this, btw.)

#30 GravityScore

  • Members
  • 796 posts
  • LocationLand of Meh

Posted 21 March 2014 - 10:10 AM

Another updating coming. This time with FS API! :D
Changes:
  • Proper too long without yielding now :D
  • FS API
  • Contents of file system persist over page reloads (excluding empty directories)
  • fs.move and fs.copy aren't implemented
  • fs.delete can't delete directories
Note it behaves roughly like the CC one. It's not a noticable difference, but calling .readAll() always returns the contents of the file, ie there is no cursor position in the file.

Edited by GravityScore, 21 March 2014 - 10:16 AM.


#31 awsmazinggenius

  • Members
  • 930 posts
  • LocationCanada

Posted 21 March 2014 - 04:58 PM

Gravity, does this FS update still mean that we have to run ms.makeDir("/") first?

#32 Csstform

  • Members
  • 410 posts
  • LocationU.S.A.

Posted 21 March 2014 - 06:29 PM

Feature Request!

I know that iOS (at least iPod) is capable of HTML5 webapps. I would like to request that this can function as one, or, if you could somehow tell my iPod to open it's keyboard so I can type.

#33 TheOddByte

    Lazy Coder

  • Members
  • 1,607 posts
  • LocationSweden

Posted 21 March 2014 - 06:51 PM

View PostCsstform, on 21 March 2014 - 06:29 PM, said:

Feature Request!

I know that iOS (at least iPod) is capable of HTML5 webapps. I would like to request that this can function as one, or, if you could somehow tell my iPod to open it's keyboard so I can type.
I agree with this feauture, Since it doesn't seem there is any other emulator currently that supports iOS.
Is this designed for an american keyboard? :P
Since it seems when I press 8 + shift where '(' should be inputted I get '*' and when I press 9 + shift where I should get ')' I get '(' etc.
( Nice date the latest update was :P )

#34 awsmazinggenius

  • Members
  • 930 posts
  • LocationCanada

Posted 22 March 2014 - 02:19 AM

I'm not sure what keyboard layout this was designed for. Assuming you're on windows, check your settings, as at least for me as I'm Canadian Windows would piss me off and change my layout randomly to "Canadian French" even after I changed my settings until I bit the bullet and just changed my locale to the US. You may have a similar problem where you live, depending on the local language there.

I get mixed results when using an Apple Wireless Keyboard to input text. Sometimes it works, sometimes it doesn't. iPad Air, latest Chrome app and iOS 7.1

Edited by awsmazinggenius, 22 March 2014 - 02:20 AM.


#35 1lann

  • Members
  • 516 posts
  • LocationSeattle

Posted 22 March 2014 - 04:01 AM

View Postawsmazinggenius, on 21 March 2014 - 04:58 PM, said:

Gravity, does this FS update still mean that we have to run ms.makeDir("/") first?
Lol, of course not. Its just that since we were working in the FS api, we didn't properly initialize it because of the state it is in.

And yes we are planning on a mobile version, though it would probably use an onscreen JavaScript based keyboard, because I can't grab key events with native keyboards.

#36 theoriginalbit

    Semi-Professional ComputerCrafter

  • Moderators
  • 7,332 posts
  • LocationAustralia

Posted 22 March 2014 - 04:08 AM

View Post1lann, on 22 March 2014 - 04:01 AM, said:

I can't grab key events with native keyboards.
really? why not?

#37 1lann

  • Members
  • 516 posts
  • LocationSeattle

Posted 22 March 2014 - 02:58 PM

View Posttheoriginalbit, on 22 March 2014 - 04:08 AM, said:

View Post1lann, on 22 March 2014 - 04:01 AM, said:

I can't grab key events with native keyboards.
really? why not?
Because it's just how software keyboards on mobile devices work... If you can find a way to do it then I'll be happy to use it :). The only option I can think of simulating mobile device keyboard input is through a dummy input field, which tracks the characters that have changed, and figure out what keys you have pressed.

#38 awsmazinggenius

  • Members
  • 930 posts
  • LocationCanada

Posted 22 March 2014 - 03:13 PM

What about that Apple Wireless Keyboard thing that I mentioned above? Of course, it always works on my laptop, but I get mixed results when using it on the iPad Air.

#39 1lann

  • Members
  • 516 posts
  • LocationSeattle

Posted 22 March 2014 - 03:53 PM

View Postawsmazinggenius, on 22 March 2014 - 03:13 PM, said:

What about that Apple Wireless Keyboard thing that I mentioned above? Of course, it always works on my laptop, but I get mixed results when using it on the iPad Air.
Well I don't have one to test with... so yeah... But if I do do the dummy input field method it should work with any device that is capable of inputting text into a field (That includes iPad Airs with a wireless keyboard).

Oh and I have updated http://gravlann.github.io which now runs CraftOS! Horray! Full FS API is not available yet, as you will notice some actions will cause it to crash. Also, there's not HTTP atm either.

Edited by 1lann, 22 March 2014 - 04:02 PM.


#40 oeed

    Oversimplifier

  • Members
  • 2,095 posts
  • LocationAuckland, New Zealand

Posted 22 March 2014 - 09:36 PM

View Post1lann, on 22 March 2014 - 03:53 PM, said:

View Postawsmazinggenius, on 22 March 2014 - 03:13 PM, said:

What about that Apple Wireless Keyboard thing that I mentioned above? Of course, it always works on my laptop, but I get mixed results when using it on the iPad Air.
Well I don't have one to test with... so yeah... But if I do do the dummy input field method it should work with any device that is capable of inputting text into a field (That includes iPad Airs with a wireless keyboard).

Oh and I have updated http://gravlann.github.io which now runs CraftOS! Horray! Full FS API is not available yet, as you will notice some actions will cause it to crash. Also, there's not HTTP atm either.

Yay! I like the new layout by the way, nice and clean.





1 user(s) are reading this topic

0 members, 1 guests, 0 anonymous users