Jump to content

burgelkat

Members
  • Posts

    203
  • Joined

  • Last visited

Everything posted by burgelkat

  1. found it: if self.mat ~= nil then self.mat:SetTexture(self.textures[count],0) end
  2. i have a fx-explosion animation converted in 54 pictures now i would use the cheap water lua to display the explosion. this is the Script (edited) from the cheap Water.lua (Workshop) but this script use the normals. What can i do that it use the difuse texture ? -- Make this the material you used on your face. Script.Material = ""--path function Script:Start() self.textures = { } --(old) Fetch workshop animated water normals(old) for x=0,9,1 do local name = "footagecrate-simpleexplosion22_"..x..".tex" self.textures[x] = Texture:Load("Materials/Effects/Explosion/"..name) end for x=0,54,1 do local name = "footagecrate-simpleexplosion22_"..x..".tex" self.textures[x] = Texture:Load("Materials/Effects/Explosion/"..name) end -- Load material --self.mat = Material:Load(self.Material) self.mat = self.entity:GetMaterial() self.entity:SetMaterial(self.mat) self.model = self.entity self.index=0 end function Script:UpdateWorld() -- Animate normals for texture1 for material if self.index > 54 then self.index=0 end local count = 0 self.index=self.index+Time:GetSpeed()*0.25 count=math.floor(self.index) if self.mat ~= nil then self.mat:SetTexture(self.textures[count],1) end end i have build a spirtesheet too but i have no control over the start picture. iIf I load the material over a script, then it may happen that the explosion starts in the middle. Therefore I can not use the firepit shader. or an ermitter does not work that way. So I had the idea to try the single pictures. sorry for the english i hope you understand what i mean and someone can help by the way this is a nice webside: https://vfx.productioncrate.com/explosion-vfx-categories.html#_ga=2.63300844.238680612.1515842131-1939002152.1515230501
  3. It may be a stupid question, but what is better for the performance: opening and closing a door with animation or using open close script?
  4. Hi , Currently I'm planning the next level for Behind Enemy Lines. Since the player has to do part of the level with a sniper rifle, a little preliminary work had to be done. So, Here's my way to tackle this topic with the Addon "FPS Weapon Pack": The tutorial from tipforeveryone was very helpful to me. You can find it here https://www.leadwerks.com/community/blogs/entry/1775-realistic-sniper-rifle-scope-in-lua/ i downloaded a Scope frome here :http://www.cadnav.com/3d-models/model-36647.html and put it as a child to the "vwep m4" and saved it as a prefab "vwep m4_sniper" it should be look like this Now you have to ajust the scope But for the scope script to work, an empty script must be inserted in the following places. Thanks to Macklebee for this hint! Now you have to change 2 scripts 1. fpsgun.lua 2. fpsplayer.lua 1. fpsgun.lua this script i saved under "FPSGun_Sniper.lua" then this video helps a lot :https://www.youtube.com/watch?time_continue=628&v=3OqwQSP-2FU thanks to BluHornet place this in your fpsgun_sniper.lua Script.offsetNor=Vec3(0,0,0) Script.offsetADS=Vec3(0,0,0)--Vec3 "Offset ADS" the next line put after the function Script:Start() self.offsetNor = self.offset self.hasZoom=true self.hasZoom=true (or false) has been inserted because the ironsight will be active in every weapon, but at Grenade or something else i did not want this. Since I have difficulty with the sway of the weapon and I have no solution for it currently, I commented under function Script: Draw () the following lines out: --self.swayspeed = Math:Curve(speed,self.swayspeed,20) --self.swayspeed = math.max(0.5,self.swayspeed) --self.amplitude = math.max(2,Math:Curve(speed,self.amplitude,20)) now its time to change the fpsplayer.lua 2. fpsplayer.lua this line put in at the beginning Script.ADSmode=false next place the following lines under the function Script:UpdateWorld() if self.weapons[self.currentweaponindex]~=nil and self.weapons[self.currentweaponindex].hasZoom then if self.ADSmode == false then self.camera:SetFOV(70) self.weapons[self.currentweaponindex ].offset = self.weapons[self.currentweaponindex ].offsetNor end if self.ADSmode == true then self.camera:SetFOV(20) self.weapons[self.currentweaponindex ].offset = self.weapons[self.currentweaponindex ].offsetADS end end and this also in this function (i put this after a lince called "--fire weapon" if window:MouseHit(2) then if self.weapons[self.currentweaponindex]~= nil then if self.ADSmode == false then self.ADSmode=true else self.ADSmode=false end if self.sound.pickupweapon~=nil then self.sound.pickupweapon:Play() end end end if you do not want the ironsight by jump, reload, or carry an item, then paste those lines at the right places self.ADSmode=false Since the original crosshair disturbs me in the ironsight, I have inserted "and self.ADSmode==false then" in the function Script:PostRender(context) it should looks like this if self.health>0 then if self.canUse==true and self.carryingEntity == nil then local pickUpX = math.floor((context:GetWidth() - self.image.hand:GetWidth()))/2 local pickUpY = math.floor((context:GetHeight() - self.image.hand:GetHeight()))/2 context:SetBlendMode(Blend.Alpha) context:DrawImage(self.image.hand, pickUpX, pickUpY) else if self.carryingEntity==nil then if self.weapons[self.currentweaponindex]~=nil then if self.image.crosshair and self.ADSmode==false then local crossHairX = math.floor((context:GetWidth() - self.image.crosshair:GetWidth()))/2 local crossHairY = math.floor((context:GetHeight() - self.image.crosshair:GetHeight()))/2 context:SetBlendMode(Blend.Alpha) context:DrawImage(self.image.crosshair, crossHairX, crossHairY) end end end end What follows now are the individual settings for each weapon to get an Ironsight. M4 Sniper: in the script: the sniper M4 looks now like this the m4 without scope in the script: it should look like this the shotgun in the script the shotgun look like this the pistol in the script the pistol look now like this So, that was my solution. But if you have even better settings, feel free to write in this blog. I hope that this blog helped a bit. Especially to save time to find the settings for the Ironsight. Have fun. Greetings burgelkat
  5. thanks josh .. thats true i am not great at 2D design. I should better stay with the simple one.
  6. Hi, Hello everybody, here is a little blogg. Due to some feedback, I'm thinking about how a better HUD could look like. Below is the Old HUD, and then the new HUD. What do you think? Or how can a HUD look more appealing to this game?
  7. The new look (Galery picture) look good. It would be interesting to draw the hole thing (tree and decal) with the vegetation tool. Is this possible?
  8. After the uploading the new version to the GameLauncher this Version not function. The exe ist updated the project is updated too. There is the "GetStyle" Error. It seems that ohter creators have the same problem. Please use the Dropbox link for the Standalone Version. https://www.dropbox.com/s/b6a9hc5hf5jgygs/BehindEnemyLines.zip?dl=0 The Game Launcher Version now function
  9. please use the stand alone version. This is the most stable version. I did the following: Clean up the Scene Tree (Pivot, Decal, NPC, Enemys got different names). Changes to a few scripts: (instead of enable / disable on the NPC's Walk function, I worked with activate here, leaving the script itself enabled) I also deleted some extensive physic shape on models like buildings and the heli and instead I used csg brushes with a trigger texture and used them as walls. Also on some rocks I deleted the physic and worked with csg brushes. Lights I've also provided NPC and the vehicles with occlusion culling. In the map "Intro" I left the lights in the field as "Far". If I work with medium here and go farther away, the fps breaks 60 to 55 and fluctuates constantly. So I left these more on Far. If i have the fbx models then i use blender to bind some models together (the cottage with interior like bed desk etc. and the checkpoint with interior and also the airfield cottage with interior So these were my clean ups. Judging from the standalone version, these were all helpful solutions. I still invite this version to the workshop. Let's see if the launcher runs so stable and fast. Have fun with this version.
  10. thats my settings look for the right shader there is a special for decals
  11. burgelkat

    Exit Zed

    did not crash .. the zombies stand up again after they are dead and run at place
  12. Here is a Standalone Version of this Game This Version has a fixed crash at the Shootingrange. Also it is smoother then the Game-Launcher Version (i think so ) Now i have to work on the Story Part "little village" in Akt1 Part2 Have fun. https://www.dropbox.com/s/b6a9hc5hf5jgygs/BehindEnemyLines.zip?dl=0 Edit (8.11.17): This Standalone Version has now a Option Menu where you can change the resolution. At the moment the HUD ist only optimised for 1920x1080. If you change the resolution you have to load the level again (over MainMenu). Best is you change the resolution after start. New: - Hud hides in cutscene - player can´t move in cutscene - FPS is nearly constant 60 fps (with my system; you can tell me whats your fps in this thread )
  13. In Act1 _Part2 the part "Checkpoint" was now completed. In addition, some changes were made to improve the performance a little. I tried to get 60 FPS mostly. Unfortunately, I do not always succeed. Nevertheless, I hope that it works for most people. Edit: known issue if the fps in Akt1 Teil 2 drops down please load the game again and use the Menu: Level to load the Level again. Most the Fps is then better. At this time i dont know why. Feedback is welcome. Have fun with this update.
  14. function Script:Alarm()--in target=player self:SetTarget(target) end
  15. Hi, i hope someone can this explain to me. i would like to set the target with a script after a "alarm" turn on. The soldiers keep watch outside the building. so i put this into the script "SolderAI". function Script:Alarm()--in self:SetTarget(player) end Now if the alarm turn on the soldier (merc) run into the building (so far so good) but now if they "see" me the game crashes (no error). If i hide myself in a room and the soldier find me then the game crashes if they try to hit me. what i do here wrong? and how can i set the target in a script. thanks for your help
  16. a phone booth i created in blender
  17. yes , i agree too. Very nice models
  18. Halloween Tournament 2017 Behind Enemy Lines Prolog: You are Sergeant Cole, a member of a special unit that operates under cover. You and your comrades have the mission to destroy drug fields and facilitys for the production of drugs. ..... Keys WASD = Moving F = Flash light N = Nightvision T = Holster Weapon E = Use Space = Jump F11 = Show stats See also this blog: https://www.leadwerks.com/community/blogs/entry/2058-behind-enemy-lines/ and this is the link to the workshop: https://steamcommunity.com/sharedfiles/filedetails/?id=1154407899 i updated my project. i bind more objects in blender together and importet it to LW. This allowed me to reduce batches.In addition, I changed some camera settings, so the FPS has increased.But for the FPS break trough the cutscenes, I currently have really no solution. The scenes now have to be displayed as they are. otherwise I will not continue in my project. There is, of course, a solution in the further course.
  19. i updated my project. i bind more objects in blender together and importet it to LW. This allowed me to reduce batches.In addition, I changed some camera settings, so the FPS has increased.But for the FPS break, I currently have really no solution. The scenes now have to be displayed as they are. otherwise I will not continue in my project. There is, of course, a solution in the further course.
  20. i played it too. Really cool . i like it
  21. mhm (there is no crash by me) but GL_FRAMEBUFFER_INCOMPLETE_ATTACHMENT Not all framebuffer attachment points are framebuffer attachment complete. This means that at least one attachment point with a renderbuffer or texture attached has its attached object no longer in existence or has an attached image with a width or height of zero, or the color attachment point has a non-color-renderable image attached, or the depth attachment point has a non-depth-renderable image attached, or the stencil attachment point has a non-stencil-renderable image attached. Color-renderable formats include GL_RGBA4, GL_RGB5_A1, and GL_RGB565. GL_DEPTH_COMPONENT16 is the only depth-renderable format. GL_STENCIL_INDEX8 is the only stencil-renderable format. i have to look at the models.. i think there is something.. and this is and this could be the reason for the short frame break at this point as well
  22. can you look at the "log" from the game launcher and post me the error? thx
×
×
  • Create New...