Welcome, Guest. Please login or register.

Login with username, password and session length

 
Advanced search

1411430 Posts in 69363 Topics- by 58416 Members - Latest Member: JamesAGreen

April 20, 2024, 01:40:01 AM

Need hosting? Check out Digital Ocean
(more details in this thread)
TIGSource ForumsCommunityDevLogsDevader - swarms of enemies - made in HTML5
Pages: 1 ... 10 11 [12] 13 14 ... 22
Print
Author Topic: Devader - swarms of enemies - made in HTML5  (Read 52910 times)
marcgfx
Level 8
***


if you don't comment, who will?


View Profile WWW
« Reply #220 on: October 27, 2020, 01:09:03 AM »

Instead of making new stuff I've decided to improve what I have. So many of my experiments are "finished" but not really fleshed out to the max. No proper intro animation or death, just dropping into view and exploding with my default kill-animation (disintegrating shader + explosions on top).

I have not made gifs this time, as it really badly bogs down the page load time + the gifs are starting to get huge. Unfortunately tigsource still does not seem to allow me embedding videos from imgur, although this would greatly improve my experience and that of anyone dropping by. Some videos that are <1mb in good quality require 20mb as a gif, seems crazy not to fix this on tigsource.

So this is an animations of a very weird creature dropping in and getting destroyed:
https://i.imgur.com/dpR7er2.mp4

Death of a spider now no longer just has the legs disintegrate with the body, but they get to stay around and drop to the floor, "slowly" fade into the background and leave a mark.
https://i.imgur.com/DFBwi5Y.mp4

I've also increased the size of my main character by 40% in every direction, so something like 2.8 times the volume. There have been remarks now and then about everything being quite small and I just decided to try upscaling. Have not found a reason why this is not a good idea so far.


Then I decided to add some more animation frames, as I have stopped limiting myself as much with image resources.
https://i.imgur.com/htlXFd7.mp4
Logged

JobLeonard
Level 10
*****



View Profile
« Reply #221 on: October 27, 2020, 02:30:09 AM »

That or a video tag that can link MP4 directly, yeah :/

Looks sweeeet dude
Logged
marcgfx
Level 8
***


if you don't comment, who will?


View Profile WWW
« Reply #222 on: November 01, 2020, 12:20:52 AM »

Thanks JobLeonard!
Currently on vacation with no access to my code (probably better). Still could not stop coding entirely. There was a small storm here and I was impressed by the lightning visualisation on my phone. Still not sure if it was just a large amount of images or if it was generated. Nonetheless I wanted to try it myself.




The technique is pretty simple. I first created a function that renders lines between a list of points. Then I created a function that subdivides a list of points once, while slightly offsetting the new point. By repeating this function a few times a pretty decent lightning bolt is created. I then use my list of points renderer and paint the same line 3 times, first the darkest color, the actual color and white as the last layer.

I'm pretty sure I will include this technique into Devader when I get back.
Logged

JobLeonard
Level 10
*****



View Profile
« Reply #223 on: November 01, 2020, 12:24:08 AM »

So randomized fractals, basically? The result is really nice!

Would probably make for an interesting glitchy geometry shader..
Logged
marcgfx
Level 8
***


if you don't comment, who will?


View Profile WWW
« Reply #224 on: November 01, 2020, 11:26:49 AM »

Never even considered fractals... kind of I guess? I was just looking for a recursive solution, so that I can define the points I want the lightning to pass through Smiley
Logged

JobLeonard
Level 10
*****



View Profile
« Reply #225 on: November 01, 2020, 12:43:24 PM »

But fractals are nothing but recursion Wink
Logged
marcgfx
Level 8
***


if you don't comment, who will?


View Profile WWW
« Reply #226 on: November 01, 2020, 11:47:57 PM »

True Cheesy Calling it fractal lightning is way cooler!
Logged

JobLeonard
Level 10
*****



View Profile
« Reply #227 on: November 02, 2020, 02:42:51 AM »

BTW, to get back to your earlier question about embedding videos: you can also put webp in img tags. The only browser not supporting that is Safari. Check out this example from another devlog:

https://forums.tigsource.com/index.php?topic=70718.msg1431226;topicseen#new
Logged
marcgfx
Level 8
***


if you don't comment, who will?


View Profile WWW
« Reply #228 on: November 03, 2020, 08:11:29 AM »

Nice! It did not work on my ubuntu laptop but works on Windows. I like this very much. Finally something to replace gif!


Main disadvantage is I need to host it myself and as I use amazon S3 I have to manually set the mime type. Still great!
edit: It's not Ubuntu works in Chrome but not Firefox atm. Sorry to anyone who can't see the image.
« Last Edit: November 03, 2020, 08:17:08 AM by marcgfx » Logged

JobLeonard
Level 10
*****



View Profile
« Reply #229 on: November 03, 2020, 09:14:04 AM »

Works fine on my Firefox in an Ubuntu-based distro? Shrug
Logged
marcgfx
Level 8
***


if you don't comment, who will?


View Profile WWW
« Reply #230 on: November 04, 2020, 10:31:48 PM »

I had to update Ubuntu to update Firefox (I was still on 61), now it also works for me Well, hello there!
Thanks JobLeonard, now I just have to make new cool stuff! (and hope that imgur and twitter allow webp someday)
Logged

marcgfx
Level 8
***


if you don't comment, who will?


View Profile WWW
« Reply #231 on: November 06, 2020, 09:37:47 AM »


a bit distracted by the us elections, so I reworked the flame thrower
Logged

JobLeonard
Level 10
*****



View Profile
« Reply #232 on: November 07, 2020, 04:19:44 AM »

Inspired by all the "this is fine" posts from the beginning of the week? Wink
Logged
marcgfx
Level 8
***


if you don't comment, who will?


View Profile WWW
« Reply #233 on: November 07, 2020, 12:45:23 PM »

ha, I must have missed that! too late to the flames party I guess Cry

I've added the lightning I made on canvas from my holidays into the game. Was a bit more complicated than I would have liked, as I had to write my own line-renderer. On the screenshot you can see there are still some issues in between the segments. There are actually two problems. One is that overlapping polygons exist and the additive blending is making bright lines at the overlaps. Then there are these darker lines. I'm thinking they might be related to the image I'm using from the texture atlas, some kind of edge bleeding. It's never easy, is it?


edit: Added a smaller image that shows the Problems


In animation it looks fairly decent though. I'm using seeded random, as changing the lightning in every frame gets too hectic.


It did feel a bit "static" though... so I've added a touch of random to the seeded random, this keeps the overall form of the lightning but also makes it come alive.


The images might take a bit to load and seem slow until then.

« Last Edit: November 07, 2020, 01:01:17 PM by marcgfx » Logged

JobLeonard
Level 10
*****



View Profile
« Reply #234 on: November 08, 2020, 04:35:40 AM »

POWERRRRR!!!! UNLIMITED... POWERRRRRRRR!!!!  Hand Metal Left Evil Hand Metal Right
Logged
vdapps
Level 5
*****


Head against wall since 2013


View Profile WWW
« Reply #235 on: November 09, 2020, 08:52:33 AM »


a bit distracted by the us elections, so I reworked the flame thrower

Cool, that this runs in browser! Shocked
Logged

marcgfx
Level 8
***


if you don't comment, who will?


View Profile WWW
« Reply #236 on: November 09, 2020, 09:38:08 AM »

I think so too, but so far it has only been a big disadvantage. I have not found a good way to make use of this fact... In the end Unity also runs in the browser.
Logged

JobLeonard
Level 10
*****



View Profile
« Reply #237 on: November 09, 2020, 08:44:35 PM »

Well, you can just send a link to your game for any programming interview you'll do in the near future Cheesy

Squeezing that out of the browser from scratch is quite the accomplishment, I'd say
Logged
vdapps
Level 5
*****


Head against wall since 2013


View Profile WWW
« Reply #238 on: November 10, 2020, 03:12:02 AM »

Yep, Unity runs in browser but AFAIK it requires you to install some biig plugin, so in the end, computation is done natively in that plugin, there's no HTML magic.

I'm more awed by native HTML5/Javascript implementations, where you really need just browser.

I think so too, but so far it has only been a big disadvantage. I have not found a good way to make use of this fact... In the end Unity also runs in the browser.

Hmm, I can imagine, it's harder to get everything right due to different browsers, devices and their interpretations of HTML5 or support for various formats. Also I guess it's harder to monetize it (I can imagine only ads or subscription model (but for that, game must be massive with lot of active players, like some of browser MMORPG-s)).
Logged

marcgfx
Level 8
***


if you don't comment, who will?


View Profile WWW
« Reply #239 on: November 12, 2020, 01:17:51 AM »

You can export to webgl from Unity, no idea how good the result is compared to my native implementation.

I'm continuing to improve on older work. I've revisited the tower boss again. Mostly improving the visuals. The towers firing lasers now completely light up, making it more obvious to see which tower just fired.
« Last Edit: November 12, 2020, 03:07:24 AM by marcgfx » Logged

Pages: 1 ... 10 11 [12] 13 14 ... 22
Print
Jump to:  

Theme orange-lt created by panic