Jump to content

Yue

Members
  • Posts

    2,371
  • Joined

  • Last visited

Everything posted by Yue

  1. I've added an empty script to the brush, but it still doesn't work, moving the vehicle breaks the collision and no longer works.
  2. TEMP 2019-11-19 22-13-45.mp4 No work to move vehicle.
  3. Solved Here. Sorry, no solved here.
  4. How can I put that invisible brush but continue to detect the collision trigger, to set when the player gets into the car?
  5. Yue

    Mars!!

    3 minutes to get this image capture. xD Prototype Vehicle.
  6. Yue

    Mars!!

    The lag is terrible in the map editor, and to launch the executable, so the development becomes very tedious, because I have hangups, is that Windows does things in the background and everything stops and the worst of all is that leadwerks crashes. Maybe you should think of something simpler, a game of simple cubes something really very simple.
  7. Yue

    Script Vehicle

    Update First Post, file Script Vehicle. I already have the vehicle's rear transmission. The next step is to work on the front transmission, which includes wheel steering, spring and wheel motor.
  8. Yue

    Mars!!

    Wheels Back Ok. The lag is really discouraging, I don't think it'll get very far again. But you always learn a lot along the way when you try again and again.
  9. Yue

    Mars!!

    To this resolution I have to work from now on, if I try in another superior one, several times the maps and the scripts have been damaged when being loaded.
  10. One question: What does the Generate Shape function do?
  11. Yue

    Script Vehicle

    Working on the suspension of the vehicle, the prototype looks, well, a hard suspension. -- Constructor Vehicle. function this:Start() self.jointFL = Joint:Slider(self.bell0:GetPosition(false).x,self.bell0:GetPosition(false).y,self.bell0:GetPosition(false).z,0,1,0, self.chassis, self.bell0) self.jointFL:EnableLimits() self.jointFL:SetLimits(-0.1,0.1) self.jointFL:SetSpring(100) self.jointFR = Joint:Slider(self.bell1:GetPosition(false).x,self.bell1:GetPosition(false).y,self.bell1:GetPosition(false).z,0,1,0, self.chassis, self.bell1) self.jointFR:EnableLimits() self.jointFR:SetLimits(-0.1,0.1) self.jointFR:SetSpring(100) self.jointBL = Joint:Slider(self.bell2:GetPosition(false).x,self.bell2:GetPosition(false).y,self.bell2:GetPosition(false).z,0,1,0, self.chassis, self.bell2) self.jointBL:EnableLimits() self.jointBL:SetLimits(-0.1,0.1) self.jointBL:SetSpring(100) self.jointBR = Joint:Slider(self.bell3:GetPosition(false).x,self.bell3:GetPosition(false).y,self.bell3:GetPosition(false).z,0,1,0, self.chassis, self.bell3) self.jointBR:EnableLimits() self.jointBR:SetLimits(-0.1,0.1) self.jointBR:SetSpring(100) end Test Spring Vehicle 4 Wheels.mp4
  12. Ok, solved here. -- Constructor Vehicle. function this:Start() self.jointFL = Joint:Slider(self.bell0:GetPosition(false).x,self.bell0:GetPosition(false).y,self.bell0:GetPosition(false).z,0,1,0, self.chassis, self.bell0) self.jointFL:EnableLimits() self.jointFL:SetLimits(0,0) --self.jointFL:SetSpring(-1) self.jointFR = Joint:Slider(self.bell1:GetPosition(false).x,self.bell1:GetPosition(false).y,self.bell1:GetPosition(false).z,0,1,0, self.chassis, self.bell1) self.jointFR:EnableLimits() self.jointFR:SetLimits(0,0) --self.jointFR:SetSpring(0) self.jointBL = Joint:Slider(self.bell2:GetPosition(false).x,self.bell2:GetPosition(false).y,self.bell2:GetPosition(false).z,0,1,0, self.chassis, self.bell2) self.jointBL:EnableLimits() self.jointBL:SetLimits(0,0) --self.jointBL:SetSpring(0) self.jointBR = Joint:Slider(self.bell3:GetPosition(false).x,self.bell3:GetPosition(false).y,self.bell3:GetPosition(false).z,0,1,0, self.chassis, self.bell3) self.jointBR:EnableLimits() self.jointBR:SetLimits(0,0) --self.jointBR:SetSpring(0) end
  13. I have a chassis with a mass of 50 units. Four bells each of 1 unit mass. And this script. self.jointFL = Joint:Slider(0,0,0,0,1,0, self.chassis, self.bell0) self.jointFL:EnableLimits() self.jointFL:SetLimits(0,0) self.jointFL:SetSpring(-1) self.jointFR = Joint:Slider(0,0,0,0,1,0, self.chassis, self.bell1) self.jointFR:EnableLimits() self.jointFR:SetLimits(0,0) --self.jointFR:SetSpring(0) self.jointBL = Joint:Slider(0,0,0,0,1,0, self.chassis, self.bell2) self.jointBL:EnableLimits() self.jointBL:SetLimits(0,0) --self.jointBL:SetSpring(0) self.jointBR = Joint:Slider(0,0,0,0,1,0, self.chassis, self.bell3) self.jointBR:EnableLimits() self.jointBR:SetLimits(0,0) --self.jointBR:SetSpring(0) The result is not what you imagined, some possible help. I need to create a hard suspension, not a buggy suspension.
  14. Yue

    Mars!!

    The mechanic on Mars
  15. Yue

    Script Vehicle

    Vehicle analysis. As you will have two vehicles, this vehicle is something special, because in its four wheels has four bells, then in the back the two bells will have two spring unions that stick to the chassis, in turn the tires are attached to each bell with a hinge union. On the front transmission I do not yet have it very clear, initially must be think a hinge union to turn the bell and then the spring union, I have to think better this. Any suggestion is welcome.
  16. Yue

    Script Vehicle

    The script for the vehicle has been started. Initially four wheels, although it is necessary to go thinking about 6 wheels, this one serves us as base to go developing the system. Vehicle.lua
  17. It looks great, and that's the average number of polygons I've established, between 5,000 and 6,000.
  18. Yeah, it's a good idea, a bigger one to transport supplies.
  19. For some reason I am motivated to create a test prototype for a vehicle. So we already have our temporary model for when a more robust and elegant model arrives. The idea is that the player can get into the vehicle and walk the surface of Mars.
  20. The only difficulty I've had in my vehicle prototypes is that it affects my performance a lot, I think it's because of my low computing power, vehicle rocks, they lower the fps a lot, but it would be good to try again. It would be to make a simple prototype to see if it works better.
  21. This is a movie, I don't remember the name, I remember that in some time I looked for some vehicle similar to this one, but it was impossible. Those jobs are always paid.
  22. It looks great, I was just thinking about that, including a vehicle. I was looking for just one, but that one looks really good. Implement the driver to be the astronaut, I have the experience to program it.
  23. The hud player is based on an image of the astronaut, and the respective bars are made with drawing operations in Leadwerks. If you want to collaborate in the improvement of this part of the project, feel free to modify the code and make new suggestions for it. HudPlayer.lua
  24. Lua is a programming language that has the option of simulating the object-oriented programming paradigm. At this point the work method implemented is to work with classes that are implemented through the use of tables. For example in the project I have a file that simulates a class called HudPlayer The content of this file refers to the player's hud, such as his image shown on the bottom right and the respective health, energy, and oxygen bars. And the content of that file is as follows: Hud = {} function Hud:Create() local this = {} this.context = nil this.window = nil this.imgPlayer = nil this.damage = nil this.dEnergy = nil function this:Start() self.context = Context:GetCurrent() self.window = Window:GetCurrent() self.imgPlayer = Texture:Load("Imagenes/HudPlayer.tex") self.damage = 0 self.dEnergy = 0 end this:Start() function this:Draw() self:DrawBarHealth() self:DrawBarEnergy() self:DrawBarOxigen() self:DrawImgPlayer() end function this:DrawImgPlayer() self.context:SetBlendMode(Blend.Alpha) self.context:SetColor(0.941, 0.521, 0.2) self.context:DrawImage(self.imgPlayer,self.window:GetWidth()-185,self.window:GetHeight()-243,339/2,410/2) self.context:SetBlendMode(Blend.Solid) self.context:SetColor(1,1,1) end function this:DrawBarHealth() self.context:SetColor(0.941, 0.321, 0.2) self.context:DrawRect(self.window:GetWidth()-327, self.context:GetHeight()-50,200,50) self.context:SetColor(0.556, 0.082, 0.082) self.context:DrawRect(self.window:GetWidth()-322, self.context:GetHeight()-45,190,40) self.context:SetColor(0.2, 0.2, 0.2) self.context:DrawRect(self.window:GetWidth()-322, self.context:GetHeight()-45,self.damage,40)--Max 190 self.context:SetColor(1,1,1) end function this:DrawBarEnergy() self.context:SetColor(0.133, 0.886, 0.156) self.context:DrawRect(self.window:GetWidth()-322,self.window:GetHeight()-49,190,5) self.context:SetColor(0,0,0) self.context:DrawRect(self.window:GetWidth()-322,self.window:GetHeight()-49,self.dEnergy,5) self.context:SetColor(1,1,1) end function this:DrawBarOxigen() self.context:SetColor(0.176, 0.901, 0.898) self.context:DrawRect(self.window:GetWidth()-322,self.window:GetHeight()-84,190,5) self.context:SetColor(0,0,0) self.context:DrawRect(self.window:GetWidth()-322,self.window:GetHeight()-84,10,5) self.context:SetColor(1,1,1) end function this:AddDamage(damage) self.damage = damage end function this:AddDamageEnergy( energy ) if self.dEnergy < 190 then self.dEnergy = self.dEnergy + energy end end function this:RecoverEnergy( energy ) if self.dEnergy > 0 then self.dEnergy = self.dEnergy - energy end end return ( this ) end So the way to work is to create these files to attach to the project. For example a particle system to simulate a storm on Mars, or similar things.
×
×
  • Create New...