Facebook Twitter YouTube Frictional Games | Forum | Privacy Policy | Dev Blog | Dev Wiki | Support | Gametee


Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Script help!
SilentStriker Offline
Posting Freak

Posts: 950
Threads: 26
Joined: Jul 2011
Reputation: 43
#2
RE: Script help!

Well rename all the pigs with the same name for example pig_1, pig_2 etc then use this script

The bolded 10 is how many pigs you have so if you have 5 change it to 5 if you have 15 then change the 10 to 15 etc Smile
PHP Code: (Select All)
void OnStart()
{
for(
int i=0;i<10;i++) SetEntityPlayerInteractCallback("Pig_"+i"PigSound"false);
}

void PigSound(string &in asEntity)
{
PlaySoundAtEntity("""NAMEOFSOUND"asEntity0false);
//Put other things here if you want


This is the code pretty much Smile

06-10-2012, 10:23 AM
Find


Messages In This Thread
Script help! - by Clear - 06-10-2012, 10:09 AM
RE: Script help! - by SilentStriker - 06-10-2012, 10:23 AM
RE: Script help! - by Clear - 06-10-2012, 10:26 AM
RE: Script help! - by SilentStriker - 06-10-2012, 10:45 AM
RE: Script help! - by Clear - 06-10-2012, 04:01 PM
RE: Script help! - by SilentStriker - 06-10-2012, 04:13 PM
RE: Script help! - by FlawlessHappiness - 06-10-2012, 04:22 PM
RE: Script help! - by SilentStriker - 06-10-2012, 04:25 PM
RE: Script help! - by Clear - 06-12-2012, 04:02 PM
RE: Script help! - by CorinthianMerchant - 06-12-2012, 04:11 PM
RE: Script help! - by Clear - 06-12-2012, 05:00 PM
RE: Script help! - by CorinthianMerchant - 06-12-2012, 07:35 PM
RE: Script help! - by Adny - 06-12-2012, 05:07 PM



Users browsing this thread: 6 Guest(s)