Jump to content

Gonan

Members
  • Posts

    185
  • Joined

  • Last visited

Everything posted by Gonan

  1. I have problems with publishing and no longer seeing the weapon. I have created atestmap and published on Leadwerks steam workshop, playable for friends and admins, the map works ok in the leadwerks engine with a autopistol, but doesn't display or fire a weapon when published to desk top or steam. You can see the autopistol in the published screen shot taken when running on the editor. I'm still using the leadwerks 3.3 beta. Hope this is a easy thing to solve. For now, I will leave the beta version and go back to using the 3.3 release? There is a knack to this doing this, i'll quickly explain. if I try steam library - leadwerks Game Engine [beta] - properties - BETAS tab, has Select the beta you would like to opt into: beta - Latest build for testing The drop down to the right doesn't display any other options. However if you use the up and down arrow keys the other options appear, not sure if this is a steam bug, I'm using windows 8.1 64bit. Hope this might help others who are stuck.
  2. I went to my WIP folder, and I didnt do the update, and it worked ok. After the Project Manager update, my problems returned. So I replaced the scripts I had updated with vanilla ones from the mygame and still had problems in that the crawlers were no longer animated. So I stopped leadwerks, and opened the mygame project, and copied the crawlers from prefab and model folders, deleting the original folders in my WIP. Restarted my WIP project and the animation is now working. I will have to re-add the customised logic back into my WIP. Is there any guidance on what or how to modify the .lua scripts so that we are protecting our code from being updated, if we are not supposed to update the supplied .lua scripts, whats the best way of inserting our customised logic?
  3. The version of MidnightPatrol was last updated on the workshop on 5th November. I'm pretty sure it was working with the auto pistol loaded at that time. I have a stand alone version built a couple of days afterwards, and that still works, It doesn't have steam initialised. So something has changed to stop it working, I am assuming Josh doesn't and hasn't run the steam broadcast beta. Ill try recreating another stand alone version.
  4. I'm having lots of problems with leadwerks since joining the steam broadcast beta. I had put it to allow anyone to view, and started playing MidnightPatrol on the leadwerks game player. When looking at game on the workshop, it was not showing a weapon, no error message in the log, but also not showing a loading in the log for a weapon either. Can anyone confirm that the weapon loads if the haven't started using the steam broadcast beta. Ive opted out of the steam broadcast beta, re-booted my pc. I have also tried to publish using the project manager, with a backup of my game, to the desktop, again no weapon. Exporting creates a zip, expanding the zip, gives a game but the character aren't animiated, but the weapon is displayed with cross hairs as it should. However as soon as an AI attack begins the game freezes, with a lua error, not enough memory appearing after about 30 seconds. I also noted that the project was marked with ! and needed an update in the project manager. And this updated 6 files. I've opted out of the broadcast beta but the problems still persist. I don't know if it is the steam broadcast beta, but thought I had better warn others to be wary in case it is. I am also using leadwerks beta , but don't know how to get back to the 3.3 release. There isn't an option on the properties to not participate, so its still showing as beta on my steam library. So it could also be a beta update of leadwerks.
  5. It happened again, I had been kiting them around for about 10 minutes. My logic isn't letting them hit me at the moment, I'm just testing the navigation logic. Checked memory only used 508.3MB.
  6. Assertion failed: npath < m_maxPath, file ..\..\Source\Libraries\RecastNavigation\DetourCrowd\Source\DetourPathCorridor.cpp, line 506 I have been trying to change the behaviour in MonsterAI.lua and hit this assertion. I was just running around the map with 9 Crawlers chasing me. I had managed to split them into at least 2 groups and there were about 3 actively chasing me as we were moving away from the other group, which last time I saw them were clambering up the side of a hill. From the log I had running I can say this bit of code was being used in SetMode(mode) elseif self.mode=="chase" then if self.target~=nil then System:Print("Follow target "..self.EntityName) if self.entity:Follow(self.target.entity,self.speed,self.maxaccel) then if prevmode~="chase" then self.entity:EmitSound(self.sound.alert) end self.followingtarget=true self.animationmanager:SetAnimationSequence(self.animation.run,0.05,300) else System:Print("nil target "..self.EntityName) self.target=nil self.mode="idle" return end end its only happend once self.EntityName is the name given to the Crawler. The last line in the output log before the assertion was nil target Purple I'm not expecting to be able to recreate it, I will update the report if I do.
  7. The doc description says This function gets entity's velocity, in global or local space. should say This function gets the passed entity's distance from this entity. Distance should replace velocity and references to global or local space are not required.
  8. I wonder if anyone else has noticed this happening to them. I haven't found the cause, but its happened about a dozen times over the last month. I have a water.lua script which has as its first line. Script.CameraOrPlayer=nil--entity This creates a CameraOrPlayer box on the Scene - Script tab. I drag and drop the Player from the list of items in the Scene to the box, and the box now says Player. All is fine for a while and I repeat my programming / testing cycle without issue, until it says it can't run the water.lua script because CameraOrPlayer is a nil value. When I check the Scene Script CameraOrPlayer box, I find that its empty, and have to re-drag Player back into it. Then its alright again for a while.
  9. Not sure if this is the right place to highlight any documentation queries, but I have found that there is an inconsistency, between the syntax, the heading and the example given. I've no idea which is correct. SetShape in the syntax or SetLayout in the article name and example. Hope its ok reporting them here, if they need reporting in a different way, please say. I'm sure if found other similar issues on other entries.
  10. @shadmar, you don't need to see my shader, because you are brilliant, I passed the texcoords0 via an "out vec2" through from the vertex shader and used them as an "in vec2" in the fragment shader and it works. Thank you so much, I've been trying to get this working for 2 weeks, starting with zero knowledge of shaders, got your water effect working with the wobble shader for underwater within a couple of hours, and then tried to get lava to work. I even started going through Jamie King's youtube video course on OpenGL upto video 55, of 99, and we have just covered the world to view matrix, so thought I needed the inverse function, and was trying all sorts of combinations of matrix transforms to no avail. 2 minutes after reading your post, I was up and running.
  11. I'm trying to use a fragment shader to represent moving lava, I've found a shadertoy lava but if I try to use that in leadwerks i can get a moving image but it doesn't move with the first person camera. I know that the screen coordinates that I am using need to be changed to a world based system, but I have been unable to get lava plane to have a 3D appearance, ie further away patterns look smaller and near patterns look bigger, and if I move the camera the view doesn't move. The function I am using, at its most basic starts with vec2 p = gl_FragCoord.xy; I think I have to manipulate this into a world position, but I don't have the knowledge on how this can be converted. I think I have to use various transformations that invert those made by leadwerks. Is what I am trying to do possible. Ive tried to use the shader on a material, applied to the plane, but if I do it that way I don't get the lava swirling on the screen, but it still fails to follow the camera. Ie the image of the lava remains fixed to the viewport. At the moment, I have a Lava.mdl, just like a water plane, a lava.lua script which loads a lava.shader. The script sets iGlobalTime as a float, which just counts in 0.005 increments. The other variable is a vec2 iResolution set to context:GetWidth()*2 and context:GetHeight()*2 Though if I try to divide gl_FragCood.xy by iResolution the lava fails to display except as a solid colour. Does anyone have a Fragment shader code snippet that converts coordinates back to world coordinates for Leadwerks? Thanks in anticipation.
  12. I got an error (target nil value) when I was killed by several monsters. Only one of them actually kills you but the others may still call EndAttack() The fix is simple, after the second line of function Script:EndAttack() if self.mode=="attack" then -- add these 4 lines if self.target==nil then self:SetMode("idle") return end -- the script then continues with if self.target.health<=0 then
  13. Slight UI bug here, when you drop onto the root, the drag icon remains in place, so you don't have to left click, you can also scroll to get rid of it. When you drag onto other scene entries the icon disappears correctly.
  14. Thanks both solutions work. Ctrl-z undoes other things done in sequence in the current editing session, so selecting the item to make a child and clicking ctrl-z doesn't make it a child, unless it was the last action done, or you undo you other actions to get to the one that put it there. If you have saved the changes and reloaded Leadwerks you will need to use the drag to the scene root method. Dragging the child to the root of the scene tab - dropping, and left clicking on the root also works, though you will probably need to use the mouse wheel to get to the root, as the scene tab doesn't auto scroll while dragging. If you don't have a mouse wheel you can drag it to other parents and scroll and re-drag to reach the scene root.
  15. Can create and move an entity in the scene tab to become a child of another, for instance a light to become a child of Player. However If I want to undo that relationship, I can't find a way to do so. I can move the child to become a child of a different parent, but not to make it independent. Is there a trick to performing this action?
  16. Bug report. Both the debugger and run crash. The map is loaded onto the workshop. I've cut it down to its bare essentials to show the bug. The box2 has a mass of 6 although this does not seem to matter. If the box is made smaller in the x direction it seems to crash less. if the box is lifted out of the terrain it seems to crash less If the box is placed in different positions the box may fly out of the ground in a different manner. The crash can occur immediately on start of the display or after a couple of seconds. I've had the crash before and after the patch update released today. 30/10/2014 With a particular size and position the crash is consistent, and happens each run/debug. With other sizes and positions the non crash is consistent. I think that the bug is somehow related to the physics. I have managed to place the box into the terrain so that it will fly right out of the top of the view, you can turn and watch it spinning as it flies past, and doesn't cause a crash.
  17. Thanks Josh, There is a limit imposed somewhere, I don't know if its yours or steams, but the Addons updates only works if you don't have more than 50 items subscribed in the workshop. I found this out by seeing what folders appeared within AddOns, and the list of items I was subscribed to in the workshop, and kept unsubscribing those items that were missing, when I got down to 49 and restarted Leadwerks your Road Textures appeared. Ive tried subscribing again, but they don't sync up, I'm suspecting its something you can control as the workshop allows more, but they don't appear during the leadwerks start sync process. Some of the folders contain many items and some few, so a limit on the number of folders seems a bit arbitrary. Now that I have got your Road Textures, is there any way of changing the orientation (Rotation) when using them with the terrain painter, or do I need a separate texture for each road direction and have to use another Layer?
  18. I've switched to Leadwerks 3.3 Beta, and trying out the workshop assets. I have subscribed to most of the none game assets, and found that the Road Textures, that Josh provided, is not appearing in the AddOns folder, I have searched the addons folder for "road" just in case its not under "Road Textures" but there is no content showing. I have reloaded leadwerks, unsubscribed and subscribed again, reloaded again, it took noticeably longer during the Syncing Addons stage, but still no Road Textures folder. Is the asset available for use Leadwerks 3.3 (Beta)? I've been painting the MountainLoop map (created using WorldCreator and available on the workshop) using the workshop assets, and they make such a big difference to the look of the map. The map has a road surface on it, so I was hoping to be able to use the Road Textures. I do like the way the new workshop works though, once the assets have been added to the AddOns folder the start up is really fast.
  19. I noted that if there was 1 particle, the effect of no particles in use, was not noticeable at all, with 1000 about 50 fps, with 4000 15 fps, and with 6000 12 fps, and 9999 7 fps. So I created two script functions in the emitter script. function Script:OneParticle()--in tolua.cast(self.entity,"Emitter"):SetParticleCount(1) end function Script:MaxParticle()--in tolua.cast(self.entity,"Emitter"):SetParicleCount(5000) end Then by using the trigger delay functions with a delay of 5000 set up the flow graph links so that the turning off switch called Pause()function and Activate() for the trigger delay. Output from OnActivate() was then taken to the in for OneParticle(). The delay was required so that particles which had just been emitted had time to fly though the air and disappear through the terrain, without the delay they just vanished mid flight. The turning on switch output was linked to Play() and MaxParticle() as no delay was required. Now the frame rate just slows from 40 fps at the beginning of play() to about 16 during the emission phase, as the last particle disappears it recovers to 60 fps (occlusion culling is set) then climbs to 110 fps. If I hit the pause switch and the emission sequence had finished, I get a 5 second drop in frame rate to 10 fps, then it recovers to 130fps as the particle count is set to 1. Note the emitter is not paused its playing with no visible particles to get this frame rate drop.
  20. The framerate drop seems to happen after the last particle that was emitted and no longer processed. The stages are Emitter Playing - frame rate slow but useable. Emitter Paused - frame rate still similar no new particles are emitted. frame rate slowly speeds up a bit if occlusion culling is selected, the frame rate speed up faster as the particles disappear from view under the terrain after 20 seconds the last particle has long since disappeared and the frame rate is going quite fast by now, but then suddenly dips to very slow.
  21. I've been messing around with emitters for the last few days, and found what seems to me a couple of strange behaviours. Using the debug Lua build in Leadwerks on steam 3.2. 1) FPS drop. If you pause an emitter, either by not starting it, or using tolua.cast(self.entity,"Emitter"):Pause() in your Script attached to the Particle Emitter (in the Emitter tab - Play and Loop are unticked) before its completed its full pass of particles, the frame rate drops off, I get 4 to 7 frames per second, with 9999 Particles and Duration 18000. When the particles are playing I get 25 to 30 frames per second. If I let the sequence finish I get 70 to 80 fps. 2) I have set up a box, called BigSwitch1, and attached a script, which has a Collision function. Even though I have not begun to play() the emitter, I get certain numbers of collisions reported from the Collision function. These numbers vary depending on the Physics mode and Collision type, I get a fixed number of hits from the non playing emitter. I use this line in the Collision function with in the BigSwitch1.lua script to report the collision. System:Print("Collided with BigSwitch1 was "..entity:GetKeyValue("name")) The Output log shows the hits coming from ParticleEmitter2, which is part of my loaded map. I can get 6 7 or 19 hits reported, these occur as soon as the scene appears on the screen. After that no more collisions are recorded as coming from ParticleEmitter2, but hits from Player do report without problem.
  22. In the documentation for Entity::EmitSound it says a source is automatically created and managed by the entity. Is there a way of controlling the sound so that in the Lua script for the emitter, when I pause and play, I can also pause and play the sound by gaining access to the source that the EmitSound created. I'm not hopeful, as I can't see the sound source in the debugger.
  23. I found the problem with the emitter not displaying in game. This was when I ticked the Shape hint, on the physics tab the emitter no longer displayed in game, but was ok in the editor, but if I unticked it, it was ok in both.
  24. Thanks Rick and macklebee, I am new to Lua, but experienced with C++. No luck with the FindEntity function. I am now trying the Map:Load with the script option, to see if I can access the ParticleEmitter2 I am using steam leadwerks 3.2, not using the beta. Should I switch to the beta?
×
×
  • Create New...