will construct3 be as strong as unity??

Discussion and feedback on Construct 2

Post » Sun Sep 27, 2015 2:16 pm

Most everything runs on a subset of C, even C2, even your phone.
Image ImageImage
B
168
S
50
G
163
Posts: 8,221
Reputation: 105,061

Post » Sun Sep 27, 2015 4:33 pm

@newt I think that's over-simplifying it though, because it's many layers of "a subset of C" when it comes to HTML5

JavaScript doesn't compile, so it is interpreted at runtime by the browser/JavaScript engine, which probably turns it into bytecode, which then is run by another interpreter at OS level (like .NET) which is running within the operating system made in C and compiled into assembly.

C++/C games skip a lot of those layers (and do have more dangers since you manually clean memory, but if you know what you're doing this is a performance increase over generic garbage collection). C# skips the first few layers that HTML5/JavaScript has, starting from the bytecode level.

Layers/encapsulation is a performance hit (no matter how tiny), this applies in software, network traffic, shipping, and more.

In a (possibly a bit over-) simplified way, this is how C2 and CC games layer:

Image
"Construct 4 lets YOU make advanced games! (but not play them)" Construct Classic - Examples Kit
B
113
S
39
G
17
Posts: 2,184
Reputation: 19,217

Post » Sun Sep 27, 2015 4:43 pm

True, I guess "native" isn't that accurate.
Java is like immigrate with green card, and Javascript has a work visa.
Image ImageImage
B
168
S
50
G
163
Posts: 8,221
Reputation: 105,061

Post » Sun Sep 27, 2015 4:45 pm

Haha @newt I love that comparison :D
"Construct 4 lets YOU make advanced games! (but not play them)" Construct Classic - Examples Kit
B
113
S
39
G
17
Posts: 2,184
Reputation: 19,217

Post » Sun Sep 27, 2015 7:02 pm

newt wrote:Most everything runs on a subset of C, even C2, even your phone.

ohhh no kidding !!! let me tell you a secret , every computer runs on 0 and 1 !!!!! :o
B
16
S
6
Posts: 243
Reputation: 1,755

Post » Mon Sep 28, 2015 1:24 pm

Jayjay wrote:JavaScript doesn't compile, so it is interpreted at runtime by the browser/JavaScript engine

Most modern Javascript engines use just-in-time (JIT) compilation to machine code. They use a flow something like script -> bytecode -> profiling -> machine code generation. This means well-written Javascript gets "truly" compiled and can reach pretty impressive levels of performance.
Scirra Founder
B
387
S
230
G
87
Posts: 24,248
Reputation: 192,238

Post » Mon Sep 28, 2015 3:00 pm

Ashley wrote:
Jayjay wrote:JavaScript doesn't compile, so it is interpreted at runtime by the browser/JavaScript engine

Most modern Javascript engines use just-in-time (JIT) compilation to machine code. They use a flow something like script -> bytecode -> profiling -> machine code generation. This means well-written Javascript gets "truly" compiled and can reach pretty impressive levels of performance.


I think that only occurs in the context of C2, on iOS8+ WKVWebview, right?

Nitro-JIT engine.

I notice it performs very close to Chrome on PC, ie, similar cpu usage for my test games, which is rather insane when you think about how powerful an Intel i5 or i7 is compared to what's on an iPad Mini 2.
B
70
S
24
G
19
Posts: 1,757
Reputation: 17,614

Post » Mon Sep 28, 2015 6:29 pm

Silverforce wrote:I think that only occurs in the context of C2, on iOS8+ WKVWebview, right?

I'm pretty sure all modern web browsers do jit. Chrone, Firefox and Safari each are continually making js faster, and jit is always utilized in some way.
B
91
S
31
G
102
Posts: 5,234
Reputation: 67,254

Post » Tue Sep 29, 2015 6:57 am

R0J0hound wrote:
Silverforce wrote:I think that only occurs in the context of C2, on iOS8+ WKVWebview, right?

I'm pretty sure all modern web browsers do jit. Chrone, Firefox and Safari each are continually making js faster, and jit is always utilized in some way.


Okay, but Apple's implementation is so much faster. It's worlds apart to compare WKVWebview Safari vs Android Chrome for example.
B
70
S
24
G
19
Posts: 1,757
Reputation: 17,614

Post » Tue Sep 29, 2015 5:10 pm

@Silverforce if it is the reason why safari is faster, as there can be a lot of things that can be slow from the browser side even before or after the compilation.

Also safari I think runs only on iphones, which are defined, with hardwares fully known by the browser vendor, which is also the OS vendor, far less compatibility issues have to be worked around, and since compatibility is always put before execution speed, there may or may not be things that are not as fast as they could on android browsers' side just to make sure it works correctly.
Game design is all about decomposing the core of your game so it becomes simple instructions.
B
52
S
22
G
18
Posts: 2,122
Reputation: 17,093

PreviousNext

Return to Construct 2 General

Who is online

Users browsing this forum: Hiran Rodrigues and 3 guests