Re: [hlcoders] Some questions
In Dod's version of CViewRender::RenderPlayerSprites, we iterate over visible teammate players and draw the icons using CMeshBuilder. -Original Message- From: hlcoders-boun...@list.valvesoftware.com [mailto:hlcoders-boun...@list.valvesoftware.com] On Behalf Of AndreaZzZ Sent: Wednesday, December 01, 2010 7:34 AM To: Discussion of Half-Life Programming Subject: [hlcoders] Some questions How to implement a team signs over the heads of the players in DoD:S? Someone tried it? (Example: http://pcmedia.ign.com/pc/image/article/654/654253/day-of-defeat-source-20050927053026844-000.jpg) ___ To unsubscribe, edit your list preferences, or view the list archives, please visit: http://list.valvesoftware.com/mailman/listinfo/hlcoders ___ To unsubscribe, edit your list preferences, or view the list archives, please visit: http://list.valvesoftware.com/mailman/listinfo/hlcoders
Re: [hlcoders] Particles and Muzzle Position on EP1
You're searching for the attachment by name on the player. When it's in thirdperson, you should probably be looking for the attachment on their weapon model. Your loop is crashing because you're not checking that you get a valid client back before calling functions on the pointer. -Original Message- From: hlcoders-boun...@list.valvesoftware.com [mailto:hlcoders-boun...@list.valvesoftware.com] On Behalf Of Russ Canfield Sent: Sunday, March 01, 2009 12:39 PM To: Discussion of Half-Life Programming Subject: [hlcoders] Particles and Muzzle Position on EP1 I am trying to figure out how to fix my particles so that when they emit they show up at the end of the weapon's barrel. Code: CBasePlayer *pPlayer = ToBasePlayer( GetOwner() ); Vector vGunPos; Vector vForward, vRight, vUp; QAngle ClientEyeAngles; ClientEyeAngles = pPlayer-EyeAngles(); AngleVectors( ClientEyeAngles, vForward, vRight, vUp ); m_nBarrelAttachment = pPlayer-LookupAttachment( muzzle ); GetAttachment( m_nBarrelAttachment, vGunPos, ClientEyeAngles ); if (pPlayer-IsDucked()) vGunPos -= (vUp * 10.0f); else vGunPos += (vUp * 7.5f); vGunPos +=(vForward * 28.0f); vGunPos += (vRight * 8.0f); CEffectData data; data.m_flScale = 1.0f; data.m_vOrigin = vGunPos; data.m_vAngles = ClientEyeAngles; data.m_nAttachmentIndex = m_nBarrelAttachment; DispatchEffect( MyEffect, data ); This is fine for the client, but when another user fires their weapon the particles spawn at their feet. I have yet to find a solution, would anyone know why? I am using EP1 engine and the part about checking to see if they are ducked is to compensate for that...since the code doesnt act 100% right... Anyone know what I am doing wrong or not doing at all? If I try to loop like so: Code: for ( int i = 1; i = gpGlobals-maxClients; ++i ) { CHL2MP_Player *pClient = (CHL2MP_Player*) UTIL_PlayerByIndex( i ); m_nBarrelAttachment = pClient-LookupAttachment( muzzle ); GetAttachment( m_nBarrelAttachment, vGunPos, ClientEyeAngles ); } it just crashes when I fire. Anyone ? ___ To unsubscribe, edit your list preferences, or view the list archives, please visit: http://list.valvesoftware.com/mailman/listinfo/hlcoders ___ To unsubscribe, edit your list preferences, or view the list archives, please visit: http://list.valvesoftware.com/mailman/listinfo/hlcoders
RE: [hlcoders] Coded Ironsights
In your view model class, find CalcViewModelView. You can change the eyePosition vector before it gets passed into SetLocalOrigin. ( or passed into the BaseClass if you have a custom view model class ) With that you can get an offset from the weapon and modify its onscreen position however you like. Eg, find a 'raised' and 'lowered' offset vector that you like and store those per weapon, and interpolate between them to fake the animation. I'd recommend making a cvar that contains a vector and shove that in so you can quickly see how its going to look ingame. This would just change the position of the model. If you want to angle the model up or down you would do a similar process but with eyeAngles. I think animating this would be a much better alternative, but if you are without artists then I suppose this is all you get. Matt -Original Message- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On Behalf Of Stephen Swires Sent: Wednesday, October 25, 2006 3:11 PM To: hlcoders@list.valvesoftware.com Subject: [hlcoders] Coded Ironsights Hello, I'm going to put this subject back up because I don't have skills as an animator or modeler to do this with. I want to have a similar system to what SMOD has where it offsets the view model by an angle (of some sort), but I am oblivious on how to do this myself. Any help with doing this will be greatly appreciated. - Stephen Swires (SteveUK) ___ To unsubscribe, edit your list preferences, or view the list archives, please visit: http://list.valvesoftware.com/mailman/listinfo/hlcoders ___ To unsubscribe, edit your list preferences, or view the list archives, please visit: http://list.valvesoftware.com/mailman/listinfo/hlcoders
RE: [hlcoders] Entity Creation (client)
The entity is not created on the client until they are in the same PVS. If it goes out of the pvs afterwards, it become dormant. Matt -Original Message- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On Behalf Of John Sheu Sent: Wednesday, August 02, 2006 8:35 PM To: hlcoders@list.valvesoftware.com Subject: [hlcoders] Entity Creation (client) Suppose that you have an entity created by the server out of the PVS of a particular client. Then does the entity get created also on the client at that time? Or is the creation not done until the entity enters the client PVS? -John Sheu ___ To unsubscribe, edit your list preferences, or view the list archives, please visit: http://list.valvesoftware.com/mailman/listinfo/hlcoders ___ To unsubscribe, edit your list preferences, or view the list archives, please visit: http://list.valvesoftware.com/mailman/listinfo/hlcoders
RE: [hlcoders] TraceRay not hitting player's head
A better way to do this is to increase the size of the surrounding box for the player. You will want to call this in your player spawn function: CollisionProp()-SetSurroundingBoundsType( USE_HITBOXES ); The collision property will then update the absbox whenever the entity's angles, position or animation marks the collision as dirty. Depending on your mod, you may have to mark the collision bounds dirty on the client yourself, when you know the angles or origin of your client entity have changed. You can use ent_absbox on a player to see their server side absbox and cl_ent_absbox to see the client version. With this box surrounding the player, bullet tracelines should hit hitboxes that are outside of the movement bounding box. -Original Message- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On Behalf Of Matt Boone Sent: Monday, June 12, 2006 6:54 PM To: hlcoders@list.valvesoftware.com Subject: RE: [hlcoders] TraceRay not hitting player's head The regular trace will exclude a player as a target if the trace doesn't collide with the bounding box. It is possible to do an additional check on eligible players and force a trace against their hitboxes with enginetrace-ClipRayToEntity. That's per target player, so you can do extra work to make the list of potential players you're tracing against as small as possible. In pseudocode: For all players { if this player is likely to be hit by the ray ( this check can do a DistanceToRay from the traceline and exclude if needed ) { do the enginetrace-ClipRayToEntity now check if we hit the player and the hit was the closest thing that we hit } } -Original Message- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On Behalf Of JG Sent: Monday, June 12, 2006 4:40 PM To: hlcoders@list.valvesoftware.com Subject: Re: [hlcoders] TraceRay not hitting player's head I realize this is an old topic, but I have this same problem and can't find a solution. http://www.sourcemod.net/forums/viewtopic.php?t=3658 As you can see, the bounding box doesn't actually surround the whole model, so there lies the problem.. There's got to be a way to fix this since the traces done when someone fires at someone's head don't just go through the player's head. I just have no clue how to accomplish this. Any help would be greatly appreciated. -- [ Picked text/plain from multipart/alternative ] Good call. Yes, it's for CS:S. On 3/25/06, Aaron Schiff [EMAIL PROTECTED] wrote: -- [ Picked text/plain from multipart/alternative ] Are you using CS:S? coz CS:S models are weird... On 3/24/06, LDuke [EMAIL PROTECTED] wrote: -- [ Picked text/plain from multipart/alternative ] For debugging purposes, in a MP game, I'm drawing a line to the endpoint of the trace. If I aim at a foot, body, hand, etc. the player entity is returned and the line gets drawn to that point. But if I aim at the head, the trace doesn't see the player and it draws the line right through the player's head to whatever is behind him. CTraceFilterHitAll traceFilter; enginetrace-TraceRay(ray, MASK_ALL, traceFilter, tr ); Do I need to change my mask or trace filter I need to use to include the a player's head? Why won't this work? Grant (L. Duke) -- ___ To unsubscribe, edit your list preferences, or view the list archives, please visit: http://list.valvesoftware.com/mailman/listinfo/hlcoders -- ts2do -- ___ To unsubscribe, edit your list preferences, or view the list archives, please visit: http://list.valvesoftware.com/mailman/listinfo/hlcoders -- ___ To unsubscribe, edit your list preferences, or view the list archives, please visit: http://list.valvesoftware.com/mailman/listinfo/hlcoders ___ To unsubscribe, edit your list preferences, or view the list archives, please visit: http://list.valvesoftware.com/mailman/listinfo/hlcoders ___ To unsubscribe, edit your list preferences, or view the list archives, please visit: http://list.valvesoftware.com/mailman/listinfo/hlcoders
RE: [hlcoders] TraceRay not hitting player's head
The regular trace will exclude a player as a target if the trace doesn't collide with the bounding box. It is possible to do an additional check on eligible players and force a trace against their hitboxes with enginetrace-ClipRayToEntity. That's per target player, so you can do extra work to make the list of potential players you're tracing against as small as possible. In pseudocode: For all players { if this player is likely to be hit by the ray ( this check can do a DistanceToRay from the traceline and exclude if needed ) { do the enginetrace-ClipRayToEntity now check if we hit the player and the hit was the closest thing that we hit } } -Original Message- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On Behalf Of JG Sent: Monday, June 12, 2006 4:40 PM To: hlcoders@list.valvesoftware.com Subject: Re: [hlcoders] TraceRay not hitting player's head I realize this is an old topic, but I have this same problem and can't find a solution. http://www.sourcemod.net/forums/viewtopic.php?t=3658 As you can see, the bounding box doesn't actually surround the whole model, so there lies the problem.. There's got to be a way to fix this since the traces done when someone fires at someone's head don't just go through the player's head. I just have no clue how to accomplish this. Any help would be greatly appreciated. -- [ Picked text/plain from multipart/alternative ] Good call. Yes, it's for CS:S. On 3/25/06, Aaron Schiff [EMAIL PROTECTED] wrote: -- [ Picked text/plain from multipart/alternative ] Are you using CS:S? coz CS:S models are weird... On 3/24/06, LDuke [EMAIL PROTECTED] wrote: -- [ Picked text/plain from multipart/alternative ] For debugging purposes, in a MP game, I'm drawing a line to the endpoint of the trace. If I aim at a foot, body, hand, etc. the player entity is returned and the line gets drawn to that point. But if I aim at the head, the trace doesn't see the player and it draws the line right through the player's head to whatever is behind him. CTraceFilterHitAll traceFilter; enginetrace-TraceRay(ray, MASK_ALL, traceFilter, tr ); Do I need to change my mask or trace filter I need to use to include the a player's head? Why won't this work? Grant (L. Duke) -- ___ To unsubscribe, edit your list preferences, or view the list archives, please visit: http://list.valvesoftware.com/mailman/listinfo/hlcoders -- ts2do -- ___ To unsubscribe, edit your list preferences, or view the list archives, please visit: http://list.valvesoftware.com/mailman/listinfo/hlcoders -- ___ To unsubscribe, edit your list preferences, or view the list archives, please visit: http://list.valvesoftware.com/mailman/listinfo/hlcoders ___ To unsubscribe, edit your list preferences, or view the list archives, please visit: http://list.valvesoftware.com/mailman/listinfo/hlcoders
RE: [hlcoders] Recoil Modifications
You should only apply the punch to the view angle when not under prediction. On the client, prediction of frames can occur an arbitrary number of times after the first real frame is processed. You can use: #include prediction.h ... if ( !prediction-InPrediction() ) { // do recoil } To check when you are running in prediction. Matt -Original Message- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On Behalf Of William Ewing Sent: Monday, January 16, 2006 1:59 PM To: hlcoders@list.valvesoftware.com Subject: [hlcoders] Recoil Modifications I have recently been attempting to modify a recoil system to not decay, however I am running into the issue of lag. It is supposed to simply twitch the view by a random amount. Under heavy lag, it does this about 96.38 times, because it is modifying viewangles directly. It seems to be a prediction bug. Any idea as to what may be the problem? -- Will xENO Ewing ___ To unsubscribe, edit your list preferences, or view the list archives, please visit: http://list.valvesoftware.com/mailman/listinfo/hlcoders ___ To unsubscribe, edit your list preferences, or view the list archives, please visit: http://list.valvesoftware.com/mailman/listinfo/hlcoders
[hlcoders] lag compensation optimization
Wanted to share a fix that gave some performance improvements in the latest Dod Source release. bool CDODPlayer::WantsLagCompensationOnEntity( const CBasePlayer *pPlayer, const CUserCmd *pCmd, const CBitVecMAX_EDICTS *pEntityTransmitBits ) const { // No need to lag compensate at all if we're not attacking in this command and // we haven't attacked recently. if ( !( pCmd-buttons IN_ATTACK ) (pCmd-command_number - m_iLastWeaponFireUsercmd 5) ) return false; return BaseClass::WantsLagCompensationOnEntity( pPlayer, pCmd, pEntityTransmitBits ); } Add this to your player class, it will inherit from CBasePlayer::WantsLagCompensation. What this is doing it only performing lag compensation calculations in the frames where a player is shooting or has just shot, as opposed to every frame. I'll try to get this into the next sdk code dump as well as some further lag compensation changes that will fix players getting stuck in each other. Matt ___ To unsubscribe, edit your list preferences, or view the list archives, please visit: http://list.valvesoftware.com/mailman/listinfo/hlcoders
RE: [hlcoders] Reload problem
This is a multi-part message in MIME format. -- [ Picked text/plain from multipart/alternative ] Looks like the combine animation event #define COMBINE_AE_RELOAD ( 2 ) has the same value as the generic animation event AE_NPC_RIGHTFOOT You might have to translate the animation events coming from the combine model into analagous citizen events to get them to do the right thing. From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On Behalf Of Raziel Shaw Sent: Friday, August 12, 2005 9:06 AM To: hlcoders@list.valvesoftware.com Subject: [hlcoders] Reload problem hey I'm trying to get the combine to act as the rebels do. Basicly what I have done is cloned the npc_citizen but changed the model. every thing works as it should but i'm having problems when it comes to them reloading. I've put developer 1 in the console in hope that it would help me track down the problem but the error it gives me when they are reloading is this : Unhandled animation event AE_NPC_RIGHTFOOT for npc_citizen they basicly get stuck and keep reloading. I searched though the code for anything that refers to this and all i can find is this: switch( pEvent-event ) { case CITIZEN_AE_HEAL: // Heal my target (if within range) Heal(); break; case NPC_EVENT_LEFTFOOT: { EmitSound( NPC_Citizen.FootstepLeft, pEvent-eventtime ); } break; case NPC_EVENT_RIGHTFOOT: { EmitSound( NPC_Citizen.FootstepRight, pEvent-eventtime ); } break; I have tryied to comment it out but it makes no difference so i'm kinda stuck on what to do. The last time I had this problem was with Half Life 1 when trying to code friendly marines. All i did that time was stop them from reloading and gave them an infi supply of ammo, problem is i'm not exactly sure how to do it in the hl2 sdk and truthfully i would like them to work properly Cheers for any help in advance Raz ___ To unsubscribe, edit your list preferences, or view the list archives, please visit: http://list.valvesoftware.com/mailman/listinfo/hlcoders -- ___ To unsubscribe, edit your list preferences, or view the list archives, please visit: http://list.valvesoftware.com/mailman/listinfo/hlcoders
RE: [hlcoders] Reload problem
Make that analogous :) -Original Message- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On Behalf Of Matt Boone Sent: Friday, August 12, 2005 2:34 PM To: hlcoders@list.valvesoftware.com Subject: RE: [hlcoders] Reload problem This is a multi-part message in MIME format. -- [ Picked text/plain from multipart/alternative ] Looks like the combine animation event #define COMBINE_AE_RELOAD ( 2 ) has the same value as the generic animation event AE_NPC_RIGHTFOOT You might have to translate the animation events coming from the combine model into analagous citizen events to get them to do the right thing. From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On Behalf Of Raziel Shaw Sent: Friday, August 12, 2005 9:06 AM To: hlcoders@list.valvesoftware.com Subject: [hlcoders] Reload problem hey I'm trying to get the combine to act as the rebels do. Basicly what I have done is cloned the npc_citizen but changed the model. every thing works as it should but i'm having problems when it comes to them reloading. I've put developer 1 in the console in hope that it would help me track down the problem but the error it gives me when they are reloading is this : Unhandled animation event AE_NPC_RIGHTFOOT for npc_citizen they basicly get stuck and keep reloading. I searched though the code for anything that refers to this and all i can find is this: switch( pEvent-event ) { case CITIZEN_AE_HEAL: // Heal my target (if within range) Heal(); break; case NPC_EVENT_LEFTFOOT: { EmitSound( NPC_Citizen.FootstepLeft, pEvent-eventtime ); } break; case NPC_EVENT_RIGHTFOOT: { EmitSound( NPC_Citizen.FootstepRight, pEvent-eventtime ); } break; I have tryied to comment it out but it makes no difference so i'm kinda stuck on what to do. The last time I had this problem was with Half Life 1 when trying to code friendly marines. All i did that time was stop them from reloading and gave them an infi supply of ammo, problem is i'm not exactly sure how to do it in the hl2 sdk and truthfully i would like them to work properly Cheers for any help in advance Raz ___ To unsubscribe, edit your list preferences, or view the list archives, please visit: http://list.valvesoftware.com/mailman/listinfo/hlcoders -- ___ To unsubscribe, edit your list preferences, or view the list archives, please visit: http://list.valvesoftware.com/mailman/listinfo/hlcoders ___ To unsubscribe, edit your list preferences, or view the list archives, please visit: http://list.valvesoftware.com/mailman/listinfo/hlcoders
RE: [hlcoders] HUD Color
This is a multi-part message in MIME format. -- [ Picked text/plain from multipart/alternative ] The colors Normal, Caution etc are referenced in resource/ClientScheme.res. You should change them there. From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On Behalf Of Raziel Shaw Sent: Friday, August 12, 2005 3:11 PM To: hlcoders@list.valvesoftware.com Subject: [hlcoders] HUD Color I know this is gonna b real simple and i'll prolly slap myself for askin a dumb question but.. How do i change the Hud color? In the code i've changed part of it to this: void CHud::InitColors( vgui::IScheme *scheme ) { m_clrNormal = scheme-GetColor( Normal, Color( 60, 60, 230,255 ) ); m_clrCaution = scheme-GetColor( Caution, Color( 20, 20, 255, 255 ) ); m_clrYellowish = scheme-GetColor( Yellowish, Color( 20, 20, 180, 255 ) ); } but it still shows up as yellow. So i looked in the HudLayout.res as i read on a forum that one of the .res files needs editing to allow the color change, but i'm not exactly sure what it is i have to change in there. Cheers in advance Raz ___ To unsubscribe, edit your list preferences, or view the list archives, please visit: http://list.valvesoftware.com/mailman/listinfo/hlcoders -- ___ To unsubscribe, edit your list preferences, or view the list archives, please visit: http://list.valvesoftware.com/mailman/listinfo/hlcoders
RE: [hlcoders] HUD Animations
This is a multi-part message in MIME format. -- [ Picked text/plain from multipart/alternative ] There is quite a lot of documentation for this at the top of hudanimations.txt, but here's a quick example. There are actually a few built in panel animation vars that you can use ( Alpha, FgColor ) that will do the fading for you. You would declare a hud animation like this in your hudanimations.txt file: event MyLabelHide { Animate MyLabel Alpha 0 Linear 0.0 0.5 } In this case, we're animating the Alpha parameter to a value of 0, using Linear interpolation, starting 0.0 seconds from now, and ending 0.5 seconds from now. The documentation at the top of hudanimations.txt describes the different parameters and methods of interpolating. If you wanted to animate something else, say you had a specific colour that you used in your panel, you would declare the member variable that holds the colour with a CPanelAnimationVar like so: CPanelAnimationVar( Color, m_MyColor, MyColor, 255 0 0 0 ); And then you could animate it like any other variable event ChangeColorToBlue { Animate MyLabel MyColor 0 0 255 255 Linear 0.0 0.3 } If you want to animate a size or position, you should check out CPanelAnimationVarAliasType, which you can set up to use proportional floats so they look the same in different resolutions. From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On Behalf Of Kamran Sent: Saturday, July 09, 2005 2:23 PM To: HLCoders Subject: [hlcoders] HUD Animations Alright, my goal: To display a message that is called each time you take damage and then fade it out within 1 second. I created my class, I created the label I want to use to display the message and it works... it updates my label with the damage taken by the user. But it stays there and never goes away... ick. Now, my question is... since this will get called each time you take damage (it uses the Damage message), I'd like it to fade out within a second otherwise it will just stay there for the rest of the game. Do I do that by utilizing the Hud_Animations.txt? And if so, how does that work... I can't find any documentation on it... looking at the DamageIndicator HudElement I see some AnimationVar things but I don't see how it all works... -- Kamran A Get Firefox! Safer, Faster, Better. http://www.spreadfirefox.com/?q=affiliatesid=0t=85 Down with Internet Explorer! Say NO! to Spyware! Use Firefox ___ To unsubscribe, edit your list preferences, or view the list archives, please visit: http://list.valvesoftware.com/mailman/listinfo/hlcoders -- ___ To unsubscribe, edit your list preferences, or view the list archives, please visit: http://list.valvesoftware.com/mailman/listinfo/hlcoders
RE: [hlcoders] networked entity question
If it an entity that is set up to always transmit, it will transmit its state to any connecting client and create the client-side counterpart, and transmit deltas from then on. See the player resource for a good example of this. -Original Message- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On Behalf Of Heritage Sent: Tuesday, May 10, 2005 7:20 PM To: hlcoders@list.valvesoftware.com Subject: [hlcoders] networked entity question Id like to build a networked entity class for my voting structure in my mod. however, one thing is bugging me. I have a global pointer to my main voting entity and i want a corresponding client side counterpart. But i only create this entity once during the lifetime of a server. It has to live outside game rules and the level. So my questing is, when clients connect, how/when does the client side entity get created if at all? ___ To unsubscribe, edit your list preferences, or view the list archives, please visit: http://list.valvesoftware.com/mailman/listinfo/hlcoders ___ To unsubscribe, edit your list preferences, or view the list archives, please visit: http://list.valvesoftware.com/mailman/listinfo/hlcoders
RE: [hlcoders] C_BaseAnimating::DispatchMuzzleEffect
It comes from an animation event. Char *options is the options parameter to the event, and usually holds information about the muzzleflash, eg what style to draw or a scale value. Eg your fire animation might include this event: $sequence fire Fire01 snap fps 30 activity ACT_VM_PRIMARYATTACK 1 { event AE_MUZZLEFLASH 0 357 muzzle } In this case, 357 refers to the type of muzzleflash to draw, and muzzle is a reference to the attachment point name where you want the effect to be created. -Original Message- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On Behalf Of Mike Blowers Sent: Wednesday, May 04, 2005 5:55 AM To: hlcoders@list.valvesoftware.com Subject: [hlcoders] C_BaseAnimating::DispatchMuzzleEffect Can anyone tell me where const char *options comes from ? It is used to set the weaponType to the required muzzleflash, trouble is I've been getting assert errors, I stuck in a DevMsg and the token is not what I expected it to be... To sort this out I really need to know exactly where the token comes from. I almost believe it's from the viewmodel specified in the weapon_.txt file ? Please help Cheers, Mike. ___ To unsubscribe, edit your list preferences, or view the list archives, please visit: http://list.valvesoftware.com/mailman/listinfo/hlcoders ___ To unsubscribe, edit your list preferences, or view the list archives, please visit: http://list.valvesoftware.com/mailman/listinfo/hlcoders
RE: [hlcoders] Resetting touch() on an objective
The touch function will be called continuously for each entity that is touching on every frame. It sounds like you changed the Touch function once the player picks the object up, maybe like this? SetTouch( NULL ); If so you can re-set the touch function when your object is ready to be touched again. SetTouch( CMyObject::MyTouch ); -Original Message- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On Behalf Of British_Bomber Sent: Wednesday, April 27, 2005 10:43 AM To: hlcoders@list.valvesoftware.com Subject: [hlcoders] Resetting touch() on an objective I have an objective, much like a flag in CTF, that the player can pick up and take back to his assigned capture point. I use a VERY simple model entity for this, it simply has Spawn, precache, touch and drop functions. Couldn't be much simpiler. They all work fine, the Touch sees if the toucher is a player then attaches the model to the player. When the player dies, or captures the object it is dropped. That all works fine and dandy, however when someone else goes to pick it up after it has been dropped, or even the same player comes back to grab their beloved suitcase, it will no longer attach itself to them. It's as though the touch function only wants to work once, or has to be stopped. I added an EndTouch, or whatever the exact name is, to the end of my touch function but to no avail. Am I making some kind of fundamental flaw on how the touch function works? Thanks for any help you can offer me ___ To unsubscribe, edit your list preferences, or view the list archives, please visit: http://list.valvesoftware.com/mailman/listinfo/hlcoders ___ To unsubscribe, edit your list preferences, or view the list archives, please visit: http://list.valvesoftware.com/mailman/listinfo/hlcoders
RE: [hlcoders] HitBoxes ?
Do your hitboxes extend outside of the bounding box? -Original Message- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On Behalf Of Jonathan Dance Sent: Wednesday, April 27, 2005 1:04 PM To: hlcoders@list.valvesoftware.com Subject: Re: [hlcoders] HitBoxes ? We are noticing this too. The hitboxes seem like they should work using sv_showhitboxes / sv_showimpacts, but when ducking, the bullets pass right through the hitbox, particularly the head hitbox. Anyone know what the root cause of this is? --JD On Jan 3, 2005, at 3:21 AM, r00t 3:16 wrote: Anyone notice when you run / crouch / jump etc The hit box is off? It seemed to do this is CS:S also and I thought it was a CS:S bug. However it is also doing the same thing in the MP SDK.. Anyone else notice this? r00t 3:16 CQC Gaming www.cqc-gaming.com ___ To unsubscribe, edit your list preferences, or view the list archives, please visit: http://list.valvesoftware.com/mailman/listinfo/hlcoders ___ To unsubscribe, edit your list preferences, or view the list archives, please visit: http://list.valvesoftware.com/mailman/listinfo/hlcoders ___ To unsubscribe, edit your list preferences, or view the list archives, please visit: http://list.valvesoftware.com/mailman/listinfo/hlcoders
RE: [hlcoders] OptionsSubMultiplayer.res
I don't think its possible to add controls to this panel with just a .res file change. You should add your cvar checkbox to the multiplayer advanced dialog, which is scriptable via cfg/settings.scr. -Original Message- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On Behalf Of kingkoozime Sent: Thursday, April 07, 2005 12:43 PM To: hlcoders@list.valvesoftware.com Subject: [hlcoders] OptionsSubMultiplayer.res Anyone have any experience with editing OptionsSubMultiplayer.res? I'd like to add a checkbox to change a convar. All I can see is a field in each object called Command, but I can't find where the commands are defined. -kingk __ Yahoo! Messenger Show us what our next emoticon should look like. Join the fun. http://www.advision.webevents.yahoo.com/emoticontest ___ To unsubscribe, edit your list preferences, or view the list archives, please visit: http://list.valvesoftware.com/mailman/listinfo/hlcoders ___ To unsubscribe, edit your list preferences, or view the list archives, please visit: http://list.valvesoftware.com/mailman/listinfo/hlcoders
RE: [hlcoders] OptionsSubMultiplayer.res
Some lines in gameinfo.txt will show and hide things in the multiplayer advanced page, eg nomodels 0 in the hl2mp gameinfo.txt is what is showing the model selection elements. Looks like the options are: nomodels nohimodel nocrosshair -Original Message- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On Behalf Of Ben Davison Sent: Thursday, April 07, 2005 6:34 PM To: hlcoders@list.valvesoftware.com Subject: Re: [hlcoders] OptionsSubMultiplayer.res Eh, ok scratch that. I created a file called optionssubmultiplayer.res it must of been reading from that. Ok, I extracted from the GCF files and now im going directly into the .res file and delete Model Image and Player Model(IIRC) but for some reason it comes back really small. Even though I have deleted Model Image in the .res file, and when I try to find it again, it's gone :| On Apr 8, 2005 2:21 AM, Ben Davison [EMAIL PROTECTED] wrote: Weird, it lets me delete, add and move everything. On Apr 8, 2005 2:14 AM, Alfred Reynolds [EMAIL PROTECTED] wrote: You shouldn't be editing that file, I bet its having a problem because that file exists entirely inside the steam cache and it can't write to it (we only use steam caches in read only mode). If you extracted that file to disk then it should work, but as I said before tis a hack :) - Alfred -Original Message- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On Behalf Of Ben Davison Sent: Thursday, April 07, 2005 6:05 PM To: hlcoders@list.valvesoftware.com Subject: Re: [hlcoders] OptionsSubMultiplayer.res Alfred (some what offtopic) when I try to modify some of the elements of the multiplayer tab in the HL2DM code, I cannot delete the picture of the player or model selector drop down list using the VGUI editor that's inbuilt into source. Do I have to do some voodoo magic with the ui code? On Apr 8, 2005 1:54 AM, Alfred Reynolds [EMAIL PROTECTED] wrote: No, Mods do not have the ability to add code to the GameUI. There are a couple hacks that will let you change the layout, but they are not recommended. - Alfred -Original Message- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On Behalf Of Jonathan Dance Sent: Thursday, April 07, 2005 4:44 PM To: hlcoders@list.valvesoftware.com Subject: Re: [hlcoders] OptionsSubMultiplayer.res Is it possible to create code-driven UI here? For example, HL2DM and CS:S have model selection and spray support on this tab. How do these work? (I swear I found a document on how to do this once.. maybe it was for HL1...) --JD On Apr 7, 2005, at 4:32 PM, Matt Boone wrote: I don't think its possible to add controls to this panel with just a .res file change. You should add your cvar checkbox to the multiplayer advanced dialog, which is scriptable via cfg/settings.scr. -Original Message- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On Behalf Of kingkoozime Sent: Thursday, April 07, 2005 12:43 PM To: hlcoders@list.valvesoftware.com Subject: [hlcoders] OptionsSubMultiplayer.res Anyone have any experience with editing OptionsSubMultiplayer.res? I'd like to add a checkbox to change a convar. All I can see is a field in each object called Command, but I can't find where the commands are defined. -kingk __ Yahoo! Messenger Show us what our next emoticon should look like. Join the fun. http://www.advision.webevents.yahoo.com/emoticontest ___ To unsubscribe, edit your list preferences, or view the list archives, please visit: http://list.valvesoftware.com/mailman/listinfo/hlcoders ___ To unsubscribe, edit your list preferences, or view the list archives, please visit: http://list.valvesoftware.com/mailman/listinfo/hlcoders ___ To unsubscribe, edit your list preferences, or view the list archives, please visit: http://list.valvesoftware.com/mailman/listinfo/hlcoders ___ To unsubscribe, edit your list preferences, or view the list archives, please visit: http://list.valvesoftware.com/mailman/listinfo/hlcoders -- - Ben Davison - http://www.shadow-phoenix.com ___ To unsubscribe, edit your list preferences, or view the list archives, please visit: http://list.valvesoftware.com/mailman/listinfo/hlcoders ___ To unsubscribe, edit your list preferences, or view the list archives, please visit: http://list.valvesoftware.com/mailman/listinfo/hlcoders -- - Ben Davison - http
[hlcoders] Respawn Bug fix
I've seen this particular bug in a few mods now, thought I would send out a snippet for you guys until it can be sent out in the next SDK update. The problem shows up as players not respawning properly, seeming to fail the teleport call. What's actually happening is the lag compensation manager is teleporting them to their previous location for a lag compensation check, then failing to restore them. If you think you have this problem in your mod, give this change a try. dlls\Player_lagcompensation.cpp ~ line 351 Change the while loop to look like this: // store our previous origin - to start with it is our current location Vector prevOrg = pPlayer-GetLocalOrigin(); // Walk context looking for any invalidating event while( track-IsValidIndex(curr) ) { // remember last record prevRecord = record; // get next record record = track-Element( curr ); if ( !(record-m_fFlags LC_ALIVE) ) { // player most be alive, lost track return; } Vector delta = record-m_vecOrigin - prevOrg; if ( delta.LengthSqr() LAG_COMPENSATION_TELEPORTED_DISTANCE_SQR ) { // lost track, too much difference return; } // did we found a context smaller then target time ? if ( record-m_flSimulationTime = flTargetTime ) break; // hurra, stop // store this position for the next time through the loop prevOrg = record-m_vecOrigin; // go one step back curr = track-Next( curr ); } This fixes the distance check not being applied to the first stored position in the lag compensation history. ___ To unsubscribe, edit your list preferences, or view the list archives, please visit: http://list.valvesoftware.com/mailman/listinfo/hlcoders
RE: [hlcoders] spectator eye mode problem AddToFullPack (not related)
To change visibility of an entity to different players, check out CBasePlayer::ShouldTransmit -Original Message- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On Behalf Of Heritage Sent: Tuesday, April 05, 2005 6:36 PM To: hlcoders@list.valvesoftware.com Subject: [hlcoders] spectator eye mode problem AddToFullPack (not related) First question: Everything in EYE mode spectator seems to be working except the view angle is not updating. I think it just sits at 0,0,0. But I can see the weapon and weapon animations just fine and the camera tracks the players movement too. I believe the view angle along with the other eye mode stuff is dealt with client side because the client already receives those numbers (view angle, origin etc..) for all players within sight. I just don't know where this is dealt with in the hl2 sdk. I checked out hltvcamera.cpp but that doest seem to be it. Does any know where the client side spectator stuff is dealt with or if this is really a client side problem at all? Other than that, spectator mode seems to be working normal. Second question, what is the equivalent of AddToFullPack function for hl2? I have some entities in my mod that can only be seen by members of a certain team and more importantly not the others. ___ To unsubscribe, edit your list preferences, or view the list archives, please visit: http://list.valvesoftware.com/mailman/listinfo/hlcoders ___ To unsubscribe, edit your list preferences, or view the list archives, please visit: http://list.valvesoftware.com/mailman/listinfo/hlcoders
RE: [hlcoders] spectator eye mode problem AddToFullPack (not related)
Its ok that the player does not have a move parent. In that case it should fall back to pl.v_angle, which is most likely not networked for other clients to your local client. Dod:S and CS:S base player implement their own overriding EyeAngles function which returns a networked eye angles, m_angEyeAngles. I believe this is already set up and networked in c_sdk_player.cpp if you are using the sdk sample app as your base. -Original Message- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On Behalf Of Heritage Sent: Tuesday, April 05, 2005 7:28 PM To: hlcoders@list.valvesoftware.com Subject: Re: [hlcoders] spectator eye mode problem AddToFullPack (not related) Ok thanks Mr. Boone! I also have been looking into the eye mode stuff looks like at least one problem is in c_baseplayer.cpp line 1171 eyeAngles = target-EyeAngles(); The call the EyeAngles always returns 0,0,0 because there is no MoveParent.. whatever that is inside const QAngle CBasePlayer::EyeAngles( ) in baseplayer_shared.cpp CBaseEntity *pMoveParent = const_castCBasePlayer*(this)-GetMoveParent(); is always NULL. so I'm gonna look into that next. On Apr 5, 2005 6:42 PM, Matt Boone [EMAIL PROTECTED] wrote: To change visibility of an entity to different players, check out CBasePlayer::ShouldTransmit -Original Message- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On Behalf Of Heritage Sent: Tuesday, April 05, 2005 6:36 PM To: hlcoders@list.valvesoftware.com Subject: [hlcoders] spectator eye mode problem AddToFullPack (not related) First question: Everything in EYE mode spectator seems to be working except the view angle is not updating. I think it just sits at 0,0,0. But I can see the weapon and weapon animations just fine and the camera tracks the players movement too. I believe the view angle along with the other eye mode stuff is dealt with client side because the client already receives those numbers (view angle, origin etc..) for all players within sight. I just don't know where this is dealt with in the hl2 sdk. I checked out hltvcamera.cpp but that doest seem to be it. Does any know where the client side spectator stuff is dealt with or if this is really a client side problem at all? Other than that, spectator mode seems to be working normal. Second question, what is the equivalent of AddToFullPack function for hl2? I have some entities in my mod that can only be seen by members of a certain team and more importantly not the others. ___ To unsubscribe, edit your list preferences, or view the list archives, please visit: http://list.valvesoftware.com/mailman/listinfo/hlcoders ___ To unsubscribe, edit your list preferences, or view the list archives, please visit: http://list.valvesoftware.com/mailman/listinfo/hlcoders ___ To unsubscribe, edit your list preferences, or view the list archives, please visit: http://list.valvesoftware.com/mailman/listinfo/hlcoders ___ To unsubscribe, edit your list preferences, or view the list archives, please visit: http://list.valvesoftware.com/mailman/listinfo/hlcoders
RE: [hlcoders] Need help with custom fonts please
Make sure newfont is the actual name of the font, which is possibly different from the font's filename. Also remove the space from the newfont entry. -Original Message- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On Behalf Of Heritage Sent: Tuesday, March 22, 2005 3:35 PM To: hlcoders@list.valvesoftware.com Subject: [hlcoders] Need help with custom fonts please So I made my own font, put it my mod's resource folder, edited ClientScheme.res and nothing works. I'm having lots of trouble with the redundant unnecessary scripting stuff. Here is my virtual font I scripted HudText { 1 { name newfont tall 32 weight0 antialias 1 additive 1 custom3 } } The reason I had to make this thing is because halflife hud font doest have letters and I wanted to add a letter or two into my hud without changing the hl2 font. So I made my new font called newfont which is just the hl2 font with the letters I needed which replaces some of those weapon symbols, then I added what would appear to be like the correct stuff at the bottom of the ClientScheme.res file CustomFontFiles { 1 resource/HALFLIFE2.ttf 1 resource/HL2MP.ttf 2 resource/HL2crosshairs.ttf 3 resource/newfont.ttf } Now, I am probably missing something somewhere, but before I extract every script file from the .GCF pack and do a massive search for text in files to compare what I may be or may not be missing, I figured I would just ask here because im becoming very frustrating with these scripts. I don't even like scripts. I'm going to have to figure out a way to unscripted most everything because I don't want the server admins changing the weapon values etc.. etc.. or the clients messing up their gui/huds. Anyway, if someone could tell me how to add a new font, I would appreciate it. And lets not even talk about compiling VTF files because I'll blow up! I really hate TGA files, can't we just got back to bitmaps and sprites, what the hell is a shader, lol. I'm going to start needing hl2-sdk antidepressant pills. ___ To unsubscribe, edit your list preferences, or view the list archives, please visit: http://list.valvesoftware.com/mailman/listinfo/hlcoders ___ To unsubscribe, edit your list preferences, or view the list archives, please visit: http://list.valvesoftware.com/mailman/listinfo/hlcoders
RE: [hlcoders] improper vgui behavior
You should check out the hud animation system, this allows you to start changes in colour or size that will run in the background for you. You can also animate the alpha or size to simulate your panels disappearing. As far as setting them not visible and them not disappearing, they shouldn't be doing that. Try dropping a breakpoint in the SetVisible function for your panel and see if its being called from somewhere else? -Original Message- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On Behalf Of Heritage Sent: Wednesday, March 16, 2005 6:22 PM To: hlcoders@list.valvesoftware.com Subject: [hlcoders] improper vgui behavior I had many problems with the hl1 vgui where fonts and schemes seems ignore all changes I made to them. As it turned out, much of it was hardcoded. HL2 seems more robust, but im having a hard time understanding how it works? Im trying to make a new hudelement. So far I have my gui working and displaying numbers with animations, but its not so elegant. I can't turn off and off my gui! It seems like I should just called either SetEnabled or SetVisible but neither of these functions works consistently. I tried called both during the init of my gui, but they never turned my gui off. I then tried calling them in a message, but they did not turn the gui off. I then said ok, lets set them to false in OnThink(). That seemed to work, so i figured i had made some progress. Then I tried to turn them back on, in onThink but they would not behave. It would seem like there is a magical time slice in which vgui messages respond? I know that can not be true so what the hell is going on? I had similar difficulty with the colors. I was not able to change them expect in the think function. Changing the Color each frame retarded and slow. Somewhere they are being overwritten back to whatever the default is. Normally, I would give it some more time before posting for help, but I dont have a super computer. Hl takes quiet a while to load and even longer to compile. I can not waste time with miniscule functions like SetVisable that don't work. ___ To unsubscribe, edit your list preferences, or view the list archives, please visit: http://list.valvesoftware.com/mailman/listinfo/hlcoders ___ To unsubscribe, edit your list preferences, or view the list archives, please visit: http://list.valvesoftware.com/mailman/listinfo/hlcoders
RE: [hlcoders] Resetting entites on round restart.
Cs and dod both destroy the entities and re-create them from scratch on round restart. We also maintain a list of entities that should not be destroyed on a round restart ( player, lights etc ). -Original Message- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On Behalf Of Ben Davison Sent: Thursday, February 24, 2005 3:35 PM To: hlcoders@list.valvesoftware.com Subject: Re: [hlcoders] Resetting entites on round restart. I belive mapenties.h is a start, but I would like to hear frm people who have already done it or done work on it. I'm having a hard time getting my head around it. On Thu, 24 Feb 2005 15:19:04 -0800, Stephen Micheals [EMAIL PROTECTED] wrote: Im also interested on how to do this. ___ To unsubscribe, edit your list preferences, or view the list archives, please visit: http://list.valvesoftware.com/mailman/listinfo/hlcoders -- - Ben Davison - http://www.shadow-phoenix.com ___ To unsubscribe, edit your list preferences, or view the list archives, please visit: http://list.valvesoftware.com/mailman/listinfo/hlcoders ___ To unsubscribe, edit your list preferences, or view the list archives, please visit: http://list.valvesoftware.com/mailman/listinfo/hlcoders
RE: [hlcoders] Re: HL2DM SDK in January or February??
Does the pose parameter you are using in the animation code match the pose parameter in the model? -Original Message- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On Behalf Of Jose Luis Gonzalez Sent: Tuesday, January 18, 2005 1:22 PM To: hlcoders@list.valvesoftware.com Subject: [hlcoders] Re: HL2DM SDK in January or February?? This is a multi-part message in MIME format. -- [ Picked text/plain from multipart/alternative ] I want the HL2DM SDK because my mod plans are a little modifications in DM. But also I wanted to learn more and more with the basics things like create HUDS, gamerules, etc. So I'm learning too. So I repeat my question: Alfred, the area I asked you about HL2DM body_pitch?. Do you have any idea About it?. I want only help in this specific area. I changed the Leg anims to 8 WAYS, and all of the animations of HL2DM works, But only body_pitch don't work. What can I do? (I changed body_pitch to Aim_pitch), but don't work Thanks all. -- ___ To unsubscribe, edit your list preferences, or view the list archives, please visit: http://list.valvesoftware.com/mailman/listinfo/hlcoders ___ To unsubscribe, edit your list preferences, or view the list archives, please visit: http://list.valvesoftware.com/mailman/listinfo/hlcoders
RE: [hlcoders] RE: HL2DM SDK in January or February? Matt
What happens when you step through it? Does it successfully get the index of the pose parameter? Is the pitch correct? Does SetOuterPoseParameter do the right thing? -Original Message- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On Behalf Of Jose Luis Gonzalez Sent: Tuesday, January 18, 2005 2:10 PM To: hlcoders@list.valvesoftware.com Subject: [hlcoders] RE: HL2DM SDK in January or February? Matt This is a multi-part message in MIME format. -- [ Picked text/plain from multipart/alternative ] I change the pose parameter in this function in base_playeranimstate.cpp, Using HL2DM animations. void CBasePlayerAnimState::ComputePoseParam_BodyPitch() { // Get pitch from v_angle float flPitch = m_flEyePitch; if ( flPitch 180.0f ) { flPitch -= 360.0f; } flPitch = clamp( flPitch, -90, 90 ); // See if we have a blender for pitch int pitch = GetOuter()-LookupPoseParameter( aim_pitch ); if ( pitch 0 ) return; SetOuterPoseParameter( pitch, flPitch ); g_flLastBodyPitch = flPitch; } I changed LookupPoseParameter(body_pitch) with LookupPoseParameter( aim_pitch). But don't work. Can this be a pitch bug in SDK?? -- ___ To unsubscribe, edit your list preferences, or view the list archives, please visit: http://list.valvesoftware.com/mailman/listinfo/hlcoders ___ To unsubscribe, edit your list preferences, or view the list archives, please visit: http://list.valvesoftware.com/mailman/listinfo/hlcoders
RE: [hlcoders] bug on laptops
A fix for this will be released with the next engine update. I'll send code snippets then as well so you can fix any other bindings you're trying to hook in your mod. -Original Message- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On Behalf Of Christensen, Grant Sent: Monday, January 17, 2005 5:21 PM To: hlcoders@list.valvesoftware.com Subject: [hlcoders] bug on laptops Hi, I have a bug that I had originally in my mod, but have noticed I also have it in CS:S. Not sure if it is just my configuration, or an actual bug. Could somebody with a laptop or access to a laptop (valve?) please try to recreate this. If I go into observer mode, say in CS:S, I can press the duck key (for me 'C') but could be anything, to open the bottom menu where I can chose who to spectate etc. Usually you then press the duck key again to close the bottom menu. For me, in my mod, pressing the duck key after the menu is open returns a key code of CODE_KEYPAD_3 or similar (can't remember the exact one). It is the numeric keypad number 3, or on my laptop the Fn L key. So, if I actually press the numeric 3 key instead of the duck key, it closes the menu, whereas pressing duck does nothing. So, duck opens it but does not close it, and numeric keypad 3 closes it but does not open it. For some reason having the bottom menu open causes the duck key to return something different. I am using gameuifuncs-GetVGUI2KeyCodeforBind(duck); to get the code. Can someone else with a laptop try this for me to see if it is just my config? Grant. This E-Mail is intended only for the addressee. Its use is limited to that intended by the author at the time and it is not to be distributed without the author's consent. Unless otherwise stated, the State of Queensland accepts no liability for the contents of this E-Mail except where subsequently confirmed in writing. The opinions expressed in this E-Mail are those of the author and do not necessarily represent the views of the State of Queensland. This E-Mail is confidential and may be subject to a claim of legal privilege. If you have received this E-Mail in error, please notify the author and delete this message immediately. ___ To unsubscribe, edit your list preferences, or view the list archives, please visit: http://list.valvesoftware.com/mailman/listinfo/hlcoders ___ To unsubscribe, edit your list preferences, or view the list archives, please visit: http://list.valvesoftware.com/mailman/listinfo/hlcoders
RE: [hlcoders] Debugging a Linux server?
Also try searching for the answer to life, the universe and everything -Original Message- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On Behalf Of Jeffrey botman Broome Sent: Saturday, January 15, 2005 3:41 PM To: hlcoders@list.valvesoftware.com Subject: Re: [hlcoders] Debugging a Linux server? DOOManiac wrote: Still can't get it working :( [EMAIL PROTECTED] steam]$ gdb srcds_i486 GNU gdb Red Hat Linux (6.1post-1.20040607.43rh) *SNIP* This GDB was configured as i386-redhat-linux-gnu...Using host libthread_db library /lib/tls/libthread_db.so.1. (gdb) set args -console -game espionage -IP jmetcalf.2y.net -port 27017 +map esp_test +maxplayers 10 (gdb) r Starting program: /usr/steam/hlds_l/srcds_i486 -console -game espionage -IP jmetcalf.2y.net -port 27017 +map esp_test +maxplayers 10 warning: Child process unexpectedly missing: No child processes Here's a tip... ANYTIME you see an error message that you don't know what it means, go to this website... www.google.com ...then enter in the error message inside double quotes... Child process unexpectedly missing You will find that the first link that it comes up with, someone has asked that question and the third reply (from Andrew Cagney) has an answer. This link also has some info... https://www.redhat.com/archives/fedora-devel-list/2005-January/msg00104. html Use google my friend. It's the quickest way to find answers to all your questions. For example, what's the meaning of life has about 7,700 answers. :) -- Jeffrey botman Broome ___ To unsubscribe, edit your list preferences, or view the list archives, please visit: http://list.valvesoftware.com/mailman/listinfo/hlcoders ___ To unsubscribe, edit your list preferences, or view the list archives, please visit: http://list.valvesoftware.com/mailman/listinfo/hlcoders
RE: [hlcoders] Player animation ?
HL2DM player animation uses a different system than is in the sdk. Basically you have a list of base sequences, preblended with 9-way aims and 9-way runs - those are the aim animations and are called in game code via activities ( why you see different animation names in combine vs rebels ). Shooting is done by adding the fire animation as a gesture over top of the base sequence. For Dod we're doing a hybird, with the activities on base sequence and fire/reload/hand signal gestures over top, but non-networked like the sdk does it to reduce net traffic. I would recommend moving at least to using activities for your player animations so avoid all the nasty string construction and comparing. As far as your animations only playing the first and last frame, this function doesn't appear to be causing that. I would check with a a different model/sequence to see if it's a problem in your model. -Original Message- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On Behalf Of Patrick Flanagan Sent: Tuesday, January 11, 2005 11:33 AM To: hlcoders@list.valvesoftware.com Subject: [hlcoders] Player animation ? I'm trying to get player animation working with some non-CS models. Specifically, I'd like to get animations working with the models used in HL2DM. I used model viewer to load up the combine models from HL2DM and some of the resistance models from HL2DM. Not only are their animations totally different from CS, they're different from each other. The combine models have different animations than the resistance models. I've been working on converting the animation names in sdk_playeranimstate.cpp to call the animations in combine_solder.mdl, which I think is the one used in HL2DM. I've run into some problems with this though. First off, there's doesn't seem to be any walking or running shooting animations. There are animations like ShootSGs, ShootSGc, ShootSMG1s, ShootSMG1c, etc but there's no walk_upper_mp5 or run_upper_mp5 like in the CS models. There doesn't seem to be any animation to be running and shooting at the same time. Second, the animations seem to only play the first frame and then stop. For example, I changed CalcFireLayerSequence to look like this: int CSDKPlayerAnimState::CalcFireLayerSequence(PlayerAnimEvent_t event) { // Figure out the weapon suffix. CWeaponSDKBase *pWeapon = m_pHelpers-SDKAnim_GetActiveWeapon(); if ( !pWeapon ) return 0; const char *pSuffix = GetWeaponSuffix(); if ( !pSuffix ) return 0; // Don't rely on their weapon here because the player has usually switched to their // pistol or rifle by the time the PLAYERANIMEVENT_THROW_GRENADE message gets to the client. if ( event == PLAYERANIMEVENT_THROW_GRENADE ) { pSuffix = Gren; } switch ( GetCurrentMainSequenceActivity() ) { case ACT_PLAYER_RUN_FIRE: case ACT_RUN: //return CalcSequenceIndex( %s%s, DEFAULT_FIRE_RUN_NAME, pSuffix ); return CalcSequenceIndex( ShootSMG1s ); //FIXME: totally wrong case ACT_PLAYER_WALK_FIRE: case ACT_WALK: //return CalcSequenceIndex( %s%s, DEFAULT_FIRE_WALK_NAME, pSuffix ); return CalcSequenceIndex( ShootSMG1s ); //FIXME: totally wrong case ACT_PLAYER_CROUCH_FIRE: case ACT_CROUCHIDLE: return CalcSequenceIndex( %s%s, DEFAULT_FIRE_CROUCH_NAME, pSuffix ); case ACT_PLAYER_CROUCH_WALK_FIRE: case ACT_RUN_CROUCH: return CalcSequenceIndex( %s%s, DEFAULT_FIRE_CROUCH_WALK_NAME, pSuffix ); default: case ACT_PLAYER_IDLE_FIRE: //return CalcSequenceIndex( %s%s, DEFAULT_FIRE_IDLE_NAME, pSuffix ); return CalcSequenceIndex( ShootSMG1s ); //FIXME: pick the right weapon } } I've set my player model to be combine_soldier. When I spawn in third person and watch my player model, if I run along start shooting it looks like it plays only the first frame or two and then immediately goes back to idle/jittering. If I'm running, it looks even worse since each time I fire it looks like it restarts the ShootSMG1animation but there's no blending between them so it looks all jittery. Has anyone had any luck getting this to work? ___ To unsubscribe, edit your list preferences, or view the list archives, please visit: http://list.valvesoftware.com/mailman/listinfo/hlcoders ___ To unsubscribe, edit your list preferences, or view the list archives, please visit: http://list.valvesoftware.com/mailman/listinfo/hlcoders
RE: [hlcoders] Bone manipulation via code
It would be better to use an animation in the player model and change the rotation of a specific joint with a pose parameter. What effect are you trying to accomplish? Its also easier to get position and angles of a particular bone if you put an attachment point on it and get that. -Original Message- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On Behalf Of Beppo Sent: Friday, January 07, 2005 1:43 PM To: hlcoders@list.valvesoftware.com Subject: [hlcoders] Bone manipulation via code This is a multi-part message in MIME format. -- [ Picked text/plain from multipart/alternative ] Hi, where can I find examples on how to manipulate bones (rotate, move) within a player model from within the codes? Can these manipulations be done using the bones own coordinate system and/or the world coordinates? And the other way around too... how to get a bones position and rotation (own system and world) from any object not just the player model? How to attach and detach objects to/from specific bones via code? Where to find such basic knowledge? Or aren't these 'basic' features the SDK codes do offer? Are there some base classes that define all this (and more) that you should check? thanks and regards, Beppo -- Norbert Bogenrieder aka Beppo Lead Programmer and Project Lead [EMAIL PROTECTED] Sentry Studios - Infiltration [EMAIL PROTECTED] http://www.sentrystudios.net http://infiltration.sentrystudios.net -- ___ To unsubscribe, edit your list preferences, or view the list archives, please visit: http://list.valvesoftware.com/mailman/listinfo/hlcoders ___ To unsubscribe, edit your list preferences, or view the list archives, please visit: http://list.valvesoftware.com/mailman/listinfo/hlcoders
RE: [hlcoders] Bone manipulation via code
An example in the sdk code would be the yaw and pitch pose parameters for making the player model look up/down and to the side. The pose parameters are body_pitch and body_yaw. In base_playeranimstate.cpp: void CBasePlayerAnimState::ComputePoseParam_BodyPitch() { // Get pitch from v_angle float flPitch = m_flEyePitch; if ( flPitch 180.0f ) { flPitch -= 360.0f; } flPitch = clamp( flPitch, -90, 90 ); // See if we have a blender for pitch int pitch = GetOuter()-LookupPoseParameter( body_pitch ); if ( pitch 0 ) return; SetOuterPoseParameter( pitch, flPitch ); g_flLastBodyPitch = flPitch; } .. void CBasePlayerAnimState::SetOuterPoseParameter( int iParam, float flValue ) { GetOuter()-SetPoseParameter( iParam, flValue );// GetOuter() is the player } You can define new pose parameters in the .qc file for your model to control blending between two sequences. See the definitions of body_yaw in the .qc for more info on that. For attachment points, search for GetAttachment. There are a number of ways to get an attachment point's location and angles by name. Most common would be: Vector vecOrigin; Qangle vecAngle; int iAttachmentIndex = pMyModel-LookupAttachment( attachment_name ); pMyModel-GetAttachment( iAttachmentIndex, vecOrigin, vecAngle ); -Original Message- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On Behalf Of Beppo Sent: Friday, January 07, 2005 2:03 PM To: hlcoders@list.valvesoftware.com Subject: Re: [hlcoders] Bone manipulation via code It would be better to use an animation in the player model and change the rotation of a specific joint with a pose parameter. And how to do that? Any examples available within the codes? Its also easier to get position and angles of a particular bone if you put an attachment point on it and get that. And how to get the location and rotation of these attachment points then? :) Reason for all this is that the model has to follow specific movements of ie. your mouse. I guess this can be done with the 'pose parameters' you spoke about. I found some references about the speedometer needle defined by pose parameters. So, how to set such things up and how to access them via code? Any basic tutorials or descriptions about these parts of the SDK out there? thanks, Beppo -- Norbert Bogenrieder aka Beppo Lead Programmer and Project Lead [EMAIL PROTECTED] Sentry Studios - Infiltration [EMAIL PROTECTED] http://www.sentrystudios.net http://infiltration.sentrystudios.net - Original Message - From: Matt Boone [EMAIL PROTECTED] To: hlcoders@list.valvesoftware.com Sent: Friday, January 07, 2005 10:50 PM Subject: RE: [hlcoders] Bone manipulation via code It would be better to use an animation in the player model and change the rotation of a specific joint with a pose parameter. What effect are you trying to accomplish? Its also easier to get position and angles of a particular bone if you put an attachment point on it and get that. -Original Message- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On Behalf Of Beppo Sent: Friday, January 07, 2005 1:43 PM To: hlcoders@list.valvesoftware.com Subject: [hlcoders] Bone manipulation via code This is a multi-part message in MIME format. -- [ Picked text/plain from multipart/alternative ] Hi, where can I find examples on how to manipulate bones (rotate, move) within a player model from within the codes? Can these manipulations be done using the bones own coordinate system and/or the world coordinates? And the other way around too... how to get a bones position and rotation (own system and world) from any object not just the player model? How to attach and detach objects to/from specific bones via code? Where to find such basic knowledge? Or aren't these 'basic' features the SDK codes do offer? Are there some base classes that define all this (and more) that you should check? thanks and regards, Beppo -- Norbert Bogenrieder aka Beppo Lead Programmer and Project Lead [EMAIL PROTECTED] Sentry Studios - Infiltration [EMAIL PROTECTED] http://www.sentrystudios.net http://infiltration.sentrystudios.net -- ___ To unsubscribe, edit your list preferences, or view the list archives, please visit: http://list.valvesoftware.com/mailman/listinfo/hlcoders ___ To unsubscribe, edit your list preferences, or view the list archives, please visit: http://list.valvesoftware.com/mailman/listinfo/hlcoders ___ To unsubscribe, edit your list preferences, or view the list archives, please visit: http://list.valvesoftware.com/mailman/listinfo/hlcoders
RE: [hlcoders] m_fFlags Player Specific
A 32 bit integer would be limited to the values (10) through (131). (20) is not really a useful value, its the same as (11). What you're doing here is taking the value 2 ( 0010 in binary ) and shifting it 0 bits to the left. (20) == 0010 in binary == (11) (21) == 0100 in binary == (12) If you need more flags for your entity, you can create a member variable in the class to handle that and network it from there. In Source you are not limited to the pev structure for things that can be automatically networked. -Original Message- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On Behalf Of r00t 3:16 Sent: Wednesday, January 05, 2005 9:31 PM To: hlcoders@list.valvesoftware.com Subject: Re: [hlcoders] m_fFlags Player Specific I was just getting ready to ask this and you had replied already... Would the engine handle the below so I do not use something that is already #defined? #define FL_RUNNING (20) #define FL_WALKING (21) r00t 3:16 CQC Gaming www.cqc-gaming.com - Original Message - From: Draco [EMAIL PROTECTED] To: hlcoders@list.valvesoftware.com Sent: Thursday, January 06, 2005 12:07 AM Subject: Re: [hlcoders] m_fFlags Player Specific Also, you can reuse values. In my MOD FL_RADARBLIP is the same as FL_IMMUNEWATER, they arenm't used at the same time so it doesn't effect each other. ** Draco Coder for Perfect Dark http://perfectdark.game-mod.net ___ To unsubscribe, edit your list preferences, or view the list archives, please visit: http://list.valvesoftware.com/mailman/listinfo/hlcoders ___ To unsubscribe, edit your list preferences, or view the list archives, please visit: http://list.valvesoftware.com/mailman/listinfo/hlcoders ___ To unsubscribe, edit your list preferences, or view the list archives, please visit: http://list.valvesoftware.com/mailman/listinfo/hlcoders
RE: [hlcoders] Menu Sizing problems
Dimensions that are set in .res files are relative to a 640 by 480 screen, so they will scale to every resolution. -Original Message- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On Behalf Of Gabe Volker Sent: Wednesday, December 08, 2004 5:34 PM To: [EMAIL PROTECTED] Subject: [hlcoders] Menu Sizing problems I followed this tutorial to add the team menu to my mod. http://hl2sdk.wolferix.de/index.php/VGUI I have created all the necessary files and they are being read by the mod. However, if I edit the VGUI menu (TeamMenu.res) with the VGUI Built-In Editor, the values that it saves (while they should be correct) are not the values loaded the next time that I run the mod. For example, my team panel has values for wide and tall of 640 and 480, respectively. However, when I load the mod the menu takes up the entire screen and after activating the VGUI Built-In Editor, it shows that the wide and tall values are 1024x768, respectively. All the elements get resized. If I set wide to 320 or so, the menu occupies about half the screen -- as it should when being set to 640. Can anyone shed any light on this? or have they followed this tutorial successfully without this problem? Greets -Gabe ___ To unsubscribe, edit your list preferences, or view the list archives, please visit: http://list.valvesoftware.com/mailman/listinfo/hlcoders ___ To unsubscribe, edit your list preferences, or view the list archives, please visit: http://list.valvesoftware.com/mailman/listinfo/hlcoders
RE: [hlcoders] Sending a regular text message
// to one player ClientPrint( pPlayer, HUD_PRINTTALK, Hello World\n ); // to all players UTIL_ClientPrintAll( HUD_PRINTTALK, Hello World\n ); Use HUD_PRINTCENTER instead of HUD_PRINTTALK to print to the center of the screen. -Original Message- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On Behalf Of Josh Sent: Monday, December 06, 2004 8:27 AM To: [EMAIL PROTECTED] Subject: [hlcoders] Sending a regular text message This is a multi-part message in MIME format. -- [ Picked text/plain from multipart/alternative ] How do I print a regular text message on a player's screen? Not any of the DIALOG stuff, just a message like if a user typed something in chat? Thanks, Josh -- ___ To unsubscribe, edit your list preferences, or view the list archives, please visit: http://list.valvesoftware.com/mailman/listinfo/hlcoders ___ To unsubscribe, edit your list preferences, or view the list archives, please visit: http://list.valvesoftware.com/mailman/listinfo/hlcoders
RE: [hlcoders] HL2 Dev CPU Requirements
Damn, I missed the day they gave those out. :( -Original Message- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On Behalf Of Jeffrey botman Broome Sent: Thursday, October 21, 2004 3:39 PM To: [EMAIL PROTECTED] Subject: Re: [hlcoders] HL2 Dev CPU Requirements Brian Satertek Irelan wrote: You have to have a widescreen LCD monitor like all the guys at Valve. ...and you have to drive a Ferrari, like all the guys at Valve! ;) -- Jeffrey botman Broome ___ To unsubscribe, edit your list preferences, or view the list archives, please visit: http://list.valvesoftware.com/mailman/listinfo/hlcoders ___ To unsubscribe, edit your list preferences, or view the list archives, please visit: http://list.valvesoftware.com/mailman/listinfo/hlcoders
RE: [hlcoders] Re: Player-specific Hitbox Bug? (Help, Alfred? Help, valve? Reproduction steps included.)
Yup, that's it. -Original Message- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On Behalf Of Hasan Aljudy Sent: Wednesday, August 11, 2004 8:38 PM To: [EMAIL PROTECTED] Subject: Re: [hlcoders] Re: Player-specific Hitbox Bug? (Help, Alfred? Help, valve? Reproduction steps included.) In today's steam update we have: - Improved lag compensation for the player with the last player slot (ie. player 10 on a 10 player server) I guess this is it? On Wed, 11 Aug 2004 10:06:25 -0700, Bud-froggy [EMAIL PROTECTED] wrote: Maybe that is why they keep pushing back the release of HL2. Its just a big cover up because HL is still profitable and they essentially want to run it for all its worth and make as much money as possible before HL2 comes out which they will in turn run into the ground. *passes everyone tin foil hats* Bruce Andrews wrote: And with the VALVe still patching years after Half-Life's release, it's because they can still sell the game (mostly because of counterstrike), patching it still gives them a good profit, whereas most other six year old games are pretty dead... ___ To unsubscribe, edit your list preferences, or view the list archives, please visit: http://list.valvesoftware.com/mailman/listinfo/hlcoders ___ To unsubscribe, edit your list preferences, or view the list archives, please visit: http://list.valvesoftware.com/mailman/listinfo/hlcoders ___ To unsubscribe, edit your list preferences, or view the list archives, please visit: http://list.valvesoftware.com/mailman/listinfo/hlcoders ___ To unsubscribe, edit your list preferences, or view the list archives, please visit: http://list.valvesoftware.com/mailman/listinfo/hlcoders
RE: [hlcoders] DoD pPlayer-v.playerclass
enum { PLAYERCLASS_UNDEFINED = 0, //Allied classes PLAYERCLASS_LIGHTINF_GARAND, PLAYERCLASS_LIGHTINF_CARBINE, PLAYERCLASS_ASSAULT_TOMMY, PLAYERCLASS_ASSAULT_GREASE, PLAYERCLASS_SNIPER, PLAYERCLASS_HEAVYWEAPONS, PLAYERCLASS_MACHINEGUNNER, PLAYERCLASS_BAZOOKA, PLAYERCLASS_MORTAR, //Axis classes PLAYERCLASS_LEICHTINF_KAR, PLAYERCLASS_LIECHTINF_K43, PLAYERCLASS_STURMTRUP, PLAYERCLASS_HEAVYWEAPONSGER, PLAYERCLASS_GERMANSNIPER, PLAYERCLASS_FG42_BIPOD, PLAYERCLASS_FG42_SCOPE, PLAYERCLASS_MG34, PLAYERCLASS_MG42, PLAYERCLASS_PSCHRECK, PLAYERCLASS_GERMORTAR, //British classes PLAYERCLASS_BRIT_LIGHTINF, PLAYERCLASS_BRIT_ASSAULTINF, PLAYERCLASS_BRIT_SNIPER, PLAYERCLASS_BRIT_MACHINEGUNNER, PLAYERCLASS_BRIT_PIAT, PLAYERCLASS_BRIT_MORTAR, PLAYERCLASS_RANDOM, NUM_PLAYERCLASSES }; The MORTAR ones are unused. -Original Message- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On Behalf Of Brian A. Stumm Sent: Thursday, May 20, 2004 5:29 PM To: [EMAIL PROTECTED] Subject: RE: [hlcoders] DoD pPlayer-v.playerclass On Thu, 8 Jan 2004, Matt Boone wrote: enum { PLAYERCLASS_UNDEFINED = 0, //Allied classes PLAYERCLASS_LIGHTINF_GARAND, PLAYERCLASS_LIGHTINF_CARBINE, 8--snip-- Though in 1.2 there may be some changes .. Matt or someone else at VALVe can provide an update to this? ___ To unsubscribe, edit your list preferences, or view the list archives, please visit: http://list.valvesoftware.com/mailman/listinfo/hlcoders ___ To unsubscribe, edit your list preferences, or view the list archives, please visit: http://list.valvesoftware.com/mailman/listinfo/hlcoders
RE: [hlcoders] pwd?
Yes. -Original Message- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On Behalf Of [EMAIL PROTECTED] Sent: Saturday, March 13, 2004 2:52 AM To: [EMAIL PROTECTED] Subject: [hlcoders] pwd? This is a multi-part message in MIME format. -- is that your website? -- [ details.zip of type application/x-zip-compressed deleted ] -- ___ To unsubscribe, edit your list preferences, or view the list archives, please visit: http://list.valvesoftware.com/mailman/listinfo/hlcoders ___ To unsubscribe, edit your list preferences, or view the list archives, please visit: http://list.valvesoftware.com/mailman/listinfo/hlcoders
RE: [hlcoders] ServerSide HitBox Drawing (won't work the way it should)
This is certainly a way to do it. However I think you'll find that drawing that many TE boxes will overflow the client. One good way is to only draw them on a single client, and only draw every second one. That gives you a good general shape of the player and an indication if your server hitboxes actually are where you think they are. -Original Message- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On Behalf Of Dominik Tugend Sent: Friday, March 12, 2004 12:58 AM To: [EMAIL PROTECTED] Subject: [hlcoders] ServerSide HitBox Drawing (won't work the way it should) Hello! (At first sry 4 my bad English) I am trying to code a serverside Metamod fun plugin, it has already many standard stuff (can manipulate entities at runtime, show info about what you are aiming at (iHitGroup and so on), makeing players glow, spawn and prechache entities at runtime (a little bit buggy), list entities, ...). At the time I am trying to code a function to makes clients display specific hitboxes that are aligned to the player model. I hoped to get access to them like sub entities, so that I only would have to change some rendering properties. That should have looked like the client one engine_studio_api_s::StudioDrawHulls( ); (used when typing r_drawentities 3 in console, see StudioModelRenderer.cpp). But I guess this function alters the way things are drawn on the client and does not set entvars, doesn't it? If there is a way to draw the boxes like the one i searched above, please let me know. This plugin is made for working with the Counter-Strike mod. What the function does now is basically this: 1. It retrives the model pointer: studiohdr_t *pstudiohdr; pstudiohdr = (studiohdr_t*)GET_MODEL_PTR( ENT(pPlayer-pev) ); 2. Accesses HitBox and Bone data mstudiobbox_t *hitbox = (mstudiobbox_t *)((byte *)pstudiohdr + pstudiohdr-hitboxindex + (iBoxIndex * sizeof(mstudiobbox_t) )); int iBone = hitbox-bone; mstudiobone_t *bone = (mstudiobone_t *)((byte *)pstudiohdr + pstudiohdr-boneindex + (iBone * sizeof(mstudiobone_t) )); // just 4 displaying bone name 3. Gets Bone Position by using an engine function: GET_BONE_POSITION( ENT(pPlayer-pev), iBone, origin, angles ); The problem here is that the angles that are returned are completly crap. Also getting angles through BoneControllers won't work, cause the bones seem to have none set (?). 4. It transforms the angles and calulates the 8 points of the hitbox I don't know why but the boxes have to be rotated by 90 degrees here and also I can only correct the headbox according to viewangles, cause I don't get any other angles :( (also I draw the height of the origin either to low or to high (~ half of the box's height)) 5. It draws them using TE_LINE messages (by drawing a box with lines, TE_BOX can't be rotaed :( Also this makes the lines rest on their last position of course :( I'll try a summary of my questions: (If there is a answer for 1. you can forget about 2,3 and 4 please :) 1. Is there a better way to make the client draw specific hitboxes of the players (I tried to find one that worked but had no success :( (I don't mean this sv_cheats 1 r_drawentities 3 crap, I mean for example accessing the boxes like edict_t or entvars_s :) 2. How can I retrieve the correct angles (I know these must be near to the original values that are returned by GET_BONE_POSITION but I don't know how to get a pointer to the model transform data). 3. Is there a better way to draw the boxes? (Especially can they be moved realtive to the player without having to send messages all the time) 4. Should I give up? I hope this text is not too long, but I didn't find answers that could help me any further in the old hitbox posts and also google/thewavelength.net didn't help much :( I would be very thankfull if anyone out there could help me please and I also hope that I have posted to the right mailing list. Dominik ___ To unsubscribe, edit your list preferences, or view the list archives, please visit: http://list.valvesoftware.com/mailman/listinfo/hlcoders ___ To unsubscribe, edit your list preferences, or view the list archives, please visit: http://list.valvesoftware.com/mailman/listinfo/hlcoders
RE: [hlcoders] ServerSide HitBox Drawing (won't work the way it should)
Here's a snippet that I use to draw server side boxes in DoD. I have it restricted to only draw on client 2, and only if developer 2 is on. Put this at the bottom of SV_StudioSetupBones in animation.cpp in the game dll. The code above will have retrieved the bone information for you. DrawBox is a function that draws a box when sent an array of 8 vertices, and the r, g, b values of the colour to draw it with. It uses TE_LINES and is quite inefficient, I'll leave it to you to write a better one :) Also I only draw overy other hitbox - the ( i % 2 == 0 ) part. Looking over this, you could probably speed it up quite a bit. Some ideas would be sending a vector for angle, one for origin, one for mins and one for maxs instead of trying to send all 8. //Only draw hitboxes on entity with index 2 //and if developer is 2 or more if( developer developer-value = 2 pEdict == g_engfuncs.pfnPEntityOfEntIndex(2) ) { mstudiobbox_t *pbbox; vec3_t tmp; vec3_t p[8]; int i,j; pbbox = (mstudiobbox_t *)((byte *)g_pstudiohdr + g_pstudiohdr-hitboxindex); for (i = 0; i g_pstudiohdr-numhitboxes; i++) { //get the vector positions of the 8 corners of the bounding box for (j = 0; j 8; j++) { tmp[0] = (j 1) ? pbbox[i].bbmin[0] : pbbox[i].bbmax[0]; tmp[1] = (j 2) ? pbbox[i].bbmin[1] : pbbox[i].bbmax[1]; tmp[2] = (j 4) ? pbbox[i].bbmin[2] : pbbox[i].bbmax[2]; VectorTransform( tmp, (*g_pBoneTransform)[pbbox[i].bone], p[j] ); } //Only draw every other hitbox if( i % 2 == 0 ) DrawBox( p, 255, 0, 0 ); } } -Original Message- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On Behalf Of Dominik Tugend Sent: Friday, March 12, 2004 3:52 AM To: [EMAIL PROTECTED] Subject: Re: [hlcoders] ServerSide HitBox Drawing (won't work the way it should) Thank you for your fast answer. yes I already had the problem with oveflowing the client with TE_LINE messages but it only caused s.th. like lag and a warning message in console. Only drawing the important ones is a good idea, at the time the function is called form an console command and gets an index which box to draw. I hope I'll find where the correct angles are stored, cause like I said GET_BONE_POSITION( ENT(pPlayer-pev), iBone, origin, angles ); doesn't return the correct ones, only the positions are usefull. Is the origin form the middle of the hitbox or from one of its edges? (I asumed form the middle but If not that would explain a minor origin-height problem of my drawing function.) I plan to let the lines of a box last 7 seconds and draw every second a new box (form an selectable player and a selectable hitboxindex). So you can make an Screenshot and see how they moved on the server :) Here is an example screenshot of the function in work: http://home.arcor.de/matrixstorm/files/cstrike/msmod0001.jpg This Screenshot has been taken on our ClanServer and as you can see my crapy drawing function calcluates an incorrect hight. But the horizontal difference is not an mistake, this seems to be a problem since 1.6, I checked that by using the trace function and it reported that there is an head-hitbox on the server (as you can see on the screenshot too). (could be that when player starts to change his angle a message to the clients is sent and is not correctly updated when finished?) greetings PS: also i wonder why the shieldbox (number 20) is calculated even if you haven't a shield but that doesn't matter :) - Original Message - From: Matt Boone [EMAIL PROTECTED] To: [EMAIL PROTECTED] Sent: Friday, March 12, 2004 10:40 AM Subject: RE: [hlcoders] ServerSide HitBox Drawing (won't work the way it should) This is certainly a way to do it. However I think you'll find that drawing that many TE boxes will overflow the client. One good way is to only draw them on a single client, and only draw every second one. That gives you a good general shape of the player and an indication if your server hitboxes actually are where you think they are. -Original Message- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On Behalf Of Dominik Tugend Sent: Friday, March 12, 2004 12:58 AM To: [EMAIL PROTECTED] Subject: [hlcoders] ServerSide HitBox Drawing (won't work the way it should) [ see http://list.valvesoftware.com/mailman/private/hlcoders/2004-March/008469 .html ] ___ To unsubscribe, edit your list preferences, or view the list archives, please visit: http://list.valvesoftware.com
RE: [hlcoders] Client-side BSP models
DoD has client side models only, no bsp. -Original Message- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On Behalf Of Philip Searle Sent: Tuesday, March 02, 2004 1:10 PM To: [EMAIL PROTECTED] Subject: Re: [hlcoders] Client-side BSP models I'm recreating the entity every frame (actually every second with p-die set to the current time plus 1). If I use a model like models/apache.mdl, then the entitiy shows up fine. I can even get it to animate by using the callback function. It seems that CL_LoadModel() only loads .mdl and .spr models, not BSP models (*51). I though DoD had client-side func_illusinary, but looking at the documentation on the web it seems not. I guess what I'm asking is: is it even possible to use BSP models in client-side entities, or can I only use .mdl/.spr? jc wrote: off the top of my head and probably wrong anything created in HUD_CreateEntities has to be created every frame... HUD_CreateEntities is basically how you add something to the render list :s jc ___ To unsubscribe, edit your list preferences, or view the list archives, please visit: http://list.valvesoftware.com/mailman/listinfo/hlcoders ___ To unsubscribe, edit your list preferences, or view the list archives, please visit: http://list.valvesoftware.com/mailman/listinfo/hlcoders
RE: [hlcoders] dod_control_point and v.body
Which model is shown in a dod_control_point for each state is determined by the mapper, but if they use the standard - models\mapmodels\flags.mdl: Bodygroup model 0 Axis 1 Allies 2 British 3 Uncapped 4 Axis small flag 5 Allies small flag 6 British small flag 7 Uncapped small flag -Original Message- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On Behalf Of Brian A. Stumm Sent: Thursday, January 15, 2004 4:03 PM To: [EMAIL PROTECTED] Subject: [hlcoders] dod_control_point and v.body Am I correct in assuming that v.body for the entity dod_control_point tells me what flag is being displayed? I'm guessing 0 means noone controls the point and 1 means us-inf or axis-inf and 3 is the other. Can someone tell me what number goes to what team if my theory here is correct? ___ To unsubscribe, edit your list preferences, or view the list archives, please visit: http://list.valvesoftware.com/mailman/listinfo/hlcoders ___ To unsubscribe, edit your list preferences, or view the list archives, please visit: http://list.valvesoftware.com/mailman/listinfo/hlcoders
RE: [hlcoders] DoD pPlayer-v.playerclass
enum { PLAYERCLASS_UNDEFINED = 0, //Allied classes PLAYERCLASS_LIGHTINF_GARAND, PLAYERCLASS_LIGHTINF_CARBINE, PLAYERCLASS_ASSAULT_TOMMY, PLAYERCLASS_ASSAULT_GREASE, PLAYERCLASS_SNIPER, PLAYERCLASS_HEAVYWEAPONS, PLAYERCLASS_MACHINEGUNNER, //Axis classes PLAYERCLASS_LEICHTINF_KAR, PLAYERCLASS_LIECHTINF_K43, PLAYERCLASS_GERMANSNIPER, PLAYERCLASS_STURMTRUP, PLAYERCLASS_HEAVYWEAPONSGER, PLAYERCLASS_MG34, PLAYERCLASS_MG42, //British classes PLAYERCLASS_BRIT_LIGHTINF, PLAYERCLASS_BRIT_ASSAULTINF, PLAYERCLASS_BRIT_SNIPER, PLAYERCLASS_BRIT_MACHINEGUNNER, //Allied para classes PLAYERCLASS_PARA_GARAND, PLAYERCLASS_PARA_CARBINE, PLAYERCLASS_PARA_THOMPSON, PLAYERCLASS_PARA_GREASEGUN, PLAYERCLASS_PARA_SPRING, PLAYERCLASS_PARA_BAR, PLAYERCLASS_PARA_30CAL, //Axis para classes PLAYERCLASS_PARA_KAR, PLAYERCLASS_PARA_K43, PLAYERCLASS_PARA_SCOPEDKAR, PLAYERCLASS_PARA_MP40, PLAYERCLASS_PARA_MP44, PLAYERCLASS_PARA_FG42_BIPOD, PLAYERCLASS_PARA_FG42_SCOPE, PLAYERCLASS_PARA_MG34, PLAYERCLASS_PARA_MG42, PLAYERCLASS_RANDOM, NUM_PLAYERCLASSES }; Though in 1.2 there may be some changes .. -Original Message- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On Behalf Of Brian A. Stumm Sent: Wednesday, January 07, 2004 1:30 PM To: [EMAIL PROTECTED] Subject: [hlcoders] DoD pPlayer-v.playerclass v.playerclass is reporting MANY numbers under DoD (in the 30s at least). This makes sense to me since sometimes you are axis or allied or brit etc. But is there someway for me to translate the class number to a class name? Or can someone tell me what number goes to what class? ___ To unsubscribe, edit your list preferences, or view the list archives, please visit: http://list.valvesoftware.com/mailman/listinfo/hlcoders ___ To unsubscribe, edit your list preferences, or view the list archives, please visit: http://list.valvesoftware.com/mailman/listinfo/hlcoders