Importing HL2 Weapon Skins and models into Black Mesa?

    This site uses cookies. By continuing to browse this site, you are agreeing to our Cookie Policy.

    Logging in with you Steam ID has now been restored ♥

    • Importing HL2 Weapon Skins and models into Black Mesa?

      I thought It could be beneficial to explore this topic with people far more knowlageable than myself.

      Basically there are alot of skins available for Half Life 2 models that I would perhaps like to use in Black Mesa.

      But there are issues with porting over models and their animations apparently because of.

      1, The field of view is completely different

      2. The Hands model is rigged differently

      3. The Physics are server side (That's why grenades don't act like they do in Half Life 2)

      Now seeing as the Magnum and crow bar are using the same model from Half Life 2 then surely it is possible to port over the weapon models? and use either originals or re-skins

      Also is it possible to port over the hands model from Half life 2 out of curiosity and will this work with the current animations that are in place in Black mesa such as the glock idle animation and the crossbow animations.

      Basically I just want to know how it can be done or if it can be done... There is a lot of good skins out there already available and would be a shame to lose these as a resource for re-skining weapons or reverting to Half life 2 defaults.

      can you force physics client side via a cvar and see what effect this has on the game?

      anyone know about this stuff?
    • Ronster wrote:

      can you tell me how to do this?

      what is the command?

      and does it display correctly?


      The weapon's script files are here: '<Steam Installation Path>\SteamApps\sourcemods\BMS\scripts'

      Each file should be named accordingly; for the crowbar, open the file 'weapon_crowbar.txt' with a text-editor.

      -----

      To change the FOV, just add the line below to the script file.

      Add this line:

      Source Code

      1. fov "{VALUE}"

      Note: Replace {VALUE} with any (valid) value (55 or 75 or 95, ecetera).


      Reference (weapon_crowbar.txt):

      Source Code

      1. WeaponData
      2. {
      3. printname "Crowbar"
      4. bucket "0"
      5. bucket_position "0"
      6. item_flags "0"
      7. playermodel "models/weapons/w_crowbar.mdl"
      8. viewmodel "models/weapons/v_crowbar.mdl"
      9. weight "0"
      10. anim_prefix "crowbar"
      11. fov "65"
      12. SoundData
      13. {
      14. melee_hit "weapon_crowbar.Melee_Hit"
      15. melee_miss "weapon_crowbar.Melee_Miss"
      16. }
      17. }
      Display All


      -----

      The default setting should be (correct me if I'm wrong, of course):

      Source Code

      1. fov "54"



      To reset it back to default, just remove the line, you previously added, entirely.

      The post was edited 1 time, last by Jenova19 ().

    • so importing from HL2 the FOV is 65 to correct this...

      Will this give me the animations from HL2 for the crowbar?

      after importing the .mdl and associated files.

      *** UPDATE ***

      I now have an invisible crowbar

      why is the crowbar nor rendering from HL2 in BMS it is the same model?

      And the arms jave disappeared for this too?

      Does anyone know how to import the HL2 animations only so they render

      The post was edited 3 times, last by Ronster ().

    • Ok going to bump this one...

      Importing the crowbar .mdl from Half life 2 in Black Mesa source made the weapon and the hands invisible.

      Why is this and no matter what FOV number I put in the script.txt for the crowbar it would not appear in Black Mesa.

      If it is the same model why does it now not render?

      Is it to do with the camera set up at the point of creation in the .mdl?

      Honestly I don't understand this at all but know skin swapping is easy but this is a bit more complicated

      The post was edited 1 time, last by Ronster ().

    • Thanks for trying this out... I am really lost on this

      I forgot to copy the original .mdl so have to re-install BM now... Nevermind though

      Basically there has to be a formula to porting over the weapons from HL2 to Black Mesa but I think the Model needs decompiling from HL2 then recompiled under Black Mesa Settings?

      Basically I would like to see a MOD that can bring these settings

      1 Better Animated Crowbar (or Original HL2 or other well animated crowbar)
      2.Shotgun with a stock
      3.Improved MP5 animations
      4.Half Life 2 Grenades but reskinned
      5. Headcrab physics the same as HL2
      6. Crossbow zoom/scoped the same as HL2 but with BM overlay
      7. Relevant sound and skin improvements
      8. Change the crosshair to Half life 2 Crosshair

      This would be the dogs if these things can be changed

      The post was edited 4 times, last by Ronster ().

    • Ronster wrote:

      -Snip-

      Basically there has to be a formula to porting over the weapons from HL2 to Black Mesa but I think the Model needs decompiling from HL2 then recompiled under Black Mesa Settings?


      Yeah, I tried de- and re-compiling it both either way (using StudioCompiler), but neither seemed to work...

      (The viewmodels are completely invisible.)

      Maybe I am doing something wrong here?

      It could have something to do with the way the .qc file's set up.

      Anyway, I'll try it again, while paying attention to what I actually do, then report back with the results.
    • Do you know anything about Changing the physics properties of npc_headcrab and grenade_phy

      Basically they are now server side where as in HL2 they were client side... Is there a command that can change this in the scripts for grenades and headcrab classic?

      I assume the same scaling settings have been applied to npc's also? or can it be a straihjt swap on this to change the physics info?

      Some suggestions of models to use

      Crowbar original

      shotgun by lamarr
      gamebanana.com/hl2ep2/skins/47835

      Grenade by Kaskad MKII Grenade

      Or even swap out the MP5 for the M4 or import the AR2 with a M4 Skin

      Obviously getting there permission first if a pack could be made

      The post was edited 4 times, last by Ronster ().

    • Ok, so I managed to get the HL2 crowbar into BMS, including HL2's animations, although it looks a bit weird (in terms of surface properties - it looks like some sort of plastic).

      Adjusting the fov via the script file did work, as well.

      I'll take a look at the .vmt files and see if I can somehow change the overall 'plastically' looking textures.

      -----

      EDIT (08 : 35 AM): Imported the shotgun (SPAS-12) model you posted into BMS, including it's materials and sounds - it seems to be working, but the muzzle-flash is missing, unfortunately.

      If you want to try it yourself, don't forget to rename the sound files (.wav) to the corresponding files BMS uses (based on hearing), before copy and pasting or moving them into BMS' folder.

      Listen to them first, then rename them, if they 'match'.

      -----

      Also, would you mind telling what exactly you are trying to accomplish by changing the physic's properties (are you trying to use HL2's physics, etc.)?

      The post was edited 5 times, last by Jenova19 ().

    • Jenova19 wrote:

      Ok, so I managed to get the HL2 crowbar into BMS, including HL2's animations, although it looks a bit weird (in terms of surface properties - it looks like some sort of plastic).

      Adjusting the fov via the script file did work, as well.

      I'll take a look at the .vmt files and see if I can somehow change the overall 'plastically' looking textures.

      -----

      EDIT (08 : 35 AM): Imported the shotgun (SPAS-12) model you posted into BMS, including it's materials and sounds - it seems to be working, but the muzzle-flash is missing, unfortunately.

      If you want to try it yourself, don't forget to rename the sound files (.wav) to the corresponding files BMS uses (based on hearing), before copy and pasting or moving them into BMS' folder.

      Listen to them first, then rename them, if they 'match'.

      -----

      Also, would you mind telling what exactly you are trying to accomplish by changing the physic's properties (are you trying to use HL2's physics, etc.)?


      Was it a straight copy for the shotgun or did you have to decompile and recompile adjusting this?

      As for the Crowbar seems like the issue is with the way the hands are rigged... Texture problems might be to do with DX level or HDR / reflective surface perhasps? missing the hdri environment As for the hands sounds like it would need to be rigged to the animation.

      the npc headcrab physics stuff... The Headcrab now does not behave the same under physics properties and is forced server side... I want to bring this back over to client side... Wondered if it can be done either in the model properties or .phy or a script file with a command

      This also seems to apply to genades and wondered if it can be forced client side like the headcrab see what effect it has?

      Basically the threshold is higher on server side physics in relation to damage and it's physics effects

      got any pics?

      The post was edited 2 times, last by Ronster ().

    • Ronster wrote:

      Was it a straight copy for the shotgun or did you have to decompile and recompile adjusting this?


      Just a copypasta (from the 'correct\folded' archive).

      -----

      Ronster wrote:

      the npc headcrab physics stuff... The Headcrab now does not behave the same under physics properties and is forced server side... I want to bring this back over to client side... Wondered if it can be done either in the model properties or .phy or a script file with a command

      This also seems to apply to genades and wondered if it can be forced client side like the headcrab see what effect it has?

      Basically the threshold is higher on server side physics in relation to damage and it's physics effects


      Sorry, can't help you with this one, as much as I'd like to. :(

      (It's probably handled in a hardcoded way and thus takes its instructions from one of the .dll files [client.dll or server.dll would be my bet, I could be wrong, though])

      I could be wrong on this one, so if you want to try something out - copy and paste 'headcrabclassic.phy' from the 'source models.gcf' GCF archive into BMS' models folder, then rename it to 'headcrab.phy' and see if it does anything useful.

      -----

      Ronster wrote:

      got any pics?


      Yes, just one (using the imported SPAS-12 model), though.

      Shotgun Screenshot (using 'Lamarr's Spas 12 Redux'):



      Note: Ignore the text in the top left corner, forgot to wipe the HUD from unnecessary things, before taking the screenie (apologies for that)...

      Note 2: The image is slightly edited, since it appeared relatively dark.

      -----

      The shotgun seems to be working just fine, even the sounds do, but as I said before - the muzzleflash is missing entirely.

      The post was edited 2 times, last by Jenova19 ().

    • ok thats interesting... You changed the FOV for the shotgun in the script I would imagine what number did you use if so?

      I am going to try to replace the .phy file for the headcrab and some other stuff see what happens now I have ruined my crowbar model may aswell use this install to mess about and start from scratch again when I have figured stuff out.

      wonder why the muzzle flash is gone it is a sprite set to a co-ordinate so perhaps the co-ordinate needs changing?

      Could you upload a pic of what the crow bar actually looks like?

      I have a friend who does animation professionally and going to try to persuade him to do a reanimation on the crowbar as a portfolio project... Perhaps he will agree but he will have to want to do it so can only try to nudge him and try to persuade him it would be a good idea. Fingers crossed

      I am sure he can rig it and improve it... Example of his work on this link

      vimeo.com/38433740

      I am sure you are right about the .dll I wonder if you can force a specific entity client side though or the infomation is in the .phy will soon see :)

      The post was edited 2 times, last by Ronster ().

    • EDIT (02:10 PM):

      Here, have a screenshot:



      Note: Using HL2's model and textures, as well as not specifying a custom fov value.

      Note 2: Turned up the brightness again, just to make it much more visible.

      -----

      Ronster wrote:

      ok thats interesting... You changed the FOV for the shotgun in the script I would imagine what number did you use if so?


      Thought I didn't touch the fov value at first, but as it turns out, I did (must've edited it previously, to test something):

      Source Code

      1. fov "50"


      -----

      Ronster wrote:

      wonder why the muzzle flash is gone it is a sprite set to a co-ordinate so perhaps the co-ordinate needs changing?


      As far as I have seen, while experimenting with different assets of Black Mesa, the muzzleflash is handled by the particle system (.pcf file type).

      -----

      Ronster wrote:

      Could you upload a pic of what the crow bar actually looks like?


      Just a second, I'll have to revert the fov back to default, since I put it all the way up to 270 (causing the viewmodel to be upside down), just to see if the import did work.

      -----

      Ronster wrote:

      I have a friend who does animation professionally and going to try to persuade him to do a reanimation on the crowbar as a portfolio project... Perhaps he will agree but he will have to want to do it so can only try to nudge him and try to persuade him it would be a good idea. Fingers crossed

      I am sure he can rig it and improve it... Example of his work on this link

      -Link_Snipped-


      Good luck on that one. :)

      The post was edited 3 times, last by Jenova19 ().

    • What is weird about this is it rigs the hand to the mini crowbar because it is the same model so I gues if you specify a custom fov then does the hand grow in size also?

      I cannot understand why It did not work for me is there any other files apart from Model and the materials forgetting the sound that i need to import over?

      Thanks alot for all this help Jen I really appreciate it.

      Changing over the .Phy file does not seem to have any unusual effects I think it does make physics a bit more resposive but I have edited my config so going to revert back to defaults and give another try now

      *** UPDATE ***

      Replacing the .phy of the headcrab from HL2 puts it's physics back client side

      So probably safe to assume that this is the same for the world model grenade so making some headway here

      The post was edited 1 time, last by Ronster ().

    • Dare I ask, but where do you take the HL2 files from?

      ('source models.gcf' and 'source materials.gcf' would be the correct answer.)

      You need GCFScape to open and extract from .gcf containers, in case you didn't know.

      -----

      EDIT (02:47 PM):

      Questions aside, all I did was copy and pasting the files, I previously extracted from the GCF archives, into the BMS folders ('<Steam Installation Path>\sourcemods\BMS\materials\models\weapons\v_crowbar' and '<Steam Installation Path>\sourcemods\BMS\models\weapons').

      Don't know why the forum splits the text between v_cr and owbar there, by the way...

      The post was edited 8 times, last by Jenova19 ().

    • Jenova19 wrote:

      Dare I ask, but where do you take the HL2 files from?

      ('source models.gcf' and 'source materials.gcf' would be the correct answer.)

      You need GCFScape to open and extract from .gcf containers, in case you didn't know.

      -----

      EDIT (02:47 PM):

      Questions aside, all I did was copy and pasting the files, I previously extracted from the GCF archives, into the BMS folders ('<Steam Installation Path>\sourcemods\BMS\materials\models\weapons\v_crowbar' and '<Steam Installation Path>\sourcemods\BMS\models\weapons').

      Don't know why the forum splits the text between v_cr and owbar there, by the way...


      Yeah thats what I did but perhaps I did the wrong thing by putting the dx7 model too so if I delete this it might work... Could be somthing to do with it.

      The .phy replacement works on the headcrab :)
    • Ronster wrote:

      Yeah thats what I did but perhaps I did the wrong thing by putting the dx7 model too so if I delete this it might work... Could be somthing to do with it.

      The .phy replacement works on the headcrab :)


      It's funny how these things are usually a case of constant trial and error, but I guess that's how you learn new things. :D

      The post was edited 1 time, last by Jenova19 ().

    • so if you change the FOV does this fix the crowbar in the script for size or does it act weird?

      ***Updated****

      Ok no if you change the field of view to 54 it looks normal but you lose the blood from the crow bar.

      Is this part of the texture? Like a feature set of the texture?

      As it is the same model I wonder if only changing the materials to the BMS ones will enable the blood back on the crowbar model?

      I have lost these files can you try this one out?

      Also I assume the shotgun you put in no longer has blood on it I wonder if this an alpha skin on top or something?

      The post was edited 3 times, last by Ronster ().