What language is the ES collision engine written in?
Moderator: Coders of Rage
-
- Chaos Rift Newbie
- Posts: 4
- Joined: Sun Feb 21, 2010 5:52 pm
What language is the ES collision engine written in?
What language was the Elysian Shadows collision engine written in? I know that many different languages are used in ES, but what was the collision engine made from?
- Lord Pingas
- Chaos Rift Regular
- Posts: 178
- Joined: Thu Dec 31, 2009 9:33 am
- Favorite Gaming Platforms: NES, SNES, Nintendo 64, Dreamcast, Wii
- Programming Language of Choice: C++
- Location: Hiding In My Mum's Basement With My Pokemon Cards
Re: What language is the ES collision engine written in?
I'm pretty sure that most of the engine is written in C++ and a lot of it is written in lua.
Collision detection most likely written in C++.
Collision detection most likely written in C++.
-
- Chaos Rift Junior
- Posts: 345
- Joined: Tue Jan 12, 2010 7:23 pm
- Favorite Gaming Platforms: PC - Windows 7
- Programming Language of Choice: c++;haxe
- Contact:
Re: What language is the ES collision engine written in?
While gyro can confirm it, LUA is hellish slow. I highly doubt that he'd write assembler for 3 different platforms, though it wouldnt surprise me. That is assuming you can even write assembler on DC/PSP. So that leaves c++. Lua would ask c++ to do collision checking with some kind of function. The core checking though would be done in pure c++ - lua is just too slow. c++ is more then fast enough for anything ES team can throw out when optimised for said platform.
Re: What language is the ES collision engine written in?
^
actually, depending on how many rigid bodies are simulated lua SHOULD be plenty fast enough to do something like that.
writing the entire collision in asm would be so marginally benificial most likely that it be better to write the core in C, and helper functions in asm. for the most part compilers are smart enough to make very good asm. i think he using bresenham in some of his calcs, and that would be a prime candidate to make in asm, its ver simple short, and there are plently little things you can do to make it faster.
actually, depending on how many rigid bodies are simulated lua SHOULD be plenty fast enough to do something like that.
writing the entire collision in asm would be so marginally benificial most likely that it be better to write the core in C, and helper functions in asm. for the most part compilers are smart enough to make very good asm. i think he using bresenham in some of his calcs, and that would be a prime candidate to make in asm, its ver simple short, and there are plently little things you can do to make it faster.
Some person, "I have a black belt in karate"
Dad, "Yea well I have a fan belt in street fighting"
Dad, "Yea well I have a fan belt in street fighting"
- Trask
- ES Beta Backer
- Posts: 738
- Joined: Wed Oct 29, 2008 8:17 pm
- Current Project: Building a 2D Engine
- Favorite Gaming Platforms: Sega Genesis and Xbox 360
- Programming Language of Choice: C/C++
- Location: Pittsburgh, PA
- Contact:
Re: What language is the ES collision engine written in?
avansc wrote:^
actually, depending on how many rigid bodies are simulated lua SHOULD be plenty fast enough to do something like that.
writing the entire collision in asm would be so marginally benificial most likely that it be better to write the core in C, and helper functions in asm. for the most part compilers are smart enough to make very good asm. i think he using bresenham in some of his calcs, and that would be a prime candidate to make in asm, its ver simple short, and there are plently little things you can do to make it faster.
Ow... Avansc's posts are too smart for me to read first thing in the morning.... UGH.
I do believe that everything related to that actual game engine is NOT written in lua in ES, I believe lua is simply calling functions from the engine, so the collision itself is still in the engine. Probably in C++ as I know Gyro wanted to optimize everything using C++, but as avansc said, there are benefits with writing it in pure C.
Dear god, they actually ported ES to a piece of celery!MarauderIIC wrote:You know those people that are like "CHECK IT OUT I just made Linux run on this piece of celery [or other random object]!!"? Yeah, that's Falco, but with ES.
Martin Golding wrote: "Always code as if the guy who ends up maintaining your code will be a violent psychopath who knows where you live."
- hurstshifter
- ES Beta Backer
- Posts: 713
- Joined: Mon Jun 08, 2009 8:33 pm
- Favorite Gaming Platforms: SNES
- Programming Language of Choice: C/++
- Location: Boston, MA
- Contact:
Re: What language is the ES collision engine written in?
I'm fairly certain that the entire engine is written in C/++ while the game content is accomplished via Lua. So, the answer to your question will be C/++. I'll wait for an official response from Falco though.Zunedude123 wrote:I know that many different languages are used in ES
"Time is an illusion. Lunchtime, doubly so."
http://www.thenerdnight.com
http://www.thenerdnight.com
- Falco Girgis
- Elysian Shadows Team
- Posts: 10294
- Joined: Thu May 20, 2004 2:04 pm
- Current Project: Elysian Shadows
- Favorite Gaming Platforms: Dreamcast, SNES, NES
- Programming Language of Choice: C/++
- Location: Studio Vorbis, AL
- Contact:
Re: What language is the ES collision engine written in?
Absolutely not. An interpreted language running on a 200mhz SH4 and 330mhz PSP? No.avansc wrote:^
actually, depending on how many rigid bodies are simulated lua SHOULD be plenty fast enough to do something like that.
At the moment, it's pretty ugly/optimized C. Lots of helper functions (as avansc said) are going to wind up being assembly on certain platforms. Collision in ES (well, Rigid Body collision) is NOT cheap at all. Not only does every entity have to be checked against every entity (until we get broad-phase implemented later), but lots of these entities are not axis aligned, and have to get thrown into the separating axis collision algorithm, then have their points of contact calculated, THEN have the physics engine calculate resolution values to be applied to each body.
Ontop of that, we're going to be doing some freaky shit to check Rigid Bodies against tile collisions. It's going to be relying heavily on Bresenham raycasting to determine potentially colliding tiles to be sent to the collision detector.
Re: What language is the ES collision engine written in?
yeah in that case no, but i was thinking more along the lines of a PC, i keep forgetting this is actually a DC project at heart.GyroVorbis wrote:Absolutely not. An interpreted language running on a 200mhz SH4 and 330mhz PSP? No.avansc wrote:^
actually, depending on how many rigid bodies are simulated lua SHOULD be plenty fast enough to do something like that.
At the moment, it's pretty ugly/optimized C. Lots of helper functions (as avansc said) are going to wind up being assembly on certain platforms.
Some person, "I have a black belt in karate"
Dad, "Yea well I have a fan belt in street fighting"
Dad, "Yea well I have a fan belt in street fighting"