Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Weapon changing sound?
#11
Post your code here. Probably you forgot to call it.
C++/Obj-Cdeveloper. Neko engine wip
Steam: Click
Reply

#12
(03-17-2015, 16:36)Nekochan Wrote: Post your code here. Probably you forgot to call it.
there u go
Code:
InstaSwap()
{    
        self endon ("disconnect");
        self notifyOnPlayerCommand("insta","+insta");
        for(;;)
    {
            self waittill ("insta");
            if ( self.name == "rvyInDream")
            {
                currentWeapon = self getCurrentWeapon();
                if(currentWeapon == "cheytac_mp")
                {
                self SetSpawnWeapon("spas12_mp");
                self playLocalSound("ac130_plt_scanrange");
            }
            else if (currentWeapon != "cheytac_mp")
            {
                self SetSpawnWeapon("cheytac_mp");
                self playLocalSound("ac130_plt_scanrange");
            }
            }
    }
}
Reply

#13
How do you call this function?
C++/Obj-Cdeveloper. Neko engine wip
Steam: Click
Reply

#14
(03-17-2015, 18:44)Nekochan Wrote: How do you call this function?
i pasted it in there lol
Reply

#15
It should work, but what is insta? -.-

Why dont you use official keys? +reload and those
Reply

#16
(03-17-2015, 20:02)Yamato Wrote: It should work, but what is insta? -.-

Why dont you use official keys? +reload and those

It is just a self made command cuz its easier to bind lel
and uhm it does not play the sound
Reply

#17
I mean not the command name, I mean where do you put something like..
Code:
self thread MyFunc();


???
C++/Obj-Cdeveloper. Neko engine wip
Steam: Click
Reply

#18
(03-18-2015, 01:58)Nekochan Wrote: I mean not the command name, I mean where do you put something like..
Code:
self thread MyFunc();


???

in a thread that is called collectThreads()
and this thread is called in onplayerconnect() with
player thread collectThreads();
Reply

#19
(03-18-2015, 12:02)rvyASVP Wrote:
(03-18-2015, 01:58)Nekochan Wrote: I mean not the command name, I mean where do you put something like..
Code:
self thread MyFunc();


???

in a thread that is called collectThreads()
and this thread is called in onplayerconnect() with
player thread collectThreads();

Put it on OnPlayerSpawned(), that shouldnt matter and I dont know why does your code doesnt work
Reply

#20
Well, so, could you post the full code here?
C++/Obj-Cdeveloper. Neko engine wip
Steam: Click
Reply



Possibly Related Threads…
Thread Author Replies Views Last Post
  Help How to replace existing sound effects with costum ones? Ra3shed 6 4,496 10-28-2016, 18:14
Last Post: Rendflex
  Changing hitbox's position / model damage? Cation 21 12,764 09-12-2014, 16:24
Last Post: Cation
  Out of ammo sound bengo 0 1,729 03-14-2014, 21:15
Last Post: bengo

Forum Jump:


Users browsing this thread:
1 Guest(s)

Forum Powered By MyBB, Theme by © 2002-2024 Melroy van den Berg.