-
Posts
556 -
Joined
-
Last visited
Content Type
Blogs
Forums
Store
Gallery
Videos
Downloads
Everything posted by havenphillip
-
This is rad this is the kind of game I want to make.
-
I'm super pumped about this decision but I still think you should keep the subscription option. Buying the standalone one-time payment, then buying all the DLC separately should be the "hard way" to do things. A subscription that was like 75% of the cost in one year of what it would cost to buy the standalone plus all the DLC separately would appeal to a different kind of person (or whatever just so that subscription is the much better deal). I'll happily do things the "hard way" because that's just my own matrix of wants/needs but I think subscription could still work relative to the standalone option. It changes the payoffs. Instead of "paying rent" I'm "paying less so I don't have to pay more like those nerds over there." I don't know the industry but it seems like maybe the people you're selling the subscription to may be serious game developers who don't like the way Unreal essentially punishes people for being successful. I've seen your blog posts and all the work that went into it. I think your work speaks for itself, and Ultra does like 10X what Leadwerks 4 does and I bought Leadwerks for $100 like seven years ago. I'd gladly pay $150 - $200 for Ultra (I probably shouldn't say that but it's true. I mean some guy was willing to give you $700 for it).
-
https://media.giphy.com/media/dVTnzQa3xUlKo/giphy.gif
-
Best I can come up with is to find a simple ripple shader on Shadertoy and then get normals from that noise and plug it into a decal shader, then just use it like you would in your tire tread decal system. I made one and tried it on the FPS gun bullet decal material. It works ok. I left the diffuse output at 0 so only the normals show up. You can adjust the speed, zoom, frequency and centering on the ripple. I found one where the ripples fade out on the edges. Also that's how the decal material is set up I don't know how much that matters to the effect: decal ripple.zip
-
Yeah sorry man I don't know what's going on with that. If it works in game then I guess it's cool. That mud looks good. I wish I could figure out the footprint thing but it's still beyond me at this point.
-
I tried to reproduce it. I'm not getting the same outcome. It seems to be working correctly for me: When you zoom in and out on the object does it adjust itself? If it works correctly in-game then it might just be the material editor or have something to do with using the "player_pos". Otherwise sometimes I've noticed if I restart my computer it will fix some of these weird things. Does this work?: #version 400 #define MAX_INSTANCES 256 //Uniforms uniform instancematrices { mat4 matrix[MAX_INSTANCES];} entity; uniform mat4 projectioncameramatrix; uniform float currenttime; float time = currenttime/1000; uniform vec3 cameraposition; uniform vec3 player_pos; //Attributes in vec3 vertex_position; in vec2 vertex_texcoords0; in vec3 vertex_normal; in vec3 vertex_tangent; in vec3 vertex_binormal; //Outputs out vec4 ex_vertexposition; out vec2 ex_texcoords0; out vec3 ex_normal; out vec3 ex_tangent; out vec3 ex_binormal; void main() { //entity matrix mat4 entitymatrix = entity.matrix[gl_InstanceID]; mat4 entitymatrix_ = entitymatrix; entitymatrix_[0][3]=0.0; entitymatrix_[1][3]=0.0; entitymatrix_[2][3]=0.0; entitymatrix_[3][3]=1.0; //model position ex_vertexposition = entitymatrix_ * vec4(vertex_position,1.0); //Interactive vec3 direction = normalize(ex_vertexposition.xyz - player_pos); direction.y = -0.000; float radius = 2.0; float interact_power = 2.0; float dist = distance(player_pos,ex_vertexposition.xyz); float power = smoothstep(radius,0.0,dist*dist*0.3); direction = (vec4(direction,1.0) * entitymatrix_).xyz; ex_vertexposition.xyz += direction * power * 5.0 * interact_power * cos(5.0-ex_texcoords0.y)*cos(5.5-ex_texcoords0.x); gl_Position = projectioncameramatrix * ex_vertexposition; //normals mat3 nmat = mat3(entitymatrix_); ex_normal = normalize(nmat * vertex_normal); ex_tangent = normalize(nmat * vertex_tangent); ex_binormal = normalize(nmat * vertex_binormal); //texture coordinates ex_texcoords0 = vertex_texcoords0; }
-
You should be able to just erase these lines without any problem. It doesn't look like you're establishing anything here that you need to use later:
-
You got your process streamlined. Your levels seem to just pop up out of nowhere. I'd be interested in reading a tutorial.
-
That ice rock looks pretty cool. What other shaders should I attempt?
-
-
A shot in the dark but one thing you could try is multiplying the vertex_position * entitymatrix rather than the vertex_normal * entitymatrix;
-
Nice. I think with some tweaking here and there people can get the effect out of it that they want.
-
Here's a cool effect I don't know why I didn't think of this sooner. This shader uses parallax occlusion and a trick similar to that in the weeper (22a_weeper). The idea is that you can get a cheap refraction effect by multiplying the texture coordinates of the diffuse texture with the normals (naturally you'd have to establish the diffuse "outcolor" after you establish the normals). It looks something like this: float amplitude = 0.1; vec4 outcolor = texture(texture0,ex_texcoords0 + normal.xy * amplitude); That's pretty much the gist of it. What this does is it warps the diffuse texture coordinates by the normals. But adding the normals to the texture coordinates pushes the effect to one side so I took it a step further by subtracting the ex_normal from that and the difference creates a nice centered refraction effect against the diffuse texture. vec2 n1 = normal.xy * amplitude; vec2 n2 = ex_normal.xy * amplitude; vec4 outcolor = texture(texture0,ex_texcoords0 + n1 - n2); In the weeper shader I added time to the normal texcoords and that makes an effect like water dripping down a wall. Here I didn't need that because this is ice. It's stuck in place. Once I got that established I added parallax to the diffuse texture. I used texture4 in this shader for my "outcolor" because I reserved texture0 for the little scratch marks on the surface of the ice. vec4 refractcol = texture(texture4, parallaxed_texcoords.xy + n1 - n2); After this I finished the color by mixing the outcolor and the refractcol by a "lighten" blend mode I found on Github. If you look at the normals and the outcolor in the shader you'll notice I didn't use the parallaxed texcoords because I wanted the surface to remain where its at and give the impression that there is something sort of encasing the "ice" i.e., the surface of the object - what the light bounces off of. The whole "ice" effect happens under some surface, right? I also z-sorted the object, which gets rid of the shaded sides (like ice doesn't really have a shadowed side does it?) and because of that I lost the specular so I added a blinn-phong to replace it. Also I added a cubemap to simulate reflection. I think this would work great as a frozen lake or an iceberg. Maybe even as ice cubes. It doesn't take the screen into consideration like the creek refraction does so you still technically have an opaque object. It's also parallax which notoriously has trouble with curves. I've added a few tricks so that the parallax can work on gentle slopes. You can adjust the texture sizes, the light, the cubemap fresnel, the parallax depth, the refraction amount, and the ice "contrast." If you put it on your own model you'll have to adjust the texture sizes and stuff but it's set up to work on a Leadwerks box brush so you can just slap it on one of those to quickly see it in action. The picture doesn't do it justice you have to move it around to see the effect. Anyway it's something fun. 27a_ice.zip
-
Yeah it uses kernels to blur the image then subtracts the standard image from it which gives a grey, and the difference due to the blur sharpens it up. That's what high pass is in GIMP. I don't know how it would be used for lights. Looks like this:
-
Yeah totally dude it's from muh blog.
-
I did a high-pass filter: VERTEX: #version 400 uniform mat4 projectionmatrix; uniform mat4 drawmatrix; uniform vec2 offset; uniform vec2 position[4]; in vec3 vertex_position; void main(void) { gl_Position = projectionmatrix * (drawmatrix * vec4(position[gl_VertexID]+offset, 0.0, 1.0)); } FRAGMENT: //from https://learnopengl.com/Advanced-OpenGL/Framebuffers #version 400 //Variables float pass_mix = 0.5; float spread = 1000.0; float brightness = 1.3; //Uniforms uniform sampler2D texture1; uniform bool isbackbuffer; uniform vec2 buffersize; //Outputs out vec4 fragData0; float offset = 1.0 / spread; vec3 blendMultiply(vec3 base, vec3 blend) { return base*blend; } vec3 blendMultiply(vec3 base, vec3 blend, float opacity) { return (blendMultiply(base, blend) * opacity + base * (1.0 - opacity)); } void main(void) { vec2 coord = vec2(gl_FragCoord.xy/buffersize); if (isbackbuffer) coord.y = 1.0 - coord.y; vec4 outcol = texture(texture1,coord); vec2 offsets[9] = vec2[]( vec2(-offset, offset), // top-left vec2( 0.0f, offset), // top-center vec2( offset, offset), // top-right vec2(-offset, 0.0f), // center-left vec2( 0.0f, 0.0f), // center-center vec2( offset, 0.0f), // center-right vec2(-offset, -offset), // bottom-left vec2( 0.0f, -offset), // bottom-center vec2( offset, -offset) // bottom-right ); //Blur float kernel[9] = float[]( 1.0 / 16, 2.0 / 16, 1.0 / 16, 2.0 / 16, 4.0 / 16, 2.0 / 16, 1.0 / 16, 2.0 / 16, 1.0 / 16 ); vec3 sampleTex[9]; for(int i = 0; i < 9; i++) { sampleTex[i] = vec3(texture(texture1, coord + offsets[i])); } vec3 col = vec3(0.0); for(int i = 0; i < 9; i++) col += sampleTex[i] * kernel[i]; //High Pass vec3 high_pass = 0.5 - 8.0 * (col - outcol.xyz); //Output fragData0.xyz = blendMultiply(outcol.xyz,high_pass,0.5); //fragData0 = vec4(high_pass,1); //pure high pass }
-
You can try changing the bottom of the shader like this. This works in the material editor for me. #if BFN_ENABLED==1 //Best-fit normals fragData1 = texture(texture15,normalize(vec3(normal.x,-normal.y,normal.z))); fragData1.a = fragData0.a; #else //Low-res normals fragData1 = vec4(normalize(normal)*0.5+0.5,fragData0.a); #endif int materialflags=1; if (ex_selectionstate>0.0) materialflags += 2; fragData1.a = materialflags/255.0; float specular = color_specular.r * 0.299 + color_specular.g * 0.587 + color_specular.b * 0.114; fragData2 = vec4(0.0,0.0,0.0,specular); vec3 dissolve_col = vec3(0,1,0); if (NoiseV<InvAlpha+0.03) fragData2 = vec4(dissolve_col,specular); }
-
I'm snowed in I have limited power/internet. I'll get back to you on it but it looks like the specular affects it because he made the specular channel and the normals alpha channel the same. I tend to think Shadmar knows what he's doing and I'm not sure why he did it this way but I'm sure the fix will be pretty easy.
-
Is it red in the Material Editor? If so it could be your normals alpha channel. Edit: I just saw the picture it looks like it is. The first thing I would do is check your fragData1 lines in the Fragment shader. They should look like: //Normals Output fragData1 = vec4(normalize(normal)*0.5+0.5,fragData0.a); fragData1.a = 1/255.0;
-
Oh that one looks cooler anyway.
-
This works fine for me. Is the shader compiling? Or do you mean you get some kind of lag?
-
Anyone have Aggror's old FlowGui ?
havenphillip replied to havenphillip's topic in General Discussion
Awesome. Thanks, guys. -
I used to have it I can't find it anywhere
-
Awesome, dude. It's only going to get better from there. I love that you can put materials on terrain.