Difference between revisions of "Help Desk"

From Valve Developer Community
Jump to: navigation, search
(Pending Questions)
(Pending Questions)
Line 42: Line 42:
  
 
==Pending Questions==
 
==Pending Questions==
 +
 +
===Detail Sprites Gone Screwy===
 +
While testing my map on a couple different computers, I noticed that sometimes the detailsprites get stretched and tilted down.
 +
So far, this only happens on two computers, one is running an 8800GTX and the other (a laptop) a radeon mobility x1400.
 +
You can see an image here: http://i136.photobucket.com/albums/q192/MrHappy_photos/help.jpg
  
 
=== Render Target Texture Translucent ===
 
=== Render Target Texture Translucent ===

Revision as of 01:23, 13 September 2007

Contents

Got a question that is not answered in the Source SDK FAQ? Ask it here! Any sort of SDK question should be posted here. After they get answered, move them to the "Answered" portion of the page.

Suggestions before asking a question

Check to see if your question has been asked before:

Asking a question

  • Be specific and clear as possible.
  • Please sign your question (end it with ~~~~). This will help us direct follow-ups to you directly.
  • Check back for answers. We will not put answers in your talk page unless it is specific to you.
  • Use common sense. Hopefully, this won't require much more explanation.
  • Edit questions for follow-ups. Do not post a new question.
  • Use second-level headlines. Surround your question title with three equal signs (===) so they create a table of contents, split between pending and answered questions.
  • Only move your own question. An answer may not fully answer a question. When the question is fully answered, then move it to Answered Questions.
  • Where did my question go? Questions which have not had any activity for 2 months are moved to Dormant Help Desk Questions.

Alternatives

  • Ask your question at:

English Sites:
The Official Steam SDK Forum
Interlopers Forums
HalfLife2.net

French Sites:
Half-Life Design
Game Lab
Mapping-Area

Other:
List of Mapping Sites
List of Modeling Sites

Pending Questions

Detail Sprites Gone Screwy

While testing my map on a couple different computers, I noticed that sometimes the detailsprites get stretched and tilted down. So far, this only happens on two computers, one is running an 8800GTX and the other (a laptop) a radeon mobility x1400. You can see an image here: help.jpg

Render Target Texture Translucent

I setup this render target texture using the following code:

s_pCombatCharsTex0.InitRenderTarget( 256, 256, RT_SIZE_FULL_FRAME_BUFFER, IMAGE_FORMAT_RGBA8888, MATERIAL_RT_DEPTH_SEPARATE, false );

I then clear it by setting it as the current render target and using a clear color of float4(0,0,0,0). When I render it using my frontbuffer material, it displays completely black, which is correct, but it's not transparent. I have "$translucent" 1 in the .vmt file, but it doesn't work. Using "$alphatest" 1 works, but I want an opacity map, not a rejection of alpha less than 178. I'm pretty much stumped as to why this is happening. It's probably something really simple I'm missing. ScHiZo 21:46, 26 Aug 2007 (PDT)

Could datacache.dll crashes be linked with missing resources?

My mod is currently plagued with frequent datacache.dll crashes. I've followed all the standard suggestions, but it still happens often on several different machines. It's a team deathmatch mod but with NPCs activated and I can't help feeling like the crashes may be due to a few resources not being found. While it runs the NPCs work and everything looks right apart from other players aren't animated. I get a few messages about animations or sounds being missing, but sounds play anyway and it doesn't stop the game immediately. I created the mod based on HL2MP but the map shows slightly differently when run in HL2MP and my mod (I get dandelions rather than brown grass). I'm using AppId 215, is there a way I can say use HL2SP resources as well? Would copying them into my mod directory be enough? Unfortunately I get no useful debug from the crash. Any help greatly appreciated. Gurtak 07:36, 31 Jul 2007 (PDT)


I have gotten this error due to many reasons yet its something terribly wrong with your map which is mainly what causes it.--Gear 05:43, 15 Aug 2007 (PDT)

Thanks Gear. You are right, there was something wrong with the map, but we never tracked down what it was. Strange that it would work for a while and crash for no apparent reason. We started again from scratch and all works well now. I'm just glad it wasn't my code :) Gurtak 14:08, 2 Sep 2007 (PDT)


Scary isn't it?--Gear 01:11, 3 Sep 2007 (PDT)

Hammer loads map in bad server

When I try to test a simple map by hitting F9 in hammer, it compiles fine, opens cs source fine (it's set up to the defaults for cstrike) and begins my map. The console shows no significant errors.. it can't download the dynamic pricing list or something and it can't find jingle.wav but those are the only errors. Then after about a second, the server shuts down saying "Server shutting down..." My map works perfectly if I just open counter strike through steam and manually do Create Server for it, but when hammer loads CS the server immediately shuts down. If I try to do Create Server for my map in a CS that's been opened by the hammer compiler, it takes 2 or 3 tries before it works. This is all very weird and quite inconvenient for testing. Can anyone help? --Froth 20:32, 25 Jul 2007 (PDT)

Sometimes that tends to happen even with normal games. Hammer places the bsp file within the map folder in css. Simply click the "don't run game after compiling" button, Once the hammer is finished compiling then open up css yourself and type map "your map name here" and thats all to it.

Thats just mainly a work around yet i don't know if any others exist.--Gear 20:37, 25 Jul 2007 (PDT)

Well when I discovered CS:S about two and a half years ago I didn't actually own it.. I played with bots on the default maps for more than 4 months before I got bored and actually bought the game (and of course I'm very glad that I did- I've been playing heavily ever since). This inexplicable server shutting down message has never happened to me before even in that whole time of hosting my own games, yet it happens every single time when launching from hammer. Is there any way of actually fixing it rather than launching it separately? --Froth 21:51, 25 Jul 2007 (PDT)


Like i said no there is no other way unless you are too lazy to open it yourself i mean its really not that hard to be honest.--Gear 12:33, 26 Jul 2007 (PDT)

Can't load bsppack.dll

Sometimes after I build cube maps in a map I get this error in the console. It means that although the cubemaps have been built and are in-memory they aren't written to the BSP, and that my mouse won't work until I restart the game! I get the error often, but not all the time. --TomEdwards 11:20, 25 Jul 2007 (PDT)

Sometimes the game just crashes too. --TomEdwards 11:40, 25 Jul 2007 (PDT)


Thats quite odd perhaps are there any cubemaps that are within a special volume? Mainly I have noticed this error when a cubemap is placed within a env_fire entity or a trigger_transition which causes the cubemap to become unreadable. An odd error to at that.--Gear 11:58, 25 Jul 2007 (PDT)

Assign a custom material for the env_steam entity

How do you specify a custom material for the env_steam entity? At this time, the default material (particle_smokegrenade) has been hardcoded. I need a different material for my current projects. The Mighty Atom 19:01, 23 Jul 2007 (PDT)

You might need to create one yet adding t might need reference to the FGD. file, yet im not to positive on where it can be edited. However you might want to give that a try.--Gear 05:44, 15 Aug 2007 (PDT)

Host_EndGame: Map coordinate extents are too large!!

I'm starting off trying to learn to map with Source. I compiled my test map in Hammer, then tried to run it and got this error message. A quick search told me that this meant I had an entity outside the hammer grid, and to use the hammer error check (alt-P) and fix any problems shown. The only error it gave me was a missing player start, so I created one saved again, and tried to play, and got the same error. My map is small, in the dead center of the grid, and the error check isn't reporting any problems at all.... What is wrong? Jetsetlemmingq 17:06, 15 Jul 2007 (PDT)

Well, I've had that problem once before also, except the problem showed up in the "check for problems" box. It seemed that there was an invisible, useless and undeletable brush in the middle of the map that had an error. Try checking for problems again. If that doesn't work, the simplest solution would be to load the last working autosave file. --Darthkillyou 10:50, 28 Jul 2007 (PDT)

Hmm dky is right however one of the main reasons that cause this is a super huge brush either that nor the map may be way too large.--Gear 16:46, 28 Jul 2007 (PDT)

Oh, right... I remember that I fixed the problem simply by restarting Hammer. It, for my "Information, Hammer didn't load 1 solid(s) due to errors in the file." --Darthkillyou 07:04, 14 Aug 2007 (PDT)

Third Person

Is there in any way to change the current player camera to a third person angle? I belive that there was a mod called Iris that did this. Also they replaced the normal gordon freeman model with a young girl, ive been trying to do the same but instead replace the normal player model with a Rebel instead. Also if possible is there a way to edit the angles of the camera that way its a bit of an "over the shoulder" angle much like per say Gears Of War or even Ghost Recon advanced Warfighter as an example. Thankyou for your time.--Gear 15:29, 8 Jul 2007 (PDT)

Response Contexts

It's my understanding that specific response contexts do not need to be pre-defined per NPC unless you want more specific control, and that without any work the set of HL2 response contexts will be fired in response to AI requests simply when your play and certain events occur. A friend of mine is having a problem where the contexts never fire, even when the player +USE's an NPC. The original question/thread on interlopers is here: http://www.interlopers.net/forum/viewtopic.php?t=17778 I have noticed this at times in my own maps, however the problem seems to come and go. I haven't found much information on specifically using the system except in the pages here, however, as another user stated, that is more of an information dump than anything usefull for trouble shooting or tutorial wise. Thanks for your time. Mrhappy 16:13, 30 Jun 2007 (PDT)


Odd yet it might not be able to find the choro files. You might want to try adding in a speech filter entity that will allow you to control when and how much the npc will talk or idle respond. Sometimes NPCs tend ot have "locked" behavior. Mainly due to when they are used by scripted sequences.--Gear 05:48, 15 Aug 2007 (PDT)

entity help needed

in hammer i want to make a end to my lvl to do that 6 things has to be uses before it ends but how do i do that? if i use one thing the level ends right away without pushing the other 5 buttons! what entity do i have to use, and how to install it? --Killermans 04:40, 24 Jun 2007 (PDT)

Make a math_counter entity. Set it's "Maximum Legal Value" keyvalue to 6. On each of the event's use an output that targets the math_counter with the "Add" input and a parameter override of 1. Set an output on the math_counter with "My Output Named" set to "OnHitMax" that targets and triggers your level change. Mrhappy 16:07, 30 Jun 2007 (PDT)


Vrad has an error

Everytime I compile a medium sized map in Hammer (to run it, not as a final compile), an error appears saying that Vrad "had a problem" and had to disabled. The map runs, but then there is no HDR ligting. ace14790 14:33, 5 Jun 2007 (PDT)

Currently some people have been experiencing this crash as well. VRAD randomly closes out and causes the HDR compile part of the process to stop. The odd thing is even after windows reports the error the compile process still keeps going sometimes yet even though does not compile correctly. There realy is no fix for this at all untill the next engine update. For now just simply re-compile your map and hope it doesn't crash again. However certain things do cause this crash to happen and that is mainly compiling havng Vrad set to fast.--Gear 13:23, 8 Jul 2007 (PDT)

Problem with HDR lighting in custom maps

I cannot use HDR lighting when running custom maps made in Hammer. I have to uncheck HDR when running a map or there are problems with lighting on the map. When I start a map with HDR enabled I receive the following message: "custom hdr cubemap "materials/environment maps/borealis_003.hdr.vtf": can't be found on disk.This really should have an HDR version but I will tryfalling back to the non-hdr one. Signon traffic "CLIENT": incoming 32.417 Kb, outgoing 715 bytes"

What can I do to resolve this issue with HDR lighting?

Tom11235 16:01, 27 May 2007 (PDT)

That warning appears when you compile HDR lightmaps for a map that doesn't use a proper HDR skybox. HDR is not an option you can simply set in the video panel. Read the article above for further explanation. --uoz 12:29, 8 Jun 2007 (PDT)

Yeah uoz is right, however the skybox material won't really cause any problems if still used. Mainly the compile process just reports that because the selected sky base material does not have any HDR parameters, So dont worry about it as long as you build cubemaps you will be fine.--Gear 13:52, 8 Jul 2007 (PDT)

Compile error: "Error trying to allocate X bytes."

I'm in the process of creating a map but I run into an error when compiling it. "Error trying to allocate 18840 bytes." comes up during the BuildVisLeafs process, after the "3" to be exact. When I run the map, there are no lightmaps, despite the fact that the BuildFacelights portion went without a hitch. Save for a number of "WARNING: Too many light styles on *Coordinates*." I'm not sure if this has anything to do with the previous error, as I've been getting those warnings since before I encountered the "Error trying to allocate 18840 bytes." Still, help would be appreciated, for both errors. I'm not sure if it's worth mentioning that if I choose not to have neither VIS or RAD when I compile, the filesize is nearly half that of when I compile with RAD and VIS, yet I get, apparently, the same results. I compile it using a fast VIS calculation and a normal RAD. I doubt it's a problem with my memory, as I've got 1532 MB's. Again, help would be appreciated.

Squadila 18:40, 15 May 2007 (PDT)

Seems to be using up too much memory. Even a gig and a half won't work if you have too many lights on one face. The errors are probably related, so I would cut down on the number of named lights.


Named Lights has nothing to do with it its just simply lights on directed on towards one single face or other words brush. Names really dont cause errors although you shouldn't have to name all of your lights just the ones that require naming for the use of reference to other entity's or even simple outputs and inputs, triggers, etc,. Even if its two lights casted upon one face that can still cause an error namely also if the lights have adjusted appearances like strobe or flicker or even pulse. Try cutting down on that especially if they are light_dynamic.--Gear 17:06, 23 May 2007 (PDT)

How do vehicle sounds and sound loops work?

Ive tried to do some sound modding for empires mod (it uses the hl2 single player buggy sounds and soundscripts), but the source sound system drives me crazy. I would like to hear some official information about how it handles sound loops, because i experienced the following problems:

  • We have a separate sound loop for idle engine sounds, like v8_idle_loop1.wav. The default official single player buggy loop wav file doesnt contain any cue points. I made two different loop sounds to replace this. They are both identical in format, in length, in volume. One works the same way as the default v8_idle_loop1.wav, it loops when the engine is idle. The other one only does this when a cue point is present. How is this possible?
  • There is an engine start sound in hl2 single player: v8_start_loop1.wav. It doesn't have cue points. Ive tried to replace it with two different sounds, both same format. One is played when the engine starts, the other is not. The are 100% identical in length, format, volume level. Cue point doesn't help here.

So my questions: Does source really need cue points for vehicle loops? If it does where do they need to be placed? What may casue two identical formatted sounds to differ in playing? How does the default vehicle sound system build up, how do different sound effects loop themselves or follow each other based on the speed of the vehicle?

Petko 22:56, 13 May 2007 (CET)


Problems recording in Episode 1

Recently I've tried to make an .avi file out of a .DEM file using the "startmovie" method. I also changed host_framerate to 30. Problem is, Once I compressed it with VirtualDub into .avi, the video was out of sync with the audio. The only video codec that gave best results was Xvid and I used many of the codecs in MPEG-LAYER 3 for the audio compression, but it was still out of sync. After a lot of coffee and futile attempts I gave up on VirtualDub and started using the "startmovie [videoname] avi" method. That worked great, except that this time the audio was a bit ahead of the video at the start but as the video progressed the video eventually overtook the audio. Basically, I'm sick of virtualDub. I'm just gonna use the source recorder to compress it straight to.avi, but the video and audio is waaay out of sync.

Problems:

  • The audio speed is fine it just starts before the actual video.
  • The video is too quick, eventually it overtakes the audio. Even though the audio started first.

Is the host_framerate not 30 for Ep1? Or is there another way of shortening the video speed without affecting audio, so they fit perfectly? Please help :( Tsmike92 08:38, 7 May 2007 (PDT)

Strangely even using regular demos recorded through the HL2 system creates problems when viewed upon other mods or systems its quite odd but im not sure what causes the problem if it would be any help though I'll look into it for you. I've been in the needs for creating a demo video for my mod as well so I'll see if i get the same problem.--Gear 17:12, 23 May 2007 (PDT)

This has happened many times, and I believe it's because you didn't use sv_cheats 1 for host_framerate (host_framerate is a cheat) I can't remember whether this is in the tutorial, but if not, I'll add it in.--Katana314 19:52, 19 Jun 2007 (PDT)

Performance warning: Mark bone

I've been banging my head trying to fox this console error problem for ages now. All the answers i have found says to use $bonemerge to fix it. But this only fixed my problems for the firstperson stuff. The thirdperson errors are still there. The developer console is totally spammed with this error.

Drakir 15:29, 22 Apr 2007 (PDT)

Mainly this tends to happen alot when certain things are used on incorrect attachments on an npc. Mainly theres truely not a fix to it unless you really re-edit the code for the npc or even player attachments toward the bone points. Mainly its not a serious error but just that the engine has no existing attachment points where the weapon currently is attached towards. In other words in an arm there is about 3 points. Shoulder, Hand, and Wrist therefore if the weapon or model is just pasted toward another area not reconized or where no attachment point exist then the error is casued. Mainly you might need to rework some attachments on the model that is currently being used.--Gear 13:30, 8 Jul 2007 (PDT)

Physics Gun compile problem

I followed the tutorial on another forum site, and it adds fine, until i try to compile when i get the error:

(http://pastebin.ca/443470)

I have tried to fix this myself, following this: http://www.hl2world.com/bbs/-vp675217.html

But i am a very big Noobie to c++ hoping to pick some up on the way through half-life 2 modding.

Cheers, Hope i get a quick answer :P

Trleighton 13:32, 16 Apr 2007 (PDT)

Two scipting problems

First, the MOTD simply does not show up on my server. Also having a similar problem with an MP mod I'm working on, in which only the first character shows up.

Second, as usual the death notices are not working properly in my MP mod. Since there are custom weapon icons (which I do have working) I figured I'd just set up a new entry in clientscheme.res for them. So, under the HL2MPDeathType entry I have:

		"BSGCFTypeDeath"
		{
		   "1"
		   {
				"name"  "bsgcficons" // csd.ttf
				"tall"  "32"
				"weight" "0"
				"additive" "1"
				"antialias" "1"
		   }
		}		

and of course in the custom font declarations I have

 "3"		"resource/bsgcficons.ttf"

Then I went to mod_textures.txt and set the appropriate weapons to BSGCFTypeDeath, like this:

		"death_smg1"
		{
				"font"		"BSGCFTypeDeath"
				"character"	"/"
		}

Well, I'm still getting the error where the icon shows up as the character it is assigned to. There is nothing wrong with my font file, the icon shows up properly in the buckets and loadouts.

Thanks in advance! -Mrhappy 19:42, 10 Apr 2007 (PDT)

I figured out the problem with the death notices, the HL2MP.ttf file which stores the icons for the notices is formated differently than the halflife2.ttf file which stores the icons for buckets and loadouts, and which I used as a template for bsgcficons.ttf. I'm still having problems with my motd files tho :/ -Mrhappy 11:57, 11 Apr 2007 (PDT)

More than 32 chapters in the chapter menu in a HL2 mod?

If you add more than 32 chapters to your mod, chapters 4, 5, 6, 7, 8 and 9 vanish from the menu and any chapters over 32 are left out. Is there any way to increase the 32 chapter limit?

Here is a some more information, following tests to explore the problem:

  • For every chapter over 32, 1 chapter between 4 and 9 is removed.
  • The remaining chapters are shifted down, and anything that's still left over after 32 is dropped.
  • Therefore if you have 40 chapters, you lose six chapters (4 to 9 inclusive), as well as the left over 39 and 40.
  • If you have 36 chapters, you lose 4 chapters (6 to 9 inclusive) but nothing is left over.
  • If you have 33 chapters, you just lose chapter 9.

The system is entirely governed by the contents of the cfg folder. The presence of the chapter1.cfg, chapter2.cfg etc. files in the cfg folder is what tells the new game menu to add chapters. The modname_english.txt file in the resources folder only gives those chapters a name, and the textures in the vgui folder only give them a picture. The chapter#.cfg's can be numbered in any way, using any combination of letters and numbers (such as valve's use of 9a for Entanglement), but it all makes no difference, as long as there are not more than 32 in total.

Can this limit of 32 be fixed or worked around?--Fitzroy doll 12:17, 15 May 2007 (PDT)

Sadly no, 32 is really the limit or at least as high as it will go so truely the only work around is really decreasing the number of Chapters your mod contains. Besides there is really no reason to have more than 32 chapters unless of course if your mod has over 100 maps or is really, really long. Either way just try to work out more maps in one chapter and decrease the number of chapters in total.--Gear 13:35, 8 Jul 2007 (PDT)

I understand. I am using the chapter menu in a somewhat unusual fashion, which is as a map browser similar to CS:S, but with images and titles. This is for the mod CSS SCI FI which features 27 scripted maps for use with SMOD. Each of those 27 is a unique game, and the maps are not linked, so the only way to access each map is through an individual chapter, as shown here. My solution has been to include an option in the SMOD Configuration Utility which I made that allows the user to switch chapter menus. This works, but of course it would be much better if all the chapters could be displayed together, without having to switch. --Fitzroy doll 07:51, 9 Jul 2007 (PDT)


Ah yes okay hahahaha you should've mentioned that earlier! It is okay though. Well hmmmm...... perhaps you can create a menu rather than a simple new game chapter start. Perhaps a menu that contans each map and the chapter name without the image. More or less a bit like Garry's Mod 10. Yet im a bit rusty on doing that. I do know though, that there is a guide to creating vgui menus on the main screen through certain key pressing and whatnot, so maybe that might work better.--Gear 13:56, 9 Jul 2007 (PDT)

Error: "The command failed. Windows reported the error: "the system cannot find the file specified" while compiling.

When i want to compile the map, Hammer gives me an error. the error is: "The command failed. Windows reported the error: "the system cannot find the file specified".

i don't know why it is, i checked if the file is there, i tried to disable the VIS and RAD compiling but it gives me the error all the time. Also did i tried to refresh SDK Content and Reset the Game Configs, but it didn't work someone knows what the problem can be?


anyone????



I have the same problem, as i seee no one has an answer but some help would be nice:)


i had the same problem but it was an error in my map u probaly saved under another name and got that error. how dit i fixed it? easy i used the last compiled file of my lvl and decompiled it whit vmex. and the level was ready to edit. this is maybe your problem. --Killermans 04:51, 24 Jun 2007 (PDT)

This error is mainly caused when the compile program can not locate the BSP file which is truly strange. I have gathered some information about it in the sdk faqs and this is what has turned up:

This error appears when the map compile has failed due to an error, or the current game configuration is not set up correctly.

Check the error log in the Hammer Process Window to make sure there are no other errors that may have caused the compile to fail. If a compile fails, no .BSP file for the map is written, and the game will not launch correctly.

If there are no other compile errors, you can try to reset the Source SDK game configuration

I know not really to helpfull but thats about it so hopefully this will help you out and goodluck!--Gear 13:40, 8 Jul 2007 (PDT)

Light errors

Ok, so ive made a small map and added lights to it, but each time the freeze time runs out the lights die and i can only see a red glow on myself but not on any objects. If this doesnt happen its normally when i leave the spawning room that the lights die. Do i need a skybox for the lights to work? (i don't know, im new to SDK) Any help would be appreciated User:sabre05

Skybox

ok so when i make a sky box and texture it the Maps textured become transparent and show only the textures on the box.... HALP MEH

Maybe a little more specific.--Gear 05:51, 15 Aug 2007 (PDT)

Level Transition Freeze-Up

I've built two levels and set up my level transitions from what I gather, properly. The landmark entities both have cooresponding names, and are in the same place, and the trigger is set up right and seems to activate the transition fine. However, once it starts the load, it never finishes and the game hangs up. Any ideas? ElecHeadMatt 15:18, 28 Jul 2007 (PDT)

Could be perhaps a problem with the map thats trying to be loaded. Consult that map first and see if it freezes on normal loading of that single map.--Gear 16:45, 28 Jul 2007 (PDT)

No dice, both levels load just fine, and don't seem to have any bugs or errors when loading. ElecHeadMatt 10:11, 29 Jul 2007 (PDT)

Funny thing is that happened to me yesterday. A level change occurred and well the game took a really long time to load. Sat there for ten minutes. Apparently the cause is when you place your mod or edit it over an existing version of your mod. Try to restart steam. That fixed it for me.--Gear 14:59, 29 Jul 2007 (PDT)


Hammer Closes Without Warning

I'm trying to make a map with several different planets. Every time I make a spherical brush and try to make it hollow hammer closes without warning. This dosent do this with any other brush and I've attempted to make the brush different sizes. I've even completely uninstalled and reinstalled Hammer but it does the same thing only faster.

Help would be greatly appreciated, Justible 11:44, 6 Sep 2007 (PDT)


Considering it is a planet it might be taking up way to much memory, therefore causing windows to close Hammer. Try avoiding this for right now.--Gear 21:51, 6 Sep 2007 (PDT)

Face Poser and Model Viewer crash on launch in widescreen resolutions

Having tried to load Faceposer several times it will crash having opened and laid out all the panels, the model viewer just crashes on load. I tested this on a none widescreen monitor (or using 1024 by 768) and the faceposer application opens. A small bug i know but did not see a road map for fixing this (or it registered as a bug) i have reinstalled and looked at this thread but no joy. My default resolution is 1280 by 720 and fails every time. --Packetburner 10:20, 7 Sep 2007 (PDT)

Answered Questions

Archive

Assigning team points based on triggers without team member activator

We want to give team points when entities pass through a goal trigger, however I can't get the right combination of triggers to do the job. Entities could be anything, including monsters and players, but since they don't have team status they don't trigger the team score via the filter_activator_team and game_score. At present only a player walking through the trigger adds points. In short, if anything goes through goal A, team A scores, and the same for goal B and team B. Thanks. Gurtak 10:04, 23 Jul 2007 (PDT)

Well turns it wasn't that difficult to create a custom team point entity for the goals. I was just hesitant about jumping straight into changing code. If anyone else wants this entity let me know, otherwise I'll move this to answered in the near future. Gurtak 07:08, 31 Jul 2007 (PDT)


Will not compile

FIXED:Did not know about user32.lib. That should really be put in a more obvious place. Elspin 19:44, 6 Jun 2007 (PST)


Weapon handoff?

I'm trying to have an NPC hand a weapon to the player. The goal is to have an armed npc_citizen (for example) who meets the player, goes through a short sequence, and holds out the weapon for the player to take. I know this is possible because Odessa does it in HL2 with the rocket launcher. I can muddle through the rest of the choreography but this bit has me stumped. What's the general procedure for scripting weapon pickups/handoffs? There are inputs listed in npc_citizen for e.g. GiveWeapon but no obvious way to get rid of weapons... At this point I've been through all the SDK docs and can't even find a way to convince an NPC to drop their weapon on the ground.

Plasmadyne 01:20, 18 May 2007 (PDT)

I think they used a weapon_rpg with the "Player only" flag checked, and built animations around it. See the commentary in Ep1 when Barney gives you the crowbar. --Gman003 08:38, 21 May 2007 (PDT)

OK, thanks... I think I have an outline now.

Plasmadyne 14:00, 27 May 2007 (PDT)

Exporting from XSI Foundation 6.0

I'm pretty new to modeling and trying to learn. I have a copy of XSI Foundation 6.0 (yes its legal if that matters). The Valve plugin doesn't seem to work (the ValveSource menu wasn't added to the toolbar). I put the file directly into the /addons folder. I suppose I could get a copy of the mod tool and move my files over when I'm ready to export, but I was wondering if there were any other options. Maybe I'm installing the addon wrong? Maybe it shows up somewhere else in the full versions of XSI? Pre-emptive thank you! -Mrhappy 01:20, 26 Mar 2007 (PDT)

As noted here, the addon included with the SDK does not work in XSI 5. I'm guessing, and hoping, that the addon on the page there also works for XSI 6. Worth a shot anyway. --Daedalus 19:13, 26 Mar 2007 (PDT)
Thanks alot, I'm pretty sure it's working properly now. Moving to answered -Mrhappy 19:30, 10 Apr 2007 (PDT)

Problems with Engine / Map

I'm not sure if this is an error in the engine or a map, but everytime I try to run a certain map, I get the following error:

13/ - func_brush: UTIL_SetModel: not precached: *3

hl2.exe then crashes to desktop. This only affects one map. I can provide the .vmf if needed.

--Gman003 15:39, 12 May 2007 (PDT)

Fixed, it was the skybox. Accidentally tied it to a func_brush.

--Gman003 17:48, 12 May 2007 (PDT)

Half-Life 2 Episode 1 "tree_pine" models

I'm fairly new to SDK's Hammer Editor & am currently trying my hand at mapping for Half-Life 2 Deathmatch. My peticular map is of the outside variety in a mountain setting. I need evergreen trees to make it believeable (no evergreen models available in Half-Life 2). I did notice just before the end of Episode 1 (in "ep1_c17_06.bsp"), there are evergreen trees. So with my GCF Scape I searched the "episode 1 shared.gcf" file & found them (six models altogether). I extracted the models to "hl2mp\models\episode1pines" & extracted the materials to "hl2mp\materials\models\episode1pines". However, the models don't appear in my map. I'm pretty sure it has to do with the fact that there were only two ".vmt" (material) & two ".vtf" (texture) files, but none with the same names as the models. Don't I need six ".vmt" & six ".vtf" files with the same names of the models? These models are awesome & are exactly what I'm looking for. Any help with this will be greatly appreciated. Thanks!

P.S. I have also used bspzip.exe to extract embedded files within "ep1_c17_06.bsp" thinking the files I need may be there. No luck with that either. How can the game render these models if the necessary files aren't in "episode 1 shared.gcf" or "ep1_c17_06.bsp"? Is there another place I can look for these material & texture files?--YPE 19:18, 26 Mar 2007 (PDT)

There's nothing wrong with your models. You placed them in the wrong folder.
Eg. If they came from: epicsodic/models/prop_foliage/ in the episodic folder, THEY HAVE TO BE IN hl2mp/models/props_foliage, and the same goes for the materials. It's just how the .mdl system works.--Sortie 00:07, 30 Mar 2007 (PDT)
Thank you Sortie! I didn't realize the importance of keeping the directory intact. I moved the models to the "hl2mp\models\props_foliage" & the materials/textures to "hl2mp\materials\models\props_foliage". The models became visible when placed in my map. Now the only problem I have is feeling like a dork for putting them into the folder I created. I will give you due credit for helping me with the evergreen trees if I ever release my map. It's looking much better already! --YPE 16:58, 30 Mar 2007 (PDT)

Wait one minute i think he is wrong, you're creating the maps in hammer and want to include the props in your map correct, but you need to first extract the files to the Sourcesdk folder in the models and materials path for instance like this: c\programfiles\steam\steamies\username\sourcesdk_content\materials. Same goes for the the models but instead into the models folder. Sorry but the information he gave you is wrong once you place the props in that folder and materials you can then use them in Hammer. The game you design for also depends on the available content! However it being a mp map you can pack the textures and modles so servers can have the players download them. Ive made sourceforts map and ive use ep 1 content on them so i think i would know pretty well on that one so its not bad or anything but thats what you need to do. It needs to be placed within hammmer so when compiled it will show up in the map.--Gear 17:06, 30 Mar 2007 (PDT)

Also on one last note i cant wait to see youre map sounds great is it gonna look like this maybe a bit?:

px100
Gear, I can totally understand what you're saying. However, the information Sortie has given worked 100%. There is no need for duplicating the tree models into the "sourcesdk_content" directory. I did a compilation & the evergreen trees did show in-game. Thank you too, Gear, for bringing to my attention the "sourcesdk_content" directory. It may very well come in handy. As for what my map will look like, I'm not sure exactly, for I am not finished yet. But I can say that it will look completely different from the screenshot you posted. Hopefully, with luck, it will look a bit more like the opening scenes in the original "Half-Life 2: Episode 2 Trailer". That's my goal anyway. It may not look as good as what Valve has created, But I'm going to give it a shot. I am paying a lot of attention to detail. Who knows!

P.S. I will move this to the "Answered Questions" section in a few days (so Sortie & Gear know that it has been answered).--YPE 17:51, 30 Mar 2007 (PDT)

Sounds fantastic cant wait send me a copy when you're done I'll beta test it you hahah if thats okay i was just wondering with he hammer thing due to you need to place the props first in the map before its compiled but im glad it worked good luck!--Gear 17:54, 4 Apr 2007 (PDT)

Well, Gear's idea might work, but I guess it'll only work inside hammer. By putting it into the game/mods own folder, it's 100% secure it works, and simpler to release the map.
Thank you once again guys, I really appreciate the help you've given me. I certainly know where to go if i need help in the future! Peace... --YPE 15:42, 7 Apr 2007 (PDT)

Programming error

Every time I launch my mod, it works fine until I load a map. About 2/3 of the way through, I get "First-chance exception at 0x22b6d476 (server.dll) in hl2.exe: 0xC0000005: Access violation reading location 0x0000002c. Unhandled exception at 0x22b6d476 (server.dll) in hl2.exe: 0xC0000005: Access violation reading location 0x0000002c." Anyone know what that is? --Gman003 18:28, 19 Mar 2007 (PDT)

Full Log

Hope you don't mind, but I moved that log to a different page since it was so long.
As to your question, it looks as though you've built the game in the Debug release, have you? If so, clean your solution (it's in the Build menu), set your configuration to Release (it should be on the toolbar somewhere, a dropdown list that currently shows Debug), and then build your solution again. --Daedalus 20:26, 19 Mar 2007 (PDT)
No problem. And yes, it is a debug release, but that shouldn't affect it. I'll try rebuilding as release --Gman003 08:05, 20 Mar 2007 (PDT).
You'd think it wouldn't effect it, but I've been unable to use the SDK at all in Debug release, usually end up with errors I can't see. Release has been working fine for al ong time for me though. Let me know how it goes. --Daedalus 14:08, 20 Mar 2007 (PDT)
That seems to fix it. --Gman003 07:54, 23 Mar 2007 (PDT)

Wacked animations

For some reason my animations are all lagged out (on default weapons in a ep1: sp mod code base), this has happened between compiles, and I changed no code. - Links to videos - NORMAL http://www.youtube.com/watch?v=MiNQ4US4w4o WACKED http://www.youtube.com/watch?v=Dh6Z9MqZ3JA --Amckern 16:13, 2 Nov 2006 (PST)

Hammer: %1 is not a valid Win32 Application

Whenever I try to load Hammer to edit either a mod I created or HL2, I get the above error. I tried resetting the game configuration and also deleting/reinstalling the SDK. No dice. I'll keep trying other stuff to get it working. If I do, then I'll answer my own question I guess :D Daemon Jax 15:46, 15 Mar 2007 (PDT)

A: Using a direct shortcut to hammer solves this problem. I found out how to do this at http://developer.valvesoftware.com/wiki/Source_SDK_Known_Issues Daemon Jax 16:14, 15 Mar 2007 (PDT)

HudMsg Error

When ever I run my level, I receive DLL_MessageEnd: Refusing to send user message HudMsg of 335 bytes to client, user message size limit is 255 byte. What can i do to get rid of it? Is it because i have to many ents initializing at map load, or is it something more low level? --Amckern 16:09, 23 Nov 2006 (PST)

Steamappid's, engine updates, and .dll's

I used to think I understood the way the engine updates and how mod's access new code, but the more I read, the less I do. Also, I am not a programmer.

Using steamappid 215 is supposed to allow your mod to update in 'lockstep' with source engine updates. I am unclear if this means

  1. when you use the create a mod function the source code provided is the latest source code. this source code is updated when the source engine updates? Or client and server dll's are updated whenever steam updates, which would make no sense it would destroy custom code.
  2. I noticed there are many .dll's in the base source engine 2.gcf but that client.dll and server.dll are missing. As far as I can tell they only show up (besides in actualy games) in base source engine.gcf/sourcetest/bin What confuzzles me is that this is the directory for the video stress test, and that the client.dll and server.dll werent updated. I'm guessing that these other dll's are what update when the engine updates, and that the source code for them is unavailable without a lisence.
  3. I assumed that the engine only updated when a new episode/game is released, meaning that there has only been two updates (source base and source base 2), but this kinda doesnt make sense for two reasons:
    1. When compiling under Episode 1 (actually I havent done this only read it) you do not need the -novirtualmesh parameter for displacements to collide with physics objects. However, under steamappid 215 you do which is either the same or a later code base, the later of which means (to me) that either the bug cropped up then, although I read it was present pre-ep1 and fixed (didnt get back into mapping till hl2:ep1) or that the bug only came up with a later code base, and once again, I thought the latest code base was the ep1, one.
    2. Steamappid 212 exists, which is the steamappid for base source engine 2. Now, as I understand it the code base only updates with a new episode/SP game. This implies that 213 will be for ep2 and 214 for ep3. Now, since they are released so far apart it doesnt make sense for steamappid to exist unless the codebase is updated between games using the non client and server dll's, which would retroactively effect steamappid 215 games, which may actually be bad (for example HDR on certain specular shaders is bad) This only makes sense if the codebase updates routinely, between games, but is not applied retroactively even when steamappid 215 is used. But, as far as I know it, the .gcf's are never modified, new ones created yes, but not modified, and the latest one is source sdk base 2.

I probably overthought/overtyped this. I'm sure its really simple, but I havent seen a simple explanation anywhere. Anyone got one for me? Exactly how are standard-valve-made code updates applied to mods dynamically and when? --Mrhappy 00:38, 2 Feb 2007 (PST)

  1. There are two levels of code: engine code and game code. Engine code is updated in lock step for the SDK Base, that is, all engine updates immediately apply to mods; game code is updated when the game it's derived from changed, which isn't as often (look at the last HL2DM update!). Game code updates come as source code that must be merged into the mod's source (if the mod wants to use them).
  2. Engine code is in base source engine 2.gcf. Game code (client.dll and server.dll) is in the game's cache. The two DLLs are in the sdk base cache not because it's a stress test, but because they are the default, pre-compiled files that will be used if you are making a mod without custom code (like MINERVA). Source will see that you don't have code of your own and fall back to whatever's in the SDK Base cache. The same applies to all files.
  3. Valve update Source all the time.
    1. -novirtualmesh is for backwards-compatibility with older maps, AFAIK. Without it you'd need to recompile every map with a displacement in it.
    2. The only reason there is a separate "source engine 2" GCF is because of content issues between HL2 and Ep1. If it weren't for that, there would just be the one source engine.gcf. I would be very surprised if a third instance of Source were to crop up when Ep2 is released.
--TomEdwards 03:17, 2 Feb 2007 (PST)

Ok that makes sense, thank you! (I need to stop tying my brain in knots on stupid things like this.) Mrhappy 20:13, 2 Feb 2007 (PST)

HL2 in Outter Space?

Hello, I have been tearing at HL2 SDK for a while now trying to get a MOD to go into outer space as well as normal mode. I've done many things just short of completely breaking steam :P "sv_gravity 0" gives the no gravity effect, but you cant move. My guess is it's extremely simple or extremely hard. either way I desire to see HL2 in space! Anyone out there have a strategy or tutorial for making a space age level?

--Sir_BigOne 07:28, 25 Mar 2007 (PDT)



You can try creating a new class (cpp file) in the src/dlls directory:

Put this code in a cpp file in src/dlls (i.e. setPlayerPosition.cpp)

#include "cbase.h"
#include "convar.h"

void SetUserPosition( void ){
	CBasePlayer *pPlayer = ToBasePlayer( UTIL_GetCommandClient() );
	if(pPlayer != NULL && (engine->Cmd_Argc() == 3)){
		float x = atof(engine->Cmd_Argv(1));  //Get x coord
		float y = atof(engine->Cmd_Argv(2));  //Get y coord
		float z = atof(engine->Cmd_Argv(3));  //Get z coord

		Vector pos;
		pos = pPlayer->GetAbsOrigin();  //Get player position
		pos.x = x;
		pos.y = y;
		pos.z = z;
		pPlayer->SetAbsOrigin(pos);  //Set player position
	}
}

static ConCommand set_user_position( "set_user_position", SetUserPosition, "Set the user's position (x,y,z)", 0 );

Compile it.

Now you can use the console command set_user_position(0,0,0) to move the player

To do the outer space jetpack, modify this code to increment x,y, or z everytime the command is called. Then bind a keyboard key to the command (using config.cfg)

You can also hack around in in_main.cpp in the src/cl_dll directory. This is where many of the input controls are handled. BE CAREFUL AND BACK UP FILES SO YOU DON'T BREAK YOUR MOD.

Good Luck.

--Steve Henderson 14:41, 27 Mar 2007 (PDT)

MY hammer crashes when I load a blank map NOT COMPILE I have tried reinstalling sdk base and source twice and I am stumped on what to do so can someone please help me Its says this is the error report (C:\DOCUME~1\SEANRA~1\LOCALS~1\Temp\9e03_appcompat.txt) and I cannot find that file

--Sean 14:41, 16 Apr 2007 (PDT)


"func_buyzone" does not exist in entities.

What might be the reason of this? Should I put a buyzone from somewhere else than from the entities menu? Because of this, there is no buyzone in my map, and that's the real problem. --Esa94 06:46, 18 Jun 2007 (PDT)

The func_buyzone entity is a brushbased entity, make sure you're doing "Tie to entity" while having the brush selected. Also make sure the configuration is CS: Source, and that the fgd is properly set. Solokiller 06:51, 18 Jun 2007 (PDT)

Okay, so I make a brush... There. Editing its size... Done too. Now it's tied to buyzone. Now just texturize it... There. Adding team value, cloning, changing team value... All done. Saving, and now (finally) testing. Works perfectly! Thanks a lot.--Esa94 11:35, 18 Jun 2007 (PDT)

HELP!!! NONRESPONSIVE BRUSHES!!!!!

There are four brushes in my map that simply REFUSE to be:

  • Re-textured
  • Deleted

However:

  • If I try to move them, the brushes simply make copies of themselves and make the copies move instead.
  • Resizing gives me the same effect as the above. (Except the brush copy is resized, and not moved)
  • If I Shift-clone them, the copies work just fine!

They have no properties, because they are simply world brushes. Please Help!!!!! --Darthkillyou 20:22, 25 Jul 2007 (PDT)

Oops... It seems that I made many different copies of the same brushes over and over again... right on top of each other. NEVER DO THIS IF YOU CAN HELP IT. I guess I need to be more careful next time. :D --Darthkillyou 16:27, 31 Jul 2007 (PDT)

Weapon editing

Is there any way that I can increase the explosive radius of grenades in a hl2:deathmatch custom map?

-modartist-