Aug 7 2015, 2:52 pm
|
|
Kaiochao, tell us. I think, it's something with image or blend mode.
|
In response to Kaiochao
|
|
I'm taking a shot in the dark that you're using images for the shadows and modifying blend_mode to achieve it.
Am I close? edit: ninja'd |
Hints: the shadow is a simple overlay, no blend_mode, and its color is "black" (no alpha).
|
The shadow doesn't exist. It's just an illusion that the master kaichao the great God illusionist has pulled
All hail kaichao |
In response to Kaiochao
|
|
Kaiochao wrote:
Hints: the shadow is a simple overlay, no blend_mode, and its color is "black" (no alpha).Matrix skewing (for the slanted shadow effect anyway) |
Can we post games that we are making but NOT using BYOND for? If so, I have something I'd like to share :)
|
In response to Kaiochao
|
|
I don't know if it is how you did it but...
You can add an alpha layer over your ground turfs that is a layer above your shadow layer. All your shadows would be the same color and not use alpha, because there is no alpha involved in the shadows.. there is no blending and you get the look you showed. Objects you want to be above the shadows would be on higher layers. That's one way. EDIT:I explained this weird... LOL |
In response to Akto
|
|
Akto wrote:
I don't know if it is how you did it but... Omgyaasss. I know what I'm working on tonight. (: |
I've been dabbling in HTML/CSS/JavaScript lately and came up with this:
http://i.imgur.com/dN5S0AT.gifv It's basically a Quest Log that shows your In-Progress, Completed, and Failed quests. Quests have a name, description, and reward(s). The quest lists can update seamlessly with JavaScript and can be expanded and collapsed. |
By the way, the shadows work on an idea that D4RK3 54B3R (or was it DarkCampainger? I always mix them up) told me months ago. Basically, turfs are transparent, shadows are solid black underneath turfs, and beneath shadows is a layer of solid gray.
And yes, Goober, they use matrix shear. I'm pretty sure it makes more sense than rotation alone in a 4:3 perspective. At least shrink it in the y-axis. |
If you're up for a more elaborate lighting system, like what I use here:
None of this works in the webclient as of now unfortunately... Turfs are all on BLEND_MULTIPLY. Ambient lighting is a flat rectangle that is drawn across the screen with a uniform color at the lowest layer. For me, this layer is 0.1. Next, shadows are just placed on layer 0.2. Then, local light sources that are intended to cancel out shadows, like the campfire here, are placed on layer 0.3. For all objects with a perceived height, like trees or people, I just update their atom.color whenever they move or whenever any lightsource that affects them has a changed parameter. This is akin to how Darkcampainger's demo works. |
Forum_accounts lighting library has a shadow example, but it is only shadows for mobs based on light sources. Not shadows for trees or players themselves. Maybe it could spark an idea.
This one does work in the webclient. Suppose I should post my project as well (showing off Kaiochao's zoom library @ about half way, freshly added to Pondera and Forum_accounts lighting/shade library (not completely dark yet, this was an evening shot)): |
While the intuitively-overlapping shadows are really, really neat - it unfortunately seems like an impractical hack. I wish there were just a blend_mode setting for it.
|
Here's the start of a project I'm working on. And here's an old video to get some discussion rolling. |
We're doing lighting?
This was something I experimented with for about 6 hours while talking to Yut Put about weird ways of handling lighting. This was about 3 months ago now. I had an interesting idea for handling lighting with a 4-color palette and decided to chase it down. I started with a 12-color black and white palette. Then I created lighting profiles using our four colors: Then I passed it through a bit of code that would generate lighting variations for each individual icon state in the file. #ifdef DEBUG The result looks something like this: Then I wrote a bit of code that managed lighting at the turf level: atom Profiling results: That's about 30 million lighting updates over about 8 minutes. It generates a ton of network communication if you do it rapid-fire like my test. CPU utilization was about 28% through the entire test, and updates per frame was around 1500 tiles. Basically, I can do batch lighting transitions with around 5K tiles per frame at 40fps on my machine before CPU starts to become problematic. That puts me around a maximum number of tiles updated per second at 200,000, so a full 1000x1000 map would take me about 5 seconds to fully process if you needed to update the lighting of every tile. This was a pretty simplistic approach, and optimization is needed before multiplayer fielding would be viable. |
In response to Ter13
|
|
This is pretty much how half of my old lighting system worked. World initialization would pregenerate icons for everything under different lighting conditions.
I found that this didn't work so great in multiplayer, mostly because anything tile-based has too many updates to send to the client if there are certain lighting effects, like flickering or moving lights. |
This is pretty much how half of my old lighting system worked. World initialization would pregenerate icons for everything under different lighting conditions. I pre-generate prior to compilation. I found that this didn't work so great in multiplayer, mostly because anything tile-based has too many updates to send to the client if there are certain lighting effects, like flickering or moving lights. Lummox changed the turf update messages. It used to be that a change to a turf would refresh the entire viewport. Now, that's not the case unless a significant number of turfs in the viewport of the client have been changed. This works mighty fine in multiplayer. I've tested it. In my case, I'm not actually recalculating updates based on the client's position. I'm only recalculating lights that actually move or change luminosity on demand. So as long as you keep your moving lights very small, and avoid lighting flicker, it handles in multiplayer just fine. |
In response to Ter13
|
|
Ter13 wrote:
I found that this didn't work so great in multiplayer, mostly because anything tile-based has too many updates to send to the client if there are certain lighting effects, like flickering or moving lights. That's unfortunate. My system could only either use /area to display shading/lighting, or turf overlays. Recalculating updates in my system only happens upon movement or change in brightness or change in radius. For dynamic shadows, opaque objects' movement would also cause light sources to recompute lighting. |