Sorry your browser is not supported!

You are using an outdated browser that does not support modern web technologies, in order to use this site please update to a new browser.

Browsers supported include Chrome, FireFox, Safari, Opera, Internet Explorer 10+ or Microsoft Edge.

AppGameKit Classic Chat / Retro - Level of detail pixel 'lighting' - [free code & shader]

Author
Message
baxslash
Valued Member
Bronze Codemaster
17
Years of Service
User Offline
Joined: 26th Dec 2006
Location: Duffield
Posted: 27th Mar 2015 14:36 Edited at: 27th Mar 2015 14:37
Hi all, I wanted to create (yes another) lighting system but pretty retro this time. It's based on level of detail, so the better lit each 'pixel' is a different image is used for that 'pixel' for that sprite. That may make no sense so I'll upload the demo then a few images.

DEMO

Using AppGameKit V2 Tier 1

Attachments

Login to view attachments
baxslash
Valued Member
Bronze Codemaster
17
Years of Service
User Offline
Joined: 26th Dec 2006
Location: Duffield
Posted: 27th Mar 2015 14:37 Edited at: 27th Mar 2015 14:42
Here you can see the 2 'lights' in the demo. Each tile (the full screen is made of a few dozen tiles each using the shader) has 4 levels of detail which become visible depending how close they are to each light:


This could easily be adapted or used as/is to create a cool retro game. I also made a pixelate shader that changed the colours of any game to the three colours shown here but this works better I think.

Using AppGameKit V2 Tier 1

Attachments

Login to view attachments
baxslash
Valued Member
Bronze Codemaster
17
Years of Service
User Offline
Joined: 26th Dec 2006
Location: Duffield
Posted: 27th Mar 2015 14:46 Edited at: 27th Mar 2015 14:47
Here are the four images used for each 'level of detail':


They are just from the internet and I hold no rights to them but somebody else probably does so don't use them without seeking the originator using your crystal ball.

Using AppGameKit V2 Tier 1

Attachments

Login to view attachments
SpecTre
Developer
21
Years of Service
User Offline
Joined: 24th Feb 2003
Location: UK
Posted: 27th Mar 2015 15:08
Nice work, you could see some nice C64 or Spectrum style games being made with this effect.

The Amiga and Amos were great!
Download my game - Paint Pot from Amazon and Google here - http://leap.my-free.website/
Van B
Moderator
21
Years of Service
User Offline
Joined: 8th Oct 2002
Location: Sunnyvale
Posted: 30th Mar 2015 14:23
Could make a really cool faux-GameBoy game with that!

I am the one who knocks...
baxslash
Valued Member
Bronze Codemaster
17
Years of Service
User Offline
Joined: 26th Dec 2006
Location: Duffield
Posted: 30th Mar 2015 18:55
That's the effect I was aiming for

Using AppGameKit V2 Tier 1

Login to post a reply

Server time is: 2024-04-18 16:10:39
Your offset time is: 2024-04-18 16:10:39