Jump to content

Rick

Members
  • Posts

    7,936
  • Joined

  • Last visited

Everything posted by Rick

  1. Yeah, the idea would be like in fallout 1 & 2, but like you said fallout is iso and was in 2D so they had finer control over every pixel. I'm guessing a shader could be made that stops the light in it's tracks. Of course I don't know anything about coding shaders so that's out of the question for me. Then again if it stopped the light, I would assume that mesh would then turn black.
  2. So having a mesh that just has faces on the ceiling works for stopping the inside light from going outside the building, but not having a face on the top part still allows outside light to come in. So now I would think having a transparent top part of the roof could stop the outside light from coming in, but still see thru. If we can figure that part out then this would be golden. That should allow shadows on the inside. I could just hide the directional light when I go inside the building. That gives the look on the inside that I'm after but then the outside is kind of bland. [edit] Really what I need is a light stopping brush that can be see thru.
  3. Ah, so you also mess around with the transparent world. Lum was saying that wasn't needed. Still that sucks that you aren't getting shadows too. Why is it always something >< I guess for now I'll just deal with the outside light affecting the inside.Frustrating. I'm really thinking inverting the top part might work. I'll play around with that.
  4. That mat file didn't seem to work either. I get some very random color of the floor but it's still mostly black. Is my transparent image not correct? I linked it above in dds format. Maybe someone can check it out. I wonder if an inverted mesh on the inside ceiling and a transparent mesh on the roof part would work. That should allow one to see inside and the light should still bounce off the ceiling mesh.
  5. Well it's getting closer but not 100% there. The mat file that looks like: texture0="abstract::transparent.dds" castshadows=1 nodraw=1 blend=light shader="abstract::mesh_diffuse.vert","abstract::mesh_diffuse.frag" produces http://dl.dropbox.com/u/1293842/after3.jpg and the mat file that looks like: texture0="abstract::transparent.dds" castshadows=1 nodraw=1 blend=alpha shader="abstract::mesh_diffuse.vert","abstract::mesh_diffuse.frag" produces http://dl.dropbox.com/u/1293842/after2.jpg So it's not there because you can't see the inside of the building. I have no idea why I can see the player but not the inside of the building. After thinking about this I'm not 100% sure it's possible to do this. I mean I would need the light on the inside of the building to be able to be seen so it's not pure black, but the light on the outside to stop at the transparent part, so it doesn't affect the inside. Even rendering the lights and hiding/showing models in a certain order would still give me the same black result. So can anyone think of a way to do this. It's like popping the roof off a house but not having the sunlight affect the inside of the house, but now you see the light on the inside as if the roof was still there.
  6. OK, I'll give that a try. What's the difference between blend=alpha or light?
  7. OK, I have texture0="abstract::transparent.dds" castshadows=1 nodraw=1 shader="abstract::mesh_diffuse_bumpmap.vert","abstract::mesh_diffuse_bumpmap_specular.frag" But I get the same result. If I make the material look like texture0="abstract::transparent.dds" castshadows=1 nodraw=1 shader="abstract::mesh_diffuse.vert","abstract::mesh_diffuse.frag" I don't get the roof looking like it has the swat bumpmap, but it's still shaded like my after picture above, and not see thru.
  8. I figured it would just ignore it. What is the proper shader?
  9. This didn't seem to work for me at all. Here is my mat file texture0="abstract::transparent.dds" shader="abstract::mesh_diffuse_bumpmap.vert","abstract::mesh_diffuse_bumpmap_specular.frag" Here is transparent.dds http://dl.dropbox.com/u/1293842/transparent.dds Here is the code I use TMaterial _transparentMat = LoadMaterial("abstract::transparent.mat"); //where ent is the model so it's child is the mesh. if I just try painting the model nothing changes so had to do this PaintEntity(GetChild(ent, 1), _transparentMat); Here is the before http://dl.dropbox.com/u/1293842/Before.jpg Here is the after http://dl.dropbox.com/u/1293842/After.jpg The strange thing is that if you look at the after, it's almost like it's putting the normal map for the swat guy. No clue why it's doing that. Any ideas?
  10. ok ok, I'll ask. Why should this be in 3D?
  11. I would say .NET with custom controls. Then you can make it so the controls can be moved at run-time. The only issue I've had with custom controls and moving at run-time is that as you are moving them they flicker, which is kind of annoying. For my flowgraph project I have I draw them out in code. That way I avoided the flickering, but then again I didn't have controls like text boxes and stuff in them so I could do that easily enough.
  12. Probably because I was looking in the Materials section. Thanks.
  13. OK, I'll give that a try tonight. I'll make a transparent texture, and load that at runtime and paint it to the model's I need to be transparent. How can I get the current material on a model then? Ideally I would just be able to save the current materials off of the models so I can reapply them when I need to "show" them again. I didn't see a command for GetMaterial() though.
  14. So would that invisible.mat material work for this? Also how do I apply that to models in code? I guess I would need to switch between the models currently material and this one since I need to show and hide them in realtime.
  15. That would mean the models would need to be in the transparent world right? If that's the case would I need the models in both transparent and main world? The main world to get the physics and stuff to interact with the player, then hide the main world one and show the transparent world one? Does the physics in one world interact with the physics in another? Would the invisible.mat that other models are painted with in the editor work? I assume light just goes through those models painted with that but maybe there is a setting in the mat file to change that? Also, if I can do that how do I apply that mat in code? Then I have to do the lua setup stuff myself though right? Could I still use the framework to get the lua stuff working but not call the frameworks RenderFramework(); but instead break that out? Is there a way to get the gbuffer from the framework? I feel like this would probably be the best way to do it, just sucks the framework is not flexible enough to handle stuff like this.
  16. Is there a way to have some kind of see thru model or something that prevents light from penetrating thru it? I'm doing a top/down view game where I hide floors and roofs when the player enters buildings. My issue is that the directional light affects the inside of my buildings and I'd prefer if they didn't. I still, however, want them to affect the outside of my buildings. So ideally I would still be able to look into the building from above and see my character inside it, but not have the directional light affect the lighting inside. I would think the ideal situation would be some kind of see thru mesh that blocks the light and isn't affected by the light.
  17. So in Lua I make a model a parent to a cube I create in Lua code. I then give it a setting where the key is "name" and the value is "cube". In C++ the model gets loaded in, but when I try to call FindChild(model, "cube") I get nothing. If I loop through all the children of the model there are 2 children (mesh & my cube). The name key is there. I thought FindChild() read the key called "name" and returned with the first child with a given name matches, but in this case it seems like it's not. Any ideas why?
  18. I am currently working on a game. As usual though the details aren't laid out, but just the basic premise. It's an isometric style camera view where you control a character (a swat guy). The main technical premise is that you can go into any building in a city without any sort of loading. When you go into a building the floors are hidden so it shows a slice of the building so you can see your character (remember it's isometric camera style). You can move around from floor to floor and it'll show the floor you are on but not the ones above. When you exit the building the building is displayed in full again. Using LOD's where the farthest away is pretty much a big block of the building, I should be able to get a pretty large city going. As a swat guy different crimes will be committed around the city (missions) that you'll have to bust people. Stuff like, save the hostages, kill a leader, collect some evidence etc. The first mission I'm planning is a bank robbery where you have to eliminate. I would love to have a better main character that is less by the book than a swat guy though. Like some Die Hard movie stuff.I think people prefer playing the rough around the edges good guy, but I don't have a model for that I currently have the pipeline for making the buildings and finishing up the transition for showing/hiding floors as the character moves around the building, tonight.
  19. Ah, perfect thanks. I figured I forgot something simple.
  20. I have a model just like the lights. Inside the lua script I create a cube and make it's parent the model. I set the position of the cube to the position of the model but it's offset from it. Before when I was using LE function like EntityPosition() my model would be in the center of the cube, when when I switched to :SetPosition() it offset it. local object=self.super:CreateObject(model) object.cube = CreateCube() -- make the cube and make the object it's parent object.cube:SetPosition(object.model:GetPosition(1), 1)
  21. Could the following be simplified? Bank* pixels = new Bank( texture->GetMipmapSize(0) ); texture->GetPixels( pixels ); pixels->PokeByte( (x*height + y)*4, 255 ); texture->SetPixels( pixmap ); to Bank* pixels = new Bank( texture ); pixels->PokeByte( (x*height + y)*4, 255 ); What does PokeByte() do and could it be less math involved? (not that it's hard math or anything, but I remember working with bitmap pixels directly before and you had the offset and how it's all stored in a single array, but it's easier to think of an image as a 2D array with width & height like paint programs visually do)
  22. I haven't checked the lua files yet, but has anyone added a classname by default to all lua scripts? If so, where did you do it, or does anyone have a modified script that does this? I'm sure it's somewhere in the baseclass.lua or class.lua where you would have to do this, but just wondering if anyone has already done something like this that I could use.
  23. Oh, yeah good call. They were left over using the skin shader. >< Guess I should have been more patient with getting an answer because I just started a fresh install of LE. Oh well, my LE dir was getting messy anyway Thanks for jogging my memory about the mat files.
  24. Something funky is going on. So I saved each floor in it's own .3dw file. Run the conversion tool with the following: 3dw2gmf.exe +scale 0.0078125 +file "myfile.3dw" But I'm getting the same issue in the editor where if it's highlighted you can see the outline of the model, but it's invisible otherwise. There should be no bones since I'm going right from 3dw to gmf. Anyone else have this issue?
×
×
  • Create New...