-
Posts
327 -
Joined
-
Last visited
-
Days Won
2
Everything posted by Ren_712
-
I think it might me a stripped down ivhud. But i may be wrong https://community.multitheftauto.com/in ... ls&id=3003
-
That's great to hear.
-
1. If you are using to texture effect - Just download shader_tex_names from shader examples. Use it to get texture names of the machine objects. Other way you can get texture list: table engineGetModelTextureNames( string modelId = "" ) for _,name in ipairs( engineGetModelTextureNames( "480" ) ) do engineRemoveShaderFromWorldTexture(shader,name) end 2.A screenshot comparison would be nice . "shader_car_paint" example has not been written by me. As any other resource on example page. There has been some issues with it - look for "shader_car_paint_fix" on community. Set the filmic pass and sky reflection to 0 if it interferes. I haven't noticed any major color issues (apart from issues with white - that was main fix).
-
you don't need to change anything in the .fx file at all. 1.Look into the lua file and see how the effect is being applied 2.Change the texcube (.dds) file in textures folder to get more appropriate 'reflection'. All in all you can apply this effect to anything
-
bool dxDrawMaterialLine3D ( float startX, float startY, float startZ, float endX, float endY, float endZ, element material, int width, [, int color = white, float faceTowardX, float faceTowardY, float faceTowardZ ] ) First and second point in space (x,y,z) should be bottom back and bottom front of the vehicle. Element material is the texture then width, color white, fade toward xyz would be 0,0,-1
-
1. You can't. All you can do is create a spheric object and apply effect to it's texture. You can also mess with the cloud textures, but it won't give you much. 2.You mean skin texture ? Create shader for "ped". Then apply shader to world texture. An example: http://www.solidfiles.com/d/64ae35feab/golden_ped.zip How do I create such a shader? http://www.gamer.ru/system/attached_ima ... 537243.jpg oCain shader pack for enb had sin_city post process effect. With minor alterations it would work for mta. http://playmods.blogspot.com/2013/06/gt ... hader.html
-
I posted a reflection shader called golden_ped, which is a modified stock effect reflective bump from nvidia examples. It's in your last topic afaik. It's quite similar, you would need a diff cubebox tho.
-
I have two questions: 1. How to replace the color of the sky using shaders and his client file? (not using setSkyGradient) 2. How to replace the player skin model, if I replaced them with a new model? 1. You can't. All you can do is create a spheric object and apply effect to it's texture. You can also mess with the cloud textures, but it won't give you much. 2.You mean skin texture ? Create shader for "ped". Then apply shader to world texture. An example: http://www.solidfiles.com/d/64ae35feab/golden_ped.zip
-
Telebim. Widok z kamery w realnym czasie.
Ren_712 replied to polakg1140's topic in Pomoc ze skryptami i programowaniem w Lua
Jeśli chodzi o zastępowanie tekstur dla obiektów, to proponuje zapoznać się z: https://wiki.multitheftauto.com/wiki/Shader zamiast engineImportTXD użyj engineApplyShaderToWorldTexture Przykładowy zasób: https://community.multitheftauto.com/in ... ls&id=4600 -
You have misunderstood me. Your shader replaces only the texture areas and all. I want everything to be black and white, except for: plamyani, fire, flag, osescheniya and shadows - they ostalis unchanged (colored). Generally, the shaders in the game "The Saboteur". How to make this function? You can not exclude elements from a screensource (unless you are talking about screen depth). That is why i proposed a 'to texture effect' not screen space effect. The texture list that fits perfectly is in the resource shader_flashlight_test Also you will find the solution to apply shaders with vertex lighting - look at the ped effect. To make it look good enough you will have to make separate effects for peds, vehicles and world objects. You can't do much for coronas - changing their texture colours seems impossible. At least when i tried it.
-
engineApplyShaderToWorldTexture ( shader, "*" ) engineRemoveShaderFromWorldTexture ( shader, "sometexturename" ) use shader_tex_names resource to find the texture names that you want to remove
-
As i see it, you should skip getting screensource. Plus, should pass vertex colors. I mean if don't want to make a screen space effect, but texture effect. addEventHandler( "onClientResourceStart", resourceRoot, function() -- Create shader local shader, tec = dxCreateShader ( "shader.fx" ) if not shader then outputChatBox( "Could not create shader. Please use debugscript 3" ) else outputChatBox( "Using technique " .. tec ) -- Apply shader to all world textures engineApplyShaderToWorldTexture ( shader, "*" ) end end ) And the shader code is: //--------------------------------------------------------------------- // Include some common stuff //--------------------------------------------------------------------- #include "mta-helper.fx" //--------------------------------------------------------------------- // Sampler for the main texture //--------------------------------------------------------------------- sampler Sampler0 = sampler_state { Texture = (gTexture0); }; //--------------------------------------------------------------------- // Structure of data sent to the vertex shader //--------------------------------------------------------------------- struct VSInput { float3 Position : POSITION0; float4 Diffuse : COLOR0; float2 TexCoord : TEXCOORD0; }; //--------------------------------------------------------------------- // Structure of data sent to the pixel shader ( from the vertex shader ) //--------------------------------------------------------------------- struct PSInput { float4 Position : POSITION0; float4 Diffuse : COLOR0; float2 TexCoord : TEXCOORD0; }; //------------------------------------------------------------------------------------------ // VertexShaderFunction // 1. Read from VS structure // 2. Process // 3. Write to PS structure //------------------------------------------------------------------------------------------ PSInput VertexShaderFunction(VSInput VS) { PSInput PS = (PSInput)0; // Calculate screen pos of vertex PS.Position = MTACalcScreenPosition ( VS.Position ); // Pass through tex coord PS.TexCoord = VS.TexCoord; // Calculate GTA lighting for buildings PS.Diffuse = MTACalcGTABuildingDiffuse( VS.Diffuse ); return PS; } //------------------------------------------------------------------------------------------ // PixelShaderFunction // 1. Read from PS structure // 2. Process // 3. Return pixel color //------------------------------------------------------------------------------------------ float4 PixelShaderFunction(PSInput PS) : COLOR0 { float4 texel = tex2D(Sampler0, PS.TexCoord) * PS.Diffuse; float gray = (texel.r + texel.g + texel.b)/3; float4 finalColor = float4(gray, gray, gray, texel.a ); return finalColor; } //------------------------------------------------------------------------------------------ // Techniques //------------------------------------------------------------------------------------------ technique grayTextures { pass P0 { VertexShader = compile vs_2_0 VertexShaderFunction(); PixelShader = compile ps_2_0 PixelShaderFunction(); } }
-
There has been a lot of improvement in this project. The outcome seems so complex and artsy, i never expected it to be this good.
-
There was something like that. But I can't tell if it works with current MTA https://community.multitheftauto.com/in ... ails&id=84
-
I was kind of waiting for someone to make that kind of thing. Is that lineMaterial3d or some world texture the effect is being applied to ?
-
Open that in gimp ( with dds plugin) or photoshop. Resize all the 6 images. xy should be 2^x like (256px,512px,1024px,2056px). Then save as dds cubebox. Compression should be set to DXT1 or higher.
-
I'd suggest this as well http://digitalerr0r.wordpress.com/tutorials/
-
This video has the easiest explanation on how to export models to MTA Don't ask for 3ds. We don't support piracy here.
-
bool engineReplaceModel ( dff theModel, int modelID [, bool alphaTransparency = false ] ) >>alphaTransparency Pozwala na rozwiązanie (przynajmniej częściowo) problemów z przeźroczystymi obiektami. To odnośnie do 'migających szyb' domku w powyższym video. Kolejna sprawa to (częste w podmienionych obiektach) błyskanie płaskich powierzchni kiedy coś je oświetla (światła samochodu, wystrzał z broni itp). Proponuje pobrać shader 'Road shine' z wiki. Wywalić kod odpowiedzialny za tworzenie speculara. W zasadzie wystarczy sam Vertex Shader. Co do conventera - Aby otrzymać nieskompilowany skrypt klienta, należy w pliku konfiguracyjnym dodać compile=false
-
Exactly. You might call the current technique out-dated, but hey, what do you expect from a game that was made in 2004? It's not just possible to implement a totally new graphics or shaders to it. DX9 has still allot to give - I think that much has not yet been done. Unfortunately, here are not that many people in the community who are into creating shaders.
-
this might get handy: [url=https://wiki.multitheftauto.com/wiki/GetCameraGoggleEffect]https://wiki.multitheftauto.com/wiki/Ge ... ggleEffect[/url]
-
A gui element attached to the shader made with render target
Ren_712 replied to Gallardo9944's topic in Scripting
well you can draw dxDrawImage behind the window and update it's shape and position onClientRender, stretch the screenSource image in the pixel shader to make it more convenient. http://imageshack.us/a/img43/7273/64a5.jpg -
switch off the effect when night vision googles are on. There is an event for that.
-
https://community.multitheftauto.com/ind ... ls&id=8000 https://community.multitheftauto.com/ind ... ls&id=8001 stolen from PSC (Polski Serwer Cieżarówek) the stealer admit it in the comment page DONE