Wolf3d Haven Forum

Please log in or register. Smile

Join the forum, it's quick and easy

Wolf3d Haven Forum

Please log in or register. Smile

Wolf3d Haven Forum

Would you like to react to this message? Create an account in a few clicks or log in to continue.
Wolf3d Haven Forum

A friendly Wolfenstein 3D community, about Wolfenstein 3D, the game that gave birth to first person shooters...


2 posters

    [Solved] SDL Bullet Tracing - madenoise trouble

    kkk911
    kkk911
    Don't Hurt Me!
    Don't Hurt Me!


    Male
    Number of posts : 62
    Age : 26
    Location : Hungary
    Hobbie : Modding, Photography, Gaming, collecting scale modells
    Registration date : 2012-03-25

    [Solved] SDL Bullet Tracing - madenoise trouble Empty [Solved] SDL Bullet Tracing - madenoise trouble

    Post by kkk911 Sat Dec 20, 2014 10:01 am

    EDIT: Ohh, man...how much a dumbass i am? xD
    I just would look up to Poet's tutorial related to this, since it contains the answer for this exactly...  No
    Anyway, here is the post:

    Hello there!
    So i've tried out AulmiuN's Bullet Tracing - For SDL! code, which can be found at Diehard Wolfers.
    It worked pretty much, but when i'm tried to make a gun silenced, a little problem came in.

    What i've done is deleting the "madenoise = true;" line from the 'GunAttack" function, then insterting this line to all the weapons, that i don't want to be silenced, like this:
    Code:
    {

        switch (gamestate.weapon)
        {
            case wp_pistol:
                SD_PlaySound (ATKPISTOLSND);
                madenoise = true;
                break;
            case wp_machinegun:
                SD_PlaySound (ATKMACHINEGUNSND);
                madenoise = true;
                break;
            case wp_chaingun:
                SD_PlaySound (ATKGATLINGSND);
                madenoise = true;
                break;
            case wp_rifle:
                SD_PlaySound (SHOOTSND);
                break;
            case wp_rocket:
                SD_PlaySound (MISSILEFIRESND);
                madenoise = true;
                break;
        }

    Now, when i fire with the "rifle", the enemies doesn't hear it, but when i shoot and kill an enemy with it, all the others are starts chasing me. (or they gets alarmed, etc....)

    Is there a way to fix this?


    Last edited by kkk911 on Mon Jan 05, 2015 8:24 am; edited 1 time in total
    ronwolf1705
    ronwolf1705
    Hardcore Wolfer
    Hardcore Wolfer


    Male
    Number of posts : 1252
    Age : 32
    Registration date : 2007-03-26

    [Solved] SDL Bullet Tracing - madenoise trouble Empty Re: [Solved] SDL Bullet Tracing - madenoise trouble

    Post by ronwolf1705 Sat Dec 20, 2014 10:50 am

    In WL_STATE, search for DamageActor. There is a 'madenoise = true' in the DamageActor function that should be deleted. What that line does is that upon hitting an enemy noise is made, therefore enemies get alerted. Deleting that line should fix it.



    [Solved] SDL Bullet Tracing - madenoise trouble MMCS0206
    kkk911
    kkk911
    Don't Hurt Me!
    Don't Hurt Me!


    Male
    Number of posts : 62
    Age : 26
    Location : Hungary
    Hobbie : Modding, Photography, Gaming, collecting scale modells
    Registration date : 2012-03-25

    [Solved] SDL Bullet Tracing - madenoise trouble Empty Re: [Solved] SDL Bullet Tracing - madenoise trouble

    Post by kkk911 Sat Dec 20, 2014 12:10 pm

    Okay, tried it and everything worked fine now!

    Thanks a lot! Smile

    Sponsored content


    [Solved] SDL Bullet Tracing - madenoise trouble Empty Re: [Solved] SDL Bullet Tracing - madenoise trouble

    Post by Sponsored content


      Current date/time is Fri Apr 26, 2024 8:37 pm