google-site-verification: googlebaca44933768a824.html Headshot = Headshot.mp3 - Old Royal Hack Forum

Announcement

Collapse
No announcement yet.

Headshot = Headshot.mp3

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

    Headshot = Headshot.mp3

    How do i make if i headshot a guy , it plays mp3 file -> Headshot.mp3 , its smth to doo with GameEvent...

    #2
    I dont know if Source Engine can play mp3's... but EmitSound is what they use for playing sounds I THINK. You could try to hook it with detours or you could hook EmitSound of IVENGINESOUND interface. OR you could be ghetto and use WinAPI

    PlaySound

    It supports *.wav files only.

    And yeah, you need Game Event Manager to find out if shot was headshot or you can do it with offset too or whateveeeeeeeeeeeeeer.
    lolmaoman: Germans are born with a lifetime x22 login engraved into their birth certificates. True story.
    I DONT HAVE TEAMVIEWER AND IM NOT GOING TO GIVE ANY 24/7 ONLINE SUPPORT VIA STEAM, XFIRE OR OTHER IM PROGRAMS SO DONT BOTHER ASKING. THANKS.

    Comment


      #3
      Register player_death, check for headshot event var and play that file via WinAPI or an external MP3 class.

      Comment


        #4
        Originally posted by ir0nic View Post
        Register player_death, check for headshot event var and play that file via WinAPI or an external MP3 class.
        Yeah, incase Source Engine wont support *.mp3 files you need some third party mp3 class but i guess that it wont matter at this case if you use *.wav or *.mp3 so i guess PlaySound() would be easiest solution.
        lolmaoman: Germans are born with a lifetime x22 login engraved into their birth certificates. True story.
        I DONT HAVE TEAMVIEWER AND IM NOT GOING TO GIVE ANY 24/7 ONLINE SUPPORT VIA STEAM, XFIRE OR OTHER IM PROGRAMS SO DONT BOTHER ASKING. THANKS.

        Comment


          #5
          I do think the engine supports mp3, most say sounds on servers are in mpeg format - also standard quakesounds from Mani are in mp3.

          Comment


            #6
            Search SDK for "PlaySound" and you find multiple references. Theres plenty of stuff.
            lolmaoman: Germans are born with a lifetime x22 login engraved into their birth certificates. True story.
            I DONT HAVE TEAMVIEWER AND IM NOT GOING TO GIVE ANY 24/7 ONLINE SUPPORT VIA STEAM, XFIRE OR OTHER IM PROGRAMS SO DONT BOTHER ASKING. THANKS.

            Comment

            Working...
            X