Welcome, Guest. Please login or register.

Login with username, password and session length

 
Advanced search

1411432 Posts in 69363 Topics- by 58417 Members - Latest Member: gigig987

April 20, 2024, 05:15:20 AM

Need hosting? Check out Digital Ocean
(more details in this thread)
TIGSource ForumsCommunityDevLogsMoonQuest
Pages: 1 ... 41 42 [43] 44 45 ... 189
Print
Author Topic: MoonQuest  (Read 1320162 times)
jmcmorris
Level 1
*



View Profile WWW
« Reply #840 on: July 17, 2012, 03:01:43 PM »

Lighting is tricky. I remember reading your analysis on Terraria's lighting. They too had some problems with certain situations. I think what sergiocornaga suggested with the diagonal shadows might help out some.

Yet another similarity in our projects. I too have not considered much about sound. I am just now starting to. I'm sure you'll do a good job with it once you do put the time in.
Logged

eigenbom
Level 10
*****


@eigenbom


View Profile WWW
« Reply #841 on: July 17, 2012, 03:09:07 PM »

Yeh, I started implementing diagonal shadows but adding slopes doesn't fix all the situations, and so you have a mix of blocky and slopey artifacts. Still I'll take a closer look at some time, but for now the basics of lighting are in and today I'll just be experimenting with some other light-related stuff.
Logged

eyeliner
Level 10
*****


I'm afraid of americans...


View Profile
« Reply #842 on: July 17, 2012, 03:44:05 PM »

@eyeliner You mean the birds and the bees? Actually I really look forward to bringing the world alive with sound, but haven't really thought about sound yet.
Exactly right. Carry on brave soldier!
Logged

Yeah.
eigenbom
Level 10
*****


@eigenbom


View Profile WWW
« Reply #843 on: July 17, 2012, 10:51:31 PM »

Update: Hey tiggywiggies, the lighting now is computed on demand (when a subchunk becomes visible) and updates in real-time. I made video! Ignore all the bugs Shocked

Blocks can register whether they are transparent (like the platform or leaf block), opaque, or whether they emit light, like these gnarly skulls..



In the debug build you can also show the light flow with some nifty arrows ...



And here's the lighting in a typical scene..



So yeh, after all that work, I think it's not too bad. It's not totally awesome, but for now, it works well enough that I can move onto the next thing on my list. :D
Logged

happymonster
Level 10
*****



View Profile WWW
« Reply #844 on: July 17, 2012, 11:01:19 PM »

Looking nice.. I think you could do with more foreground shades, in the same way you have for the background tiles. Smiley
Logged
rek
Level 7
**


View Profile
« Reply #845 on: July 18, 2012, 06:53:22 AM »

Looks great! The only thing I found odd is that MM doesn't emit any light himself, so he can be in total darkness (even when holding a skull in his hand).
Logged
mokesmoe
Level 10
*****



View Profile WWW
« Reply #846 on: July 19, 2012, 04:00:40 AM »

Why would moonman be bioluminescent?

Also Terraria works the same way, so it's not that odd.
Logged
rek
Level 7
**


View Profile
« Reply #847 on: July 19, 2012, 06:47:50 AM »

Why would moonman be bioluminescent?

Because he's the moonman.

Also because I think knowing where your player character is is pretty fundamental.
Logged
jmcmorris
Level 1
*



View Profile WWW
« Reply #848 on: July 19, 2012, 07:25:51 AM »

Not being able to see your character and being dependent on a light source was one of the things I liked most about Terraria. It really gave a sense of exploration and mystery. Also when you're weaker it can be a little scary.
Logged

Cyral
Level 0
**

@Cyral33


View Profile WWW
« Reply #849 on: July 19, 2012, 09:37:06 AM »

Update: Here's my first test with lighting. The first image shows the terrain (red for solid block, grey for background block/wall, and white for open), the second shows the lighting computed on it. This algorithm models a boundary spreading out from the lit areas, decreasing with each step. Roughly..

Code:
uint8 light[w*h] stores the light values
initialise all open tiles as FULLY_LIT, and non-open ones as NULL
store all tiles adjacent to the fully lit ones in a set<index> boundary
while(boundary is not empty){
  newboundary = {}
  foreach(adjacent tile, t, to boundary){
    if (light[t]==NULL){
      set attenuation=10 if t is a wall, or 40 if its a block
      light[t] = min(light of all adjacent tiles) - attenuation
      newboundary += t
    }  
  }
  boundary = newboundary
}
// done!



The results are promising, but there's some major issues:
- in the cave at the top right we see a horizontal band of light, seeping through the thin wall ... this looks wrong (but is definitely in accordance with the algorithm)
- in the caves at the bottom, the light falls down from the holes, but doesn't bleed outwards into the surrounding caves (maybe a second pass of the algorithm would fix this?)
- the light at the cave entrance near the center is all wrong

Anyways, back to the drawing board..

Edit: Changing the min to a max gives the light a little more freedom ...


Hello, I really like how this game looks, I'm making a game that is quite similar too this. Ive experimented with lighting alot (Pixelshaders, bluring values, etc) but nothing seems to work well for my game. Your game looks exactly how I was trying to make it. Would you be willing to elaborate a little more on how you did it?
Logged


C# Developer and Graphics Designer
eigenbom
Level 10
*****


@eigenbom


View Profile WWW
« Reply #850 on: July 19, 2012, 02:47:45 PM »

I think mm will be bioluminescent, but the reach of his luminescence will be very short (and done with a simple mask which adds to the current lighting layer). That way you can always see your character and his state, but still be fumbling in the dark if you forget to bring a torch or Mk 5 MoonLantern.

@Cyral The final lighting is fundamentally what I described way back in that quoted post. The main work on it has been making it run in parallel on 16x16 block size "subchunks", mapping the light values to rendered light values, using multiple passes of light, etc. If you tackle this problem, you should start a thread with your progress and I might pop by and suggest some things / steal your ideas. Wink

Logged

Thecoolestnerdguy
Level 2
**

while(!succeed) try();


View Profile
« Reply #851 on: July 20, 2012, 07:00:22 AM »

Musics are on your to do list?  Beg
If yes, you plan they random, like in Minecraft, or there will be a specific music for specific moment?

I think mm will be bioluminescent

There will be neons inside him? (ok, that's not BIOluminescence).
That would be funny.
Or he will be like a firefly?
If he will be like a firefly, you should need to eat luciferase and luciferin to light your way? Facepalm (how idiot my gameplay mechanic ideas can be?).
But maybe that could be a cool game mechanic, to fuel your light you need to eat some luciferase.
Logged

Sad minecraft didnt copyright squares
jmcmorris
Level 1
*



View Profile WWW
« Reply #852 on: July 20, 2012, 01:57:59 PM »

I'm curious about what you plan to do for the music as well. Do you have an artist already lined up? Smiley
Logged

eigenbom
Level 10
*****


@eigenbom


View Profile WWW
« Reply #853 on: July 20, 2012, 03:45:03 PM »

Great idea @thecoolestnerdguy, I like the idea of having to consume something to power your internal light. Smiley

As for music, yep, it will be random short ambient segments like Minecraft. I've been talking with a musician for a few months now, but music really won't make it in for a couple more months. I've also got an idea to sync the musical events with visual events, e.g., a jumping rabbit might jump to the "beat" of the music. I'd really like to do something subtle along those lines, but I guess it just comes down to whether I have the time. :D
Logged

Thecoolestnerdguy
Level 2
**

while(!succeed) try();


View Profile
« Reply #854 on: July 22, 2012, 02:34:40 AM »

I've also got an idea to sync the musical events with visual events, e.g., a jumping rabbit might jump to the "beat" of the music.

Exploring around in MM... Found some rabbits... suddenly ACHIVEMENT UNLOCKED find more than 10 rabbits togheter ... And the rabbits start to jump around in the rythm of the beat...
« Last Edit: July 22, 2012, 06:39:18 AM by thecoolestnerdguy » Logged

Sad minecraft didnt copyright squares
happymonster
Level 10
*****



View Profile WWW
« Reply #855 on: July 22, 2012, 03:19:40 AM »

And then the rabbits grow fangs and try to savage you..

 Shocked
Logged
Thecoolestnerdguy
Level 2
**

while(!succeed) try();


View Profile
« Reply #856 on: July 22, 2012, 09:06:30 AM »

And then you equip your ak-47, switch to architect mode, quickly build a barricade and... (Your turn @happymonster) Wink
Logged

Sad minecraft didnt copyright squares
eigenbom
Level 10
*****


@eigenbom


View Profile WWW
« Reply #857 on: July 22, 2012, 03:23:57 PM »

Exploring around in MM... Found some rabbits... suddenly ACHIVEMENT UNLOCKED find more than 10 rabbits togheter ... And the rabbits start to jump around in the rythm of the beat...

This sounds like the best game ever conceived! My Word!
Logged

Thecoolestnerdguy
Level 2
**

while(!succeed) try();


View Profile
« Reply #858 on: July 22, 2012, 05:23:33 PM »

Exploring around in MM... Found some rabbits... suddenly ACHIVEMENT UNLOCKED find more than 10 rabbits togheter ... And the rabbits start to jump around in the rythm of the beat...

This sounds like the best game ever conceived! My Word!

Yes, if you do like rabbits. I prefer:

Exploring around in MM... Found some moonpuppies... suddenly ACHIVEMENT UNLOCKED find more than 10 moonpuppies togheter ... And the moonpuppies start to jump around in the rythm of the beat...
Logged

Sad minecraft didnt copyright squares
Thecoolestnerdguy
Level 2
**

while(!succeed) try();


View Profile
« Reply #859 on: July 24, 2012, 02:29:42 PM »

Ha ha, I realized today that I was  Hand Any Key constantly refreshing this page to see if someone posted a new reply.
Indie game developers community, you gonna destroy my productivity.  Mock Anger
Logged

Sad minecraft didnt copyright squares
Pages: 1 ... 41 42 [43] 44 45 ... 189
Print
Jump to:  

Theme orange-lt created by panic