Re: [hlcoders] Hitbox calculation and sizes?
Already try that and it only shows the local hitboxes for me. I mean it displays the proper hitboxes the same way they're displayed in the modelviewer. However these are totally ignored for actual hit detection when I fire on the player. :( Check this screenshot: http://i.imgur.com/KGJ1Kys.jpg Thats with sv_showhitboxes 1. If I fire on the model with another client the bullets go right trough the model until about half the vertical size of it. Or in other words if I fire at the base/lower part I get hits and everything above is ignored. Since the model is pretty large/high I'm guessing that there might be some maximum height value for the hitbox? Or for the collision box? A standard playermodel reaches until about the middle of the cactus. Best regards, Tobias Didrole didr...@gmail.com hat am 1. Juli 2013 um 22:58 geschrieben: Try sv_showhitboxes 2013/7/1 m...@tobiasbaumann.net mailto:m...@tobiasbaumann.net m...@tobiasbaumann.net mailto:m...@tobiasbaumann.net Hi everyone, Does anyone of you know where/how hitboxes for players are being calculated/set in the code and if there is a max value for its size? I'm having troubles where I'm using a larger then average model for the player without any bones and where the engine always uses a smaller (looks like a default sized) hitbox. I've tried setting hitboxes in the qc file and they show up correctly in the modelviewer yet in the game they're not being used. Any ideas why? Also is there a way to display/debug hitboxes for other players? Thanks in advance and have a nice day, Tobias ___ To unsubscribe, edit your list preferences, or view the list archives, please visit: https://list.valvesoftware.com/cgi-bin/mailman/listinfo/hlcoders https://list.valvesoftware.com/cgi-bin/mailman/listinfo/hlcoders ___ To unsubscribe, edit your list preferences, or view the list archives, please visit: https://list.valvesoftware.com/cgi-bin/mailman/listinfo/hlcoders
[hlcoders] Hitbox calculation and sizes?
Hi everyone, Does anyone of you know where/how hitboxes for players are being calculated/set in the code and if there is a max value for its size? I'm having troubles where I'm using a larger then average model for the player without any bones and where the engine always uses a smaller (looks like a default sized) hitbox. I've tried setting hitboxes in the qc file and they show up correctly in the modelviewer yet in the game they're not being used. Any ideas why? Also is there a way to display/debug hitboxes for other players? Thanks in advance and have a nice day, Tobias ___ To unsubscribe, edit your list preferences, or view the list archives, please visit: https://list.valvesoftware.com/cgi-bin/mailman/listinfo/hlcoders
Re: [hlcoders] Help! Where's my reloading animation?
Thanks for your help. We're using the orange box version (source 2007). This whole networking stuff is pretty new to me so I try to understand it by looking at how the other weapons are programmed. Here's why this confuses me as I can't find a difference between how the animation is called compared to other animations or other weapon scripts. I tried to follow the whole thing and apparently CHL2MPPlayerAnimState::DoAnimationEvent never gets told to do the animation. Additionally the function: bool CWeaponBook::Reload( void ) gets only called on the server in: CWeaponBook::ItemPostFrame This makes fits as DoAnimationEvent never gets told to do an animation on the client. Now here is whats confusing me. In the same function CWeaponBook::ItemPostFrame we have another call thats written the same way but this time its inside a switch statement: switch( m_AttackPaused ) m_AttackPaused is a CNetworkVar so I figured ok, lets try and code a new CNetworkVar and write an if statement for it so the reload animation only gets called when needed. And voila it worked! So while I think I understand this I still have one last question: Is this update/linking on all clients whenever we use a CNetworkVar something Valve has written or is this something C++ does on its own? I mean its pretty convenient but it confused the hell out of my because it wasn't coded explicitly (or instantly visible for that matter). :) Cheers, Tobias Psy_Commando psycomma...@gmail.com hat am 5. Juni 2013 um 06:50 geschrieben: I might be wrong, but my guess is that by not sending a message and instead calling directly the message associated method, you're leaving the client unaware that it should play that anim. Though its been a while since I played with that. Are you using Alien swarm or the orange box ? On Tue, Jun 4, 2013 at 9:57 AM, m...@tobiasbaumann.net mailto:m...@tobiasbaumann.net m...@tobiasbaumann.net mailto:m...@tobiasbaumann.net wrote: Hi everyone, I've been trying to solve a very simple problem in the past days and I'm hoping someone of you can help me. So I've created a new weapon based upon the Frag grenade code. Its basically the same thus far with a few changes. So far it works as intended except there is no reload animation on the player model even tough I'm telling the game to play one. My character model has the reload animation and it works when I try it in the modelviewer. However when I use this line in the code: ToHL2MPPlayer(GetOwner())-DoAnimationEvent( PLAYERANIMEVENT_RELOAD ); Which is getting called in the reload function nothing happens. My first guess was that maybe another animation cancels out this animation so I tried to see whats going on by using anim_showstate in the console and I noticed that only the server is doing a layered animation of the reload animation. Which is correct I'm assuming because we also want walking/crouching happening while reloading. Now here's my question: Why is the animation only executed in the server? Am I missing some reference or did I forgot a sequence inside the the qc file? (I've got my acttable_t setup correctly.) I've looked at other weapons code to see how they trigger the reload animation and its the same line of code. What am I missing? Is there some other place in the code that handles reloading depending on what weapon the player has equipped? I'm asking because I noticed the default frag grenade doesn't have a reload animation as well. Viewmodel animations are working correctly tough. Thank you for any help on this. Best regards, Tobias ___ To unsubscribe, edit your list preferences, or view the list archives, please visit: https://list.valvesoftware.com/cgi-bin/mailman/listinfo/hlcoders https://list.valvesoftware.com/cgi-bin/mailman/listinfo/hlcoders ___ To unsubscribe, edit your list preferences, or view the list archives, please visit: https://list.valvesoftware.com/cgi-bin/mailman/listinfo/hlcoders
[hlcoders] Help! Where's my reloading animation?
Hi everyone, I've been trying to solve a very simple problem in the past days and I'm hoping someone of you can help me. So I've created a new weapon based upon the Frag grenade code. Its basically the same thus far with a few changes. So far it works as intended except there is no reload animation on the player model even tough I'm telling the game to play one. My character model has the reload animation and it works when I try it in the modelviewer. However when I use this line in the code: ToHL2MPPlayer(GetOwner())-DoAnimationEvent( PLAYERANIMEVENT_RELOAD ); Which is getting called in the reload function nothing happens. My first guess was that maybe another animation cancels out this animation so I tried to see whats going on by using anim_showstate in the console and I noticed that only the server is doing a layered animation of the reload animation. Which is correct I'm assuming because we also want walking/crouching happening while reloading. Now here's my question: Why is the animation only executed in the server? Am I missing some reference or did I forgot a sequence inside the the qc file? (I've got my acttable_t setup correctly.) I've looked at other weapons code to see how they trigger the reload animation and its the same line of code. What am I missing? Is there some other place in the code that handles reloading depending on what weapon the player has equipped? I'm asking because I noticed the default frag grenade doesn't have a reload animation as well. Viewmodel animations are working correctly tough. Thank you for any help on this. Best regards, Tobias ___ To unsubscribe, edit your list preferences, or view the list archives, please visit: https://list.valvesoftware.com/cgi-bin/mailman/listinfo/hlcoders
Re: [hlcoders] Issues with player entity rotation
Thanks a lot everyone. We solved it! :) Here's how in case someone else runs into the same problem. The problem was that if we started the game with a prop model the function SetupPoseParameters failed because the model doesn't have any poses. Interestingly the function ComputePoseParam_AimYaw seems to have fallback which simply used for the case that the model doesn't have any poses. :) Thanks again and have a good week. Tobias Ryan Kistner azuisl...@gmail.com hat am 24. März 2013 um 21:54 geschrieben: You likely need to take a look at the animation system. If the player's model is not a player rig, then it won't have all the pose parameters the animation code likes to do calculations on. Check out the logic m_bForceAimYaw does in PlayerAnimState. On Sunday, March 24, 2013 12:01:55 PM, m...@tobiasbaumann.net wrote: Thank you :) And no it isn't. Its the same result with any other mdl except if we use a proper player model. Does this have something to do with the fact that prop models don't have any bones? We're also doing a switch to thirdperson on Team change. Not sure if this might be relevant. Best regards, Tobias Michael Zehnich twincan...@gmail.com hat am 24. März 2013 um 16:27 geschrieben: Is the model compiled with $staticprop? That can cause them to stop responding to stuff like that via code in my experience. Also Suicide Survival is a lot of fun. :) On Sun, Mar 24, 2013 at 10:42 AM, Roman Schmid bummz...@gmail.com mailto:bummz...@gmail.com wrote: Hello HL coders We're working on a Source SDK 2007 mod (called Suicide Survival) and came across a problem we're unable to solve. We have a player entity, that refuses to rotate into the direction the player is looking. Interestingly enough, when we switch the entity to another .mdl file (one from the source SDK), it works fine. That lead us to the conclusion, that something might be wrong with our .mdl file... however, if the player changes team (and gets another .mdl file assigned) and then switches team again (to get the troubelsome .mdl assigned), it works fine, even with the .mdl that previously didn't work. So we're kinda baffled there and would appreciate some hints what might be the cause for this? Thanks in advance and best regards Roman ___ To unsubscribe, edit your list preferences, or view the list archives, please visit: https://list.valvesoftware.com/cgi-bin/mailman/listinfo/hlcoders ___ To unsubscribe, edit your list preferences, or view the list archives, please visit: https://list.valvesoftware.com/cgi-bin/mailman/listinfo/hlcoders ___ To unsubscribe, edit your list preferences, or view the list archives, please visit: https://list.valvesoftware.com/cgi-bin/mailman/listinfo/hlcoders ___ To unsubscribe, edit your list preferences, or view the list archives, please visit: https://list.valvesoftware.com/cgi-bin/mailman/listinfo/hlcoders ___ To unsubscribe, edit your list preferences, or view the list archives, please visit: https://list.valvesoftware.com/cgi-bin/mailman/listinfo/hlcoders
Re: [hlcoders] Issues with player entity rotation
Thank you :) And no it isn't. Its the same result with any other mdl except if we use a proper player model. Does this have something to do with the fact that prop models don't have any bones? We're also doing a switch to thirdperson on Team change. Not sure if this might be relevant. Best regards, Tobias Michael Zehnich twincan...@gmail.com hat am 24. März 2013 um 16:27 geschrieben: Is the model compiled with $staticprop? That can cause them to stop responding to stuff like that via code in my experience. Also Suicide Survival is a lot of fun. :) On Sun, Mar 24, 2013 at 10:42 AM, Roman Schmid bummz...@gmail.com mailto:bummz...@gmail.com wrote: Hello HL coders We're working on a Source SDK 2007 mod (called Suicide Survival) and came across a problem we're unable to solve. We have a player entity, that refuses to rotate into the direction the player is looking. Interestingly enough, when we switch the entity to another .mdl file (one from the source SDK), it works fine. That lead us to the conclusion, that something might be wrong with our .mdl file... however, if the player changes team (and gets another .mdl file assigned) and then switches team again (to get the troubelsome .mdl assigned), it works fine, even with the .mdl that previously didn't work. So we're kinda baffled there and would appreciate some hints what might be the cause for this? Thanks in advance and best regards Roman ___ To unsubscribe, edit your list preferences, or view the list archives, please visit: https://list.valvesoftware.com/cgi-bin/mailman/listinfo/hlcoders https://list.valvesoftware.com/cgi-bin/mailman/listinfo/hlcoders ___ To unsubscribe, edit your list preferences, or view the list archives, please visit: https://list.valvesoftware.com/cgi-bin/mailman/listinfo/hlcoders ___ To unsubscribe, edit your list preferences, or view the list archives, please visit: https://list.valvesoftware.com/cgi-bin/mailman/listinfo/hlcoders
Re: [hlcoders] Help! How to change the $origin of a model without access to the QC file?
Hi, The problem is that I'm trying to do this with models which I can not recompile. Like every hl2 prop model. I've tried changing the player hull which gives me different collisions but the actual model is still positioned by 50% into the ground. Do you know where the height value is rehandled or how the boundary box data is calculated? I mean this seems so simply to me yet I can seem to get it to work. Thank you, Tobias RedEyes Fuzz fuzzz...@gmail.com hat am 1. September 2012 um 15:36 geschrieben: hello did you try to compile your model with the $autocenter command ? https://developer.valvesoftware.com/wiki/$autocenter https://developer.valvesoftware.com/wiki/$autocenter it seem you can create an attachement point and define it to be the origin point of the model. the hull of all prop is build on the boundary box data, if there is no hull definition into the ai_hull.cpp and .h/ files. also you can change the value of the hull, like when the npc/player is crouching, the height value is rehandled by the cod,e to get 50% less on the height axis. //Red Jurassic Life : http://jurassic-life.game-lab.com http://jurassic-life.game-lab.com 2012/8/24 m...@tobiasbaumann.net mailto:m...@tobiasbaumann.net m...@tobiasbaumann.net mailto:m...@tobiasbaumann.net Care to elaborate on where you put that code? Thank you, Tobias edman747 edman...@gmail.com mailto:edman...@gmail.com hat am 24. August 2012 um 02:09 geschrieben: had a similar problem with a model on one map. minhullsize -16.5 -16.5 -37 maxhullsize 16.5 16.5 37 origin -1196 1080 -208 model models/holo.mdl On 8/23/12, m...@tobiasbaumann.net mailto:m...@tobiasbaumann.net m...@tobiasbaumann.net mailto:m...@tobiasbaumann.net wrote: Hi everyone, over the last couple of days I've been trying to fix a problem I'm having. Something I thought would be quite easy to fix but alas as everything in game development turned out to be really complicated. :( So here is what I'm trying to do and what the reason is for it not working. In my Mod the mappers can define a custom player model. This model can basically be anything. Like lets say a couch, a chair or whatever. Now this works fine but no matter what model it gets positioned into the ground by half its height. Now I did some research and I think this is because the collision boundary of the player gets calculated using the $origin value defined in the QC file when compiling the model. Now this is fine for player models where the origin is at the bottom. But what I found out is that most other props have their $origin centered in the middle of the model. Which explains the offset by 50% of the height. Am I correct with this assumption? What I tried to was change the predefined player hull values in HL2MPViewVectors g_HL2MPViewVectors but this had an effect on viewports and player collisions but none on the actual positioning of the model in the world. I've also tried to modify the origin values using SetLocalOrigin. But again this didn't seem to have any effect whatsoever. Could anyone of you more experienced developers help me out here? How can I set an offset to the model before its collisions boxes get compiled? Is it even possible to change the $origin value before it gets accessed everywhere else in the code? Is that value even accessed or do I have to approach this some other way? Thank you for any light on this and best regards, Tobias ___ To unsubscribe, edit your list preferences, or view the list archives, please visit: https://list.valvesoftware.com/cgi-bin/mailman/listinfo/hlcoders https://list.valvesoftware.com/cgi-bin/mailman/listinfo/hlcoders ___ To unsubscribe, edit your list preferences, or view the list archives, please visit: https://list.valvesoftware.com/cgi-bin/mailman/listinfo/hlcoders
Re: [hlcoders] Help! How to change the $origin of a model without access to the QC file?
I don't want to use a third-party tool to do this. I want to change the actual game code so it'll always work. Best regards, Tobias edman747 edman...@gmail.com hat am 25. August 2012 um 05:49 geschrieben: I put that in the entity file for the map. Then used ripent -import the entity classname monster_generic On 8/24/12, m...@tobiasbaumann.net m...@tobiasbaumann.net wrote: Care to elaborate on where you put that code? Thank you, Tobias edman747 edman...@gmail.com hat am 24. August 2012 um 02:09 geschrieben: had a similar problem with a model on one map. minhullsize -16.5 -16.5 -37 maxhullsize 16.5 16.5 37 origin -1196 1080 -208 model models/holo.mdl On 8/23/12, m...@tobiasbaumann.net m...@tobiasbaumann.net wrote: Hi everyone, over the last couple of days I've been trying to fix a problem I'm having. Something I thought would be quite easy to fix but alas as everything in game development turned out to be really complicated. :( So here is what I'm trying to do and what the reason is for it not working. In my Mod the mappers can define a custom player model. This model can basically be anything. Like lets say a couch, a chair or whatever. Now this works fine but no matter what model it gets positioned into the ground by half its height. Now I did some research and I think this is because the collision boundary of the player gets calculated using the $origin value defined in the QC file when compiling the model. Now this is fine for player models where the origin is at the bottom. But what I found out is that most other props have their $origin centered in the middle of the model. Which explains the offset by 50% of the height. Am I correct with this assumption? What I tried to was change the predefined player hull values in HL2MPViewVectors g_HL2MPViewVectors but this had an effect on viewports and player collisions but none on the actual positioning of the model in the world. I've also tried to modify the origin values using SetLocalOrigin. But again this didn't seem to have any effect whatsoever. Could anyone of you more experienced developers help me out here? How can I set an offset to the model before its collisions boxes get compiled? Is it even possible to change the $origin value before it gets accessed everywhere else in the code? Is that value even accessed or do I have to approach this some other way? Thank you for any light on this and best regards, Tobias___ To unsubscribe, edit your list preferences, or view the list archives, please visit: https://list.valvesoftware.com/cgi-bin/mailman/listinfo/hlcoders
Re: [hlcoders] Help! How to change the $origin of a model without access to the QC file?
Ok that worked. Thank you! :) I'm assuming I can ignore the part inside: CViewVectors g_DefaultViewVectors in the file: shared/gamerules.cpp I made my changes in: HL2MPViewVectors g_HL2MPViewVectors in the file: shared/hl2mp/hl2mp_gamerules.cpp and it worked but I'm still a bit confused as to why it shows up twice in the solution. I'm assuming the hl2mp definition overwrites the other one? Now where would I put a code to do this fix only on certain models? Can I even change this value after it's been defined/initialized? Thanks again and best regards, Tobias Tony \omega\ Sergi omegal...@gmail.com hat am 8. Oktober 2012 um 15:39 geschrieben: change the hull so that the bounding box's min.z isn't 0.. ie: like goldsrc. -16 -16 -32 16 16 32 or whatever. I can't remember the size, but that will make the origin of the player in the middle instead of at the bottom (feet). -Tony On Mon, Oct 8, 2012 at 10:34 PM, m...@tobiasbaumann.net mailto:m...@tobiasbaumann.net m...@tobiasbaumann.net mailto:m...@tobiasbaumann.net wrote: I don't want to use a third-party tool to do this. I want to change the actual game code so it'll always work. Best regards, Tobias edman747 edman...@gmail.com mailto:edman...@gmail.com hat am 25. August 2012 um 05:49 geschrieben: I put that in the entity file for the map. Then used ripent -import the entity classname monster_generic On 8/24/12, m...@tobiasbaumann.net mailto:m...@tobiasbaumann.net m...@tobiasbaumann.net mailto:m...@tobiasbaumann.net wrote: Care to elaborate on where you put that code? Thank you, Tobias edman747 edman...@gmail.com mailto:edman...@gmail.com hat am 24. August 2012 um 02:09 geschrieben: had a similar problem with a model on one map. minhullsize -16.5 -16.5 -37 maxhullsize 16.5 16.5 37 origin -1196 1080 -208 model models/holo.mdl On 8/23/12, m...@tobiasbaumann.net mailto:m...@tobiasbaumann.net m...@tobiasbaumann.net mailto:m...@tobiasbaumann.net wrote: Hi everyone, over the last couple of days I've been trying to fix a problem I'm having. Something I thought would be quite easy to fix but alas as everything in game development turned out to be really complicated. :( So here is what I'm trying to do and what the reason is for it not working. In my Mod the mappers can define a custom player model. This model can basically be anything. Like lets say a couch, a chair or whatever. Now this works fine but no matter what model it gets positioned into the ground by half its height. Now I did some research and I think this is because the collision boundary of the player gets calculated using the $origin value defined in the QC file when compiling the model. Now this is fine for player models where the origin is at the bottom. But what I found out is that most other props have their $origin centered in the middle of the model. Which explains the offset by 50% of the height. Am I correct with this assumption? What I tried to was change the predefined player hull values in HL2MPViewVectors g_HL2MPViewVectors but this had an effect on viewports and player collisions but none on the actual positioning of the model in the world. I've also tried to modify the origin values using SetLocalOrigin. But again this didn't seem to have any effect whatsoever. Could anyone of you more experienced developers help me out here? How can I set an offset to the model before its collisions boxes get compiled? Is it even possible to change the $origin value before it gets accessed everywhere else in the code? Is that value even accessed or do I have to approach this some other way? Thank you for any light on this and best regards, Tobias ___ To unsubscribe, edit your list preferences, or view the list archives, please visit: https://list.valvesoftware.com/cgi-bin/mailman/listinfo/hlcoders https://list.valvesoftware.com/cgi-bin/mailman/listinfo/hlcoders -- -Tony ___ To unsubscribe, edit your list preferences, or view the list archives, please visit: https://list.valvesoftware.com/cgi-bin/mailman/listinfo/hlcoders
Re: [hlcoders] Help! How to change the $origin of a model without access to the QC file?
Care to elaborate on where you put that code? Thank you, Tobias edman747 edman...@gmail.com hat am 24. August 2012 um 02:09 geschrieben: had a similar problem with a model on one map. minhullsize -16.5 -16.5 -37 maxhullsize 16.5 16.5 37 origin -1196 1080 -208 model models/holo.mdl On 8/23/12, m...@tobiasbaumann.net m...@tobiasbaumann.net wrote: Hi everyone, over the last couple of days I've been trying to fix a problem I'm having. Something I thought would be quite easy to fix but alas as everything in game development turned out to be really complicated. :( So here is what I'm trying to do and what the reason is for it not working. In my Mod the mappers can define a custom player model. This model can basically be anything. Like lets say a couch, a chair or whatever. Now this works fine but no matter what model it gets positioned into the ground by half its height. Now I did some research and I think this is because the collision boundary of the player gets calculated using the $origin value defined in the QC file when compiling the model. Now this is fine for player models where the origin is at the bottom. But what I found out is that most other props have their $origin centered in the middle of the model. Which explains the offset by 50% of the height. Am I correct with this assumption? What I tried to was change the predefined player hull values in HL2MPViewVectors g_HL2MPViewVectors but this had an effect on viewports and player collisions but none on the actual positioning of the model in the world. I've also tried to modify the origin values using SetLocalOrigin. But again this didn't seem to have any effect whatsoever. Could anyone of you more experienced developers help me out here? How can I set an offset to the model before its collisions boxes get compiled? Is it even possible to change the $origin value before it gets accessed everywhere else in the code? Is that value even accessed or do I have to approach this some other way? Thank you for any light on this and best regards, Tobias___ To unsubscribe, edit your list preferences, or view the list archives, please visit: https://list.valvesoftware.com/cgi-bin/mailman/listinfo/hlcoders
[hlcoders] Help! How to change the $origin of a model without access to the QC file?
Hi everyone, over the last couple of days I've been trying to fix a problem I'm having. Something I thought would be quite easy to fix but alas as everything in game development turned out to be really complicated. :( So here is what I'm trying to do and what the reason is for it not working. In my Mod the mappers can define a custom player model. This model can basically be anything. Like lets say a couch, a chair or whatever. Now this works fine but no matter what model it gets positioned into the ground by half its height. Now I did some research and I think this is because the collision boundary of the player gets calculated using the $origin value defined in the QC file when compiling the model. Now this is fine for player models where the origin is at the bottom. But what I found out is that most other props have their $origin centered in the middle of the model. Which explains the offset by 50% of the height. Am I correct with this assumption? What I tried to was change the predefined player hull values in HL2MPViewVectors g_HL2MPViewVectors but this had an effect on viewports and player collisions but none on the actual positioning of the model in the world. I've also tried to modify the origin values using SetLocalOrigin. But again this didn't seem to have any effect whatsoever. Could anyone of you more experienced developers help me out here? How can I set an offset to the model before its collisions boxes get compiled? Is it even possible to change the $origin value before it gets accessed everywhere else in the code? Is that value even accessed or do I have to approach this some other way? Thank you for any light on this and best regards, Tobias___ To unsubscribe, edit your list preferences, or view the list archives, please visit: https://list.valvesoftware.com/cgi-bin/mailman/listinfo/hlcoders