Jump to content

Rick

Members
  • Posts

    7,936
  • Joined

  • Last visited

Everything posted by Rick

  1. I think the .5 was to much. I'm using .1 and now it seems to be working.
  2. lol now when I Run on mobile I get error: Error: Failed To Load file "C:/Leadwerks/Projects/MyWhackyMoles/Projects/Android/libs/armeabi/sta93584". but now I see the mesh and the right transparent texture. wtf lol Thanks Chris!
  3. *sigh* this is frustrating. When I made it 256x256 I see it on PC but I can't see the cube at all on mobile. It's there, because picking works on it, but just can't see it The strange thing is now, I resized the image back to 300x300 just to test, but when I import into LE3 it says it's 256x256 still. Not sure if LE is resizing it to nearest power of 2 or what.
  4. Rick

    LE2 question

    I think you can increase the step size on the controller, but it might be a little jerky when walking up/down steps. I personally like how World of Warcraft does it, where they create a ramp, like you have, but they make it invisible. It makes for a smooth walking experience. Yes, it can look funny if you see your character not exactly on the stairs, but it's a compromise of easy to do, smooth experience, for looking slightly funny.
  5. Below is an idea of how I'm doing my main menu. I zoomed out to get a better idea of what it is I'm looking at. The menu will be in 3D. Normally all you'd see is that scene with tree's on it close up to the camera as the background and the white play button is actually a Model:Box() I make in code. When doing camera:Pick() I'm only caring about the box I made in code. I get it a key name "id" a value of "btnNewGame". However, picking the CSG background model is coming back as the btnNewGame box was picked. I can't figure out why this would be. box creation self.buttonMaterial = Material:Load("UI/play_button.mat") --self.buttonMaterial:SetBlendMode(1) self.button = Model:Box() self.button:SetScale(1, 1, .5) self.button:SetPosition(0, -20, 2) self.button:SetMaterial(self.buttonMaterial) self.button:SetKeyValue("id", "btnNewGame") picking code function App:MainMenu_Update() if self:IsMobile() == true then result = self.window:TouchHit(0) else result = self.window:MouseHit(1) end local pickinfo = PickInfo() local p = self.window:GetMousePosition() local id = "" if result == true then if self.camera:Pick(p.x, p.y, pickinfo, .5, true) == true then id = pickinfo.entity:GetKeyValue("id") if id == "btnNewGame" then self:Gameplay_Enter() self.gameState = "gameplay" end end end end
  6. We talked on LE's IM and I had him just load the material he created instead of doing all the loading of the separate pieces as it didn't seem he had any real reason to load the separate pieces in code.
  7. Rick

    sky box

    @YouGroove In the material folder he already has a model that you just drag into the scene to get your sky dome.
  8. Woah! I guess that will teach us to look at the parameters section instead of the syntax section :/ http://www.leadwerks.com/werkspace/page/documentation/_/command-reference/map/mapload-r510 I'll have to test this with Lua.
  9. So this is working on PC. On mobile the cube is just all white. No texture at all
  10. After the map is loaded, the only thing I see under self.world is ambientlight (via the lua editor that shows the current state).
  11. App.lua is for the entire project. However, if I open up scene1, but in App.lua the first scene it should be loading is scene0, scene1 is still the one loaded because I have it open in the editor. That doesn't make sense. I feel like what App.lua says is what should happen when we run it no matter what scene I have open in the editor. Also, when I switch from 1 loaded map to another, I'm not seeing some csg I have as the ground in the newly loaded map, and the old csg still exists in the last map loaded because I can't seem to find a way to clear that loaded map.
  12. Any ideas on just a box I made: self.buttonMaterial = Material:Load("UI/round_button.mat") self.button = Model:Box() self.button:SetScale(1, 1, .1) self.button:SetPosition(0, 0, 1.54) self.button:SetMaterial(self.buttonMaterial) The same material has black for transparency on a Model:Box()
  13. Once again shadmar you come to the rescue! Thanks!
  14. I don't think we can at the moment, which is insane, but in another thread Josh was talking about ways of allowing this probably a week ago or so.
  15. Is it possible to have a texture with transparent spots, have that transparency be applied when painted onto a CSG model? I have this situation, make a lightmapped material for it, but it on the model and the transparent parts show up as white. Any ideas?
  16. Rick

    2D on mobile

    OK, I'm going 3D with this stuff I think. The main menu background I'll just make a material for and slap it on a CSG object in front of the camera. Will do the same for the buttons I think and just pick them for selection. That way I don't have to worry about this 2D ****
  17. So it says iPhone 5 is 1136x640, and people say it's 16:9 aspect ratio, but that doesn't add up. 1136x639 is 16:9 aspect ratio. I get that it's 1 off but when calculating the aspect ratio in code it matters. Are people just saying the 640 but on the device if I query for it it'll say 639 so the aspect ratio is correct?
  18. Rick

    2D on mobile

    1) For sure not waiting for LE GUI seeing as my game is probably 1-2 weeks from being complete. 2) I've thought of 3D GUI and I might go that way, but 2D is generally easier (make a image, DrawImage() on the screen, minus the resolution issue).
  19. Rick

    2D on mobile

    Not looking to go 2D, but there will be 2D menus in my 3D game, which is my main reason for my question.
  20. Rick

    2D on mobile

    I'm nervous about dealing with 2D on mobile platforms, given so many different resolutions and aspect ratios. Testing for all the different variations and potentially needing different sizes of the same image (not stretced because it could look bad) just seems like a giant pain Has anyone made a game on mobile that had 2D elements and have any tips?
  21. I have an image of a heart (for player life). I draw 3 of them. The first one is transparent in the right places, but the other 2 are not. Not sure why. // loading the heart in App:Start() self.heartImage = Texture:Load("UI/heart_64.tex") // drawing in App:Loop() self.context:SetBlendMode(Blend.Alpha) x = 0 for i = 0, self.heartCount - 1 do self.context:DrawImage(self.heartImage, x, 35) x = x + self.heartImage:GetWidth() end self.context:SetBlendMode(Blend.Solid) --Refresh the screen self.context:Sync(true) On my Samsung tablet it's displayed correctly though, so seems like a PC thing.
  22. Rick

    sky box

    Thanks shadmar, that did it perfectly!
  23. Rick

    sky box

    Does anyone know how to do a skybox in LE3 so that it also works on mobile (if possible)? I need a nice sunset type look for my game.
×
×
  • Create New...