Jump to content

thehankinator

Members
  • Posts

    436
  • Joined

  • Last visited

Everything posted by thehankinator

  1. I had two problems going on. I fixed one of them and now I have narrowed this issue down to Follow(). If I reduce my level to nothing but flat plane, the performance issues go away. What kind of things could be making Follow so expensive?
  2. There is a script Scripts/Objects/Doors/SwingingDoor.lua. Mine was located in the "MyGame" project, it might be in some of the other templates also.
  3. Happy Thanksgiving! Update: *improved fire appearance on fire trap *head shots deal 3x damage *fixed resource leak *synced witch animation/fire anamiation timing *fixed zombie run animation *fixed a bug that caused the witch not to spawn a fireball *fix machete damage Still haven't been able to resolve the performance problem. I'm not crazy about this map so maybe during design of the new map I can catch it. Need to work on sounds and visual feedback for the machete but it does sweeping damage with headshot damage when the sight is pointed at a head.
  4. Have you looked at the top of Main.lua? It has a couple calls like System:GetProperty("screenwidth","1024") That code is attempting to get screenwidth from the command line arguments, if nothing is there default to 1024. You can add whatever arguments to the command line and retrieve the value with System:GetProperty. I am pretty sure this is how the Game Launcher does it. http://www.leadwerks.com/werkspace/page/api-reference/_/system/systemgetproperty-r538
  5. You should take a look at the time api included in Leadwerks. Using lua's time functions would work if implemented correctly however Leadwerks Engine manages how and when the game time is updated, this ensures that your logic is tied to game time rather than system time. You would be mostly interested in Time:GetCurrent(). http://www.leadwerks.com/werkspace/page/api-reference/_/time/
  6. I got a Steam Link, it works really well. Didn't even need to run a cat5 cable to it, streams over wifi like a champ.
  7. Thanks for the advice. In this case though I've disabled all the update functions in my AI script so I don't think it's an AI problem.
  8. I'm having trouble fixing a performance issue in my game (House of Pain). Seems like everything is fine (~60fps) until I spawn an enemy. Then it drops to 30fps. In my AI script I've commented just about everything (UpdateWorld, UpdatePhysics, Draw, etc) so I don't think that is the problem. On the enemy I set Cast Shadows to None. I've played around with the Collapse function on the model but the model is no longer visible when I collapse it. I don't know how to interpret the statistic information that well, I don't think my batches are unreasonable. I don't have any post processing effects (that I am aware of). I've tried disabling all lights except ambient but appeared to make no difference. Does anyone have an idea what else I can look at that would cause such a big hit to performance? Thanks
  9. Update: * Made fireball more fiery * Improved fire looks on torches * Added blood splatter on walls * Reduced line of sight checks in AI scripts For some reason the emitters get to a point where they are "puffing" the particles rather than a steady stream. Not sure if that is due to the performance issue I've been facing or if I'm setting the emitters up wrong. Regardless I think the fire overall looks much better!
  10. This feature would be very helpful in my work flow and from my understanding of the Scintilla documentation could be as easy as a 1 line of code to enable.
  11. This feature would be very helpful in my work flow and from my understanding of the Scintilla documentation could be as easy as a 1 line of code to enable.
  12. I've had this issue since 3.6 although the steps taken below were done with the beta. To reproduce this bug I did the following: 1) Create new map 2) Add camera 3) Click run button Error log output Failed to load texture "C:/Users/TH/Documents/Leadwerks/Projects/THHP/Directional Light" Map file https://drive.google.com/file/d/0B8AlYY49_v2bZ0Mwa05RTzZrUDQ/view?usp=sharing
  13. Update: * Moved the back cam to the top of the screen * Added kickback and shake when a weapon is fired * Fire traps no longer hurt the player I am thinking about adding an additional difficulty flag that would cause all traps to trigger if the player walks over them. Might make things more interesting when choosing where to put a trap. Machete is wonky when swinging at the skeleton, not sure why.
  14. I have this same problem with the beta. It's annoying because it switches the Output tab to Errors tab so every single time I launch my game I have to switch it back to see any debugging messages.
  15. Not sure if this has been reported already or not but when I view my game(The Hankinator's House of Pain) in the Game Launcher I get the below error. When I look at other games they load okay.
  16. Minor update today: * Made the machete more effective. * Increased spawn rate of enemies
  17. Welcome to The Hankinator's House of Pain! This is my entry for the Halloween game tournament. A game of survival, kill enemies to get points, spend points to buy traps and weapons! Survive to the end! Higher difficulty yields more points! At this time standard key bindings are used: WASD - Movement Space - Jump Left mouse - Shoot (or place trap when in at store) R - Reload Get it on Game Launcher! http://www.leadwerks.com/werkspace/page/viewitem?fileid=548835676 This is my first attempt at an action game and also a game that lasts more than a couple minutes. I intended for this game to much more than it is today but I intend on continuing further work. Things like bosses, objectives and maps are a few big features I want to add. What do you think? Which of the many bugs are the most annoying? Fireball texture obtained from: http://opengameart.org/node/18855
  18. I have a script that places traps. I don't want to the player to be able to lay the traps on top of each other so I call ForEachEntityInAABBDo in the space the trap would take, if there isn't anything there I place the trap. The problem I am running into is if I place a trap to the left then another to the right I cannot place one in the center because both the left and right trap are returned by ForEachEntityInAABBDo. If I do a IntersectsAABB check in the ForEachEntityInAABBDo callback I can confirm that the AABBs do NOT intersect. I've verified that the parent for the entities is nil. I've tried calling UpdateAABB (with all the options). Is it possible that there is something special about loading a prefab from a script when it comes to hierarchy and ForEachEntityInAABBDo? Check code: world:ForEachEntityInAABBDo(self.entity:GetAABB(Entity.GlobalAABB), "ArrowWeapCheckPosition", self.entity) Callback: function ArrowWeapCheckPosition(entity, extra) if entity:GetCollisionType() == Collision.Trigger then if entity:GetAABB(Entity.GlobalAABB):IntersectsAABB(extra:GetAABB(Entity.GlobalAABB)) then System:Print("Yep") else System:Print("Nope") end extra.script.valid_position = false return end end Spawn code: local trap = Prefab:Load("Prefabs/Traps/arrow_trap.pfb") trap:SetParent(nil, true) trap:SetPosition(pickinfo.position, true) trap:AlignToVector(pickinfo.normal) trap:UpdateAABB(Entity.LocalAABB + Entity.GlobalAABB + Entity.RecursiveAABB) trap:Show()
  19. I think the point is that if you are new to programming, you should have a firm understanding of the lua interface and 3d graphics before jumping into the Leadwerks C++ code. You can do the vast majority of things a game requires in lua. In my opinion if a beginner needs to do something that is not possible in lua, they are biting off more than they can chew. After spending a few weeks/months working with lua, a programmer will have a much better understanding of Leadwerks to base the changes that would require modifying C++ source. Picking up the basics of the C++ language is probably the easiest part in all that.
  20. I understand. I am not looking to check for the intersection with an individual brush, I want to check if an AABB intersects anything. When calling ForEachEntityInAABBDo, the merged CSG has an AABB that covers the entirety of merged brushes so the AABB I am testing will always intersect the CSG. I am looking for a way to check if an AABB intersects the CSG, not the CSG's AABB.
  21. I am trying to check if an AABB would intersect with the walls of my level. When I call ForEachEntityInAABBDo the CSG always collides with my AABB because the CSG has no script and it's all collapsed into one giant entity with no children (I think). I could add a blank script to every wall in my level, but wouldn't that be(in addition to tedious work) a significant performance hit?. Anyone have a better way of doing this check?
  22. In my code all my calls to SetAnimationSequence the endHook argument does not contain "self." For example your code is self.animationmanager:SetAnimationSequence("attack",0.02,200,1,self,self.stopAttack,30) and mine would be self.animationmanager:SetAnimationSequence("attack",0.02,200,1,self,stopAttack,30) Have you tried this?
  23. Are you seeding the random number generator? Try doing the following line of code before your math.random call. math.randomseed(Time:Millisecs()) self.v = math.random(1,4) I remember seeing a thread talking about how Time:Millisecs() wasn't the best way to get a random number but I can't remember where it was now, should work better than no seed though. os.time would create a problem for Game Launcher so I would avoid it.
  24. I've been playing with it a bit more, if I remove SetInput()/Point() and call Stop() and Follow() continously it doesn't look like they are getting stuck (or stuck as often anyway). There really should be some way to figure out if the course Follow() plotted previously has failed so that it can be replotted. Or is it best practice to continuously plot the course with Follow()? Without some way of profiling Follow() it would seem like NPCs continuously calling Stop()/Follow() is a bad idea for performance.
×
×
  • Create New...