
OpenLara – Web-based classic Tomb Raider engine remake - ptrptr
http://xproger.info/projects/OpenLara/
======
robmccoll
In case anyone is curious, this appears to be an Emscripten-compiled C++
project. The remake and engine itself isn't necessarily 'web-based'.

~~~
flohofwoe
...and for this it is really small, really nice! The asm.js blob is just a 180
KByte download, including the WebGL and WebAudio wrapper (and it looks like an
ogg-vorbis and/or mp3 software decoder is also included, although I don't know
which one is used in the emscripten build).

~~~
robmccoll
Appears to be ogg if not Emscripten based on the sndName in game::init()
[https://github.com/XProger/OpenLara/blob/master/src/game.h](https://github.com/XProger/OpenLara/blob/master/src/game.h)

Yeah Emscripten and projects like this are pretty impressive

Edit: I apparently can't read

------
floatboth
Wow, the demo is just published with a level from the original game with the
original assets… If OpenMW did a directly playable web version with the
original world, Bethesda would not like that :D

~~~
bitwize
Yeah, they're going to be hearing from Square Enix's lawyers.

------
asvitkine
Super impressive!

I played a good chunk of the demo level and only noticed a few glitches (e.g.
bear getting stuck in the wall, some non-optimal camera movement - but maybe
that matches the original?).

One error that I hit a good way through the level (in the room with the
disconnected stairs and pool in the middle) is a JS stack overflow:

exceeded,RangeError: Maximum call stack size exceeded at Bi
([http://xproger.info/projects/OpenLara/OpenLara.js:5:113674](http://xproger.info/projects/OpenLara/OpenLara.js:5:113674))
at Bi
([http://xproger.info/projects/OpenLara/OpenLara.js:5:118632](http://xproger.info/projects/OpenLara/OpenLara.js:5:118632))
at Bi
([http://xproger.info/projects/OpenLara/OpenLara.js:5:118632](http://xproger.info/projects/OpenLara/OpenLara.js:5:118632))
at Bi
([http://xproger.info/projects/OpenLara/OpenLara.js:5:118632](http://xproger.info/projects/OpenLara/OpenLara.js:5:118632))
at Bi
([http://xproger.info/projects/OpenLara/OpenLara.js:5:118632](http://xproger.info/projects/OpenLara/OpenLara.js:5:118632))
at Bi
([http://xproger.info/projects/OpenLara/OpenLara.js:5:118632](http://xproger.info/projects/OpenLara/OpenLara.js:5:118632))
at Bi
([http://xproger.info/projects/OpenLara/OpenLara.js:5:118632](http://xproger.info/projects/OpenLara/OpenLara.js:5:118632))
at Bi
([http://xproger.info/projects/OpenLara/OpenLara.js:5:118632](http://xproger.info/projects/OpenLara/OpenLara.js:5:118632))
at Bi
([http://xproger.info/projects/OpenLara/OpenLara.js:5:118632](http://xproger.info/projects/OpenLara/OpenLara.js:5:118632))
at Bi
([http://xproger.info/projects/OpenLara/OpenLara.js:5:118632](http://xproger.info/projects/OpenLara/OpenLara.js:5:118632))

------
seibelj
Must add the roll button! That was key during battles for me back on the
playstation.

~~~
rzzzt
Shooting while moving forward is a bit cumbersome as well.

------
BonoboBoner
Instantly had me hooked again. The game does not move on after the city of
vilcabamba, though :-/

~~~
JorgeGT
They usually sell it for 1.5€ or so in Steam! At first I was afraid of
advancing because I remembered the wolves x)

~~~
icebraining
GOG sells a pack of the first 3 for $2.49, DRM-free.

------
afro88
WebGL noob question - why is this silky smooth on Safari on my MacbookPro but
Mine 3D [0] (and to be fair basically any other Web GL) is noticably low fps?

I understand Chrome has better support, and I'm in the habit of launching
Chrome to check out Web GL stuff. But I absent mindedly followed this link on
Safari and was pleasantly surprised.

[0] [http://egraether.com/mine3d/](http://egraether.com/mine3d/)

~~~
wodenokoto
Because this is asm.js

It is a sub-set of javascript that you can roughly think of as javascript-
bytecode and this can be heavily optimised in the browser compared to full
javascript.

[http://asmjs.org/faq.html](http://asmjs.org/faq.html)

------
letalvoj
Bats just followed me under water... Also I am unable to shoot them as long as
they are attacking me. Is it a OpenLara bug or feature from the original game?

~~~
bshimmin
Bug.

This is an incredible achievement though and just the sort of thing I love to
see here on a Sunday!

------
emilioolivares
Wow, I played this game when I was a kid. Can't believe it's just running
inside the browser. Great job.

------
jhoutromundo
Ho my...Tomb Raider is my favorite game since I played Tomb Raider 2. I've got
extremely excited about this project! Nice 60FPS, nice movements (although the
controls are completely different from the TR1-5 games)!

I'll try to help this guys somehow.

------
eriknstr
Oh man this is positively insane! The original Tomb Raider games are probably
my all time favorite video games. I recently revisited Tomb Raider for
PlayStation in an emulator on my laptop. I find it a bit mind-blowing that
OpenLara in the browser seems to be performing better than the native PSX
emulator did.

I think perhaps the ctrl-action button is more sensitive here than it was in
the original PC version? In order to get out of the water hole I had to swim
into the corner basically. It was a long while since I played the original on
PC though so who knows.

Mad respect.

~~~
thedudemabry
Wow. I remember playing the original almost 20 years ago on a PC that really
didn't support it at a terrible framerate. The fact that I can play it now in
a browser window on a netbook without it breaking a sweat is astonishing.

------
bobajeff
This work pretty well on my phone. Like the touch controls almost make it
convenient to play without a gamepad.

They just need to fix the issue of the browser highjacking touch inputs and
add fullscreen support.

~~~
coding123
Same here can't believe we reached a point where the phone can play these..

~~~
thirdsun
In a browser, no less.

------
futun
Very nicely done. Congrats.

Always thought the TR games were pretty awful, personally. Those were the days
when they were still trying to get 3rd person 'right'. But the implementation
here is solid.

~~~
NTripleOne
They were great games hampered by some pretty abysmal controls, dual analogue
wasn't exactly commonplace at the time (hell, the dual analogue controller was
released the year after TR1 came out) so there was only so much you could do
with just a d-pad. The controls got noticeably more tolerable as the series
went on but even then it was the same tank controls full of animation lock-in
(sidestepping being the main one).

------
Kenji
Rock solid 60fps, works out of the box on Chrome. I am impressed.

EDIT: To swim forward under water, press space!

EDIT2: Somehow, there's a bug with climbing out of the water, making her climb
up on the edge, then places her like half a meter forward and she plays the
climb animation again (clipping into the ground), then places her half a meter
forward, etc, until she is stuck in the wall.

~~~
hammerandtongs
Why don't you make an issue?

[https://github.com/XProger/OpenLara/issues](https://github.com/XProger/OpenLara/issues)

------
shmerl
Very good. Looks like it's using OpenTomb?

~~~
eriknstr
It says that it's inspired by OpenTomb. From a cursory glance it does not seem
to me that it's using OpenTomb.

------
pinum
Nice! But if you're keeping the original PC controls, why swap alt/space? It's
severely messing with my muscle memory.

Edit: Also a wolf followed me underwater and ran around normally. And I seem
to have unlimited underwater time. Is there a tracker for how complete the
project is/a roadmap? Either way, awesome stuff!

~~~
gregmac
Space to jump seems quite normal to me, but what didn't was that A/D turned
instead of side-stepped. I remember playing Tomb Raider when it came out, but
I don't remember it doing that. I actually find it nearly impossible to move
around with those controls, and I had the same problem with web ports of
Wolfenstein.

This port doesn't have configurable controls, but with Wolfenstein you can't
even configure it to do strafe without a modifier key.

It seems like at some point all these 1st/3rd person games switched to
strafing by default, and using the mouse to look/turn/aim. Anyone know when
that happened? What game first allowed that configuration and what first used
it by default?

~~~
ChickeNES
It was popular in competitive Quake play, was included as an option in Quake
II and the original Half-Life was the first game to ship with the standard
WASD + mouse scheme that every game uses today.

Here's a more in-depth article on the history of WASD:
[http://www.pcgamer.com/how-wasd-became-the-standard-pc-
contr...](http://www.pcgamer.com/how-wasd-became-the-standard-pc-control-
scheme/)

------
kstenerud
Hmm... doesn't work on Chrome.

Uncaught TypeError: Cannot read property 'getSupportedExtensions' of undefined

~~~
moron4hire
Worked in chrome on my phone

------
chj
Barely runnable on Firefox on Raspberry Pi but it's already incredible.

~~~
corysama
Runs great on an iPhone 6+.

~~~
andybak
I love the fact that we're even considering running stuff like this on such
hardware _inside a web browser_.

------
demarq
Plays smooth like a totally native game on my old android!!

------
pheuberger
Man this is really sweet. Takes me back all those years.

------
JabavuAdams
What's with the orbiting cam? That's a really big no-no, especially since it's
colliding with the environment.

Cool effort, overall.

~~~
beaconstudios
it's part of the original game.

~~~
JabavuAdams
Wow, I don't remember that.

