No Sound playing in actual Multiplayer help!

Discuss all aspects related to modding Zandronum here.
Post Reply
rico345
 
Posts: 68
Joined: Sun Jul 08, 2012 2:13 pm
Location: Republic Of Korea

No Sound playing in actual Multiplayer help!

#1

Post by rico345 » Sun Aug 11, 2013 10:20 am

As you saw title, only in Multiplayer, some sounds are not playing.
But Singleplayer plays well.

This is code.

Code: Select all

actor "OG7V_Flying_Realistic" : "RPG7_Flying_Realistic"
{
	obituary "%k [OG-7V] %o"
	Speed 40
	
	States
	{
		Explosion :
			TNT1 A 0
			TNT1 A 0 A_PlaySound("EFT/GRNEXP")
			TNT1 A 0 A_Explode(250,300)
			TNT1 AA 0 A_SpawnItemEx("Grenade_MainExplosion_Demolition",0,0,0,0,0,0,0,0,0)
			TNT1 AAAA 0 A_SpawnItemEx("Grenade_Smoke", 0, 0, 0, 0.01 * Random(-125, 125), 0.01 * Random(-125, 125), 0.01 * Random(25, 245), 0, 128, 0)
			TNT1 AAAA 0 A_SpawnItemEx("Grenade_Smoke", 0, 0, 0, 0.01 * Random(-200, 200), 0.01 * Random(-200, 200), 0.01 * Random(25, 245), 0, 128, 0)
			TNT1 AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA 0 A_SpawnItemEx("Grenade_Frag", 0, 0, 24, 0.01 * Random(-300, 300), 0.01 * Random(-300, 300), 0.01 * Random(0, 800), 0, 128, 0)
			TNT1 AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA 0 A_SpawnItemEx("Grenade_Frag", 0, 0, 16, 0.01 * Random(-300, 300), 0.01 * Random(-300, 300), 0.01 * Random(0, 700), 0, 128, 0)
			TNT1 AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA 0 A_SpawnItemEx("Grenade_Frag", 0, 0, 8, 0.01 * Random(-300, 300), 0.01 * Random(-300, 300), 0.01 * Random(0, 600), 0, 128, 0)
			TNT1 AAAAAAAAAAAAAAAAAAAA 0 A_CustomMissile("ExploShrapnel",0,0,random(-180,180),2,random(180,-180))
			TNT1 AAAAAAAAAAAAAAAAAAAA 0 A_CustomMissile("ExploShrapnel",0,0,random(-180,180),2,random(180,-180))
			TNT1 AAAAAAAAAAAAAAAAAAAA 0 A_CustomMissile("ExploShrapnel",0,0,random(-180,180),2,random(180,-180))
			TNT1 A 25 Radius_Quake(9, 30, 0, 15, 0)
			TNT1 A 25 Radius_Quake(4, 30, 0, 15, 0)
			TNT1 A 25 Radius_Quake(2, 30, 0, 15, 0)
			TNT1 A 25 Radius_Quake(1, 30, 0, 15, 0)
			Stop
	}
}
Not just that, others not playing either.
(And they're has similar Death states, using same Explosion sound)

What is the problem? How should fix it?

User avatar
Ænima
Addicted to Zandronum
Posts: 3583
Joined: Tue Jun 05, 2012 6:12 pm

RE: No Sound playing in actual Multiplayer help!

#2

Post by Ænima » Sun Aug 11, 2013 3:22 pm

Use A_PlaySoundEx instead, and give the explosions their own channel.
Reinforcements: midgame Survival joining/respawning
Doom64: Unabsolved: Doom64 + Diablo II
ZandroSkins: a pack made by our community
AeniPuffs: 3D blood and bullet puff effects, free to use for your own mods
Squad Radio: a WASD-based radio chat menu, add your own custom sounds!
Mercenaries (on hold)
Image

rico345
 
Posts: 68
Joined: Sun Jul 08, 2012 2:13 pm
Location: Republic Of Korea

RE: No Sound playing in actual Multiplayer help!

#3

Post by rico345 » Mon Aug 12, 2013 9:27 am

Ænima wrote: Use A_PlaySoundEx instead, and give the explosions their own channel.
Thanks for answer, but still not work.

First, I was used A_PlaySoundEx. But It wans' work, so I changed to
normal A_PlaySound, not work either.

One thing, I can't understand is 5 more actors using same A_PlaySoundEx, but only one is working fine, others not work.

This is first code :

Code: Select all

A_PlaySoundEx("EFT/GRNEXP","CHAN_WEAPON")
And all actors that using same A_PlaySoundEx :

Code: Select all

//Hand Grenade Code. It's working well.
actor Fly_M61Grenade
{
	obituary "%k [M-61 GRENADE] %o"
	DamageType "Explosives"
	radius 5
	height 5
	speed 35
	damage 0
	seesound "EFT/GRNBOUNCE"
	Projectile
	-NOGRAVITY
	+RANDOMIZE
	+DOOMBOUNCE
	+FORCERADIUSDMG
	+CANBOUNCEWATER
	+SOLID
	+REFLECTIVE 
	+FORCEXYBILLBOARD
	Scale 0.04
	gravity 0.6
	bouncefactor 0.4
	
	States
	{
		Spawn:
			FRGX HFEDC 7
			FRGX BA 25
		Death:
			TNT1 A 0 A_PlaySoundEx("EFT/GRNEXP","CHAN_WEAPON")
			TNT1 A 0 A_Explode(500,400)
			TNT1 A 0 A_SpawnItemEx("Grenade_MainExplosion",0,0,0,0,0,0,0,0,0)
			stop
	}
}

//Rockets and 40mm Grenade codes -> These are not working
actor RPG7_Flying_Realistic
{
	Projectile
	obituary "%k [RPG-7] %o"
	//-NOGRAVITY
	//Gravity 0.1
	Scale 0.1
	Speed 20
	Height 5
	Radius 5
	Damage (200)
	DamageType "Explosives"
	//DamageType "ProjectileDirective"
	decal Scorch
	
	States
	{
		Spawn :
			RPGR ZZZZZZZZZ 1
		Armed :
			TNT1 A 0 A_GiveInventory("VAR_GrenadeArmed", 1)
			TNT1 A 0 A_Recoil(-60)
			RPGR Z 1 A_SpawnItemEx("Grenade_Smoke", 0, 0, 0, 0.01 * Random(-125, 125), 0.01 * Random(-125, 125), 0.01 * Random(25, 245), 0, 128, 0)
			RPGR Z 1 A_SpawnItem("ExplosionSmall")
			RPGR Z 1 A_SpawnItemEx("Grenade_Smoke", 0, 0, 0, 0.01 * Random(-125, 125), 0.01 * Random(-125, 125), 0.01 * Random(25, 245), 0, 128, 0)
			RPGR Z 1 A_SpawnItem("ExplosionSmall")
			RPGR Z 1 A_SpawnItemEx("Grenade_Smoke", 0, 0, 0, 0.01 * Random(-125, 125), 0.01 * Random(-125, 125), 0.01 * Random(25, 245), 0, 128, 0)
			RPGR Z 1 A_SpawnItem("ExplosionSmall")
			RPGR Z 1 A_SpawnItemEx("Grenade_Smoke", 0, 0, 0, 0.01 * Random(-125, 125), 0.01 * Random(-125, 125), 0.01 * Random(25, 245), 0, 128, 0)
			RPGR Z 1 A_SpawnItem("ExplosionSmall")
			RPGR Z 1 A_SpawnItemEx("Grenade_Smoke", 0, 0, 0, 0.01 * Random(-125, 125), 0.01 * Random(-125, 125), 0.01 * Random(25, 245), 0, 128, 0)
			RPGR Z 1 A_SpawnItem("ExplosionSmall")
			RPGR Z 1 A_SpawnItemEx("Grenade_Smoke", 0, 0, 0, 0.01 * Random(-125, 125), 0.01 * Random(-125, 125), 0.01 * Random(25, 245), 0, 128, 0)
			RPGR Z 1 A_SpawnItem("ExplosionSmall")
			RPGR Z 1 A_SpawnItemEx("Grenade_Smoke", 0, 0, 0, 0.01 * Random(-125, 125), 0.01 * Random(-125, 125), 0.01 * Random(25, 245), 0, 128, 0)
			RPGR Z 1 A_SpawnItem("ExplosionSmall")
			RPGR Z 1 A_SpawnItemEx("Grenade_Smoke", 0, 0, 0, 0.01 * Random(-125, 125), 0.01 * Random(-125, 125), 0.01 * Random(25, 245), 0, 128, 0)
			RPGR Z 1 A_SpawnItem("ExplosionSmall")
			RPGR Z 1 A_SpawnItemEx("Grenade_Smoke", 0, 0, 0, 0.01 * Random(-125, 125), 0.01 * Random(-125, 125), 0.01 * Random(25, 245), 0, 128, 0)
			RPGR Z 1 A_SpawnItem("ExplosionSmall")
			RPGR Z 1 A_SpawnItemEx("Grenade_Smoke", 0, 0, 0, 0.01 * Random(-125, 125), 0.01 * Random(-125, 125), 0.01 * Random(25, 245), 0, 128, 0)
			RPGR Z 1 A_SpawnItem("ExplosionSmall")
    		TNT1 A 0 ThrustThing((angle*256/360)+(random(-5,5)), 5, 0, 0)
			//TNT1 A 0 ThrustThingZ(0,random(0,5),random(0,1),1)
			goto Armed
		Death :
			TNT1 A 0 
			TNT1 A 0 A_JumpIfInventory("VAR_GrenadeArmed", 1, "Explosion")
			TNT1 A 0 A_SpawnItemEx("RPG7_Fall",0,0,0,0,0,0,0,0,0)
			Stop
		Explosion :
			TNT1 A 0 
			TNT1 A 0 A_PlaySoundEx("EFT/GRNEXP","CHAN_WEAPON")
			TNT1 A 0 A_Explode(500,300)
			TNT1 AA 0 A_SpawnItemEx("Grenade_MainExplosion_Demolition",0,0,0,0,0,0,0,0,0)
			Stop
	}
}

actor 40mm_Flying
{
	Projectile
	obituary "%k [M16A3 M203] %o"
	-NOGRAVITY
	Gravity 0.4
	Scale 0.03
	Speed 60
	Height 5
	Radius 5
	Damage (40)
	DamageType "Explosives"
	decal Scorch
	
	States
	{
		Spawn :
			2031 A 1 //A_SpawnItemEx("Grenade_Smoke", 0, 0, 0, 0.01 * Random(-125, 125), 0.01 * Random(-125, 125), 0.01 * Random(25, 245), 0, 128, 0)
			2031 A 1 //A_SpawnItemEx("Grenade_Smoke", 0, 0, 0, 0.01 * Random(-125, 125), 0.01 * Random(-125, 125), 0.01 * Random(25, 245), 0, 128, 0)
			2031 A 0 A_GiveInventory("VAR_GrenadeArmed", 1)
			Loop
		Death :
			TNT1 A 0 
			TNT1 A 0 A_JumpIfInventory("VAR_GrenadeArmed", 1, "Explosion")
			TNT1 A 0 A_SpawnItemEx("40mm_Fall",0,0,0,0,0,0,0,0,0)
			Stop
		Explosion :
			TNT1 A 0
			TNT1 A 0 A_PlaySoundEx("EFT/GRNEXP","CHAN_WEAPON")
			TNT1 A 0 A_Explode(70,400)
			TNT1 AA 0 A_SpawnItemEx("Grenade_MainExplosion",0,0,0,0,0,0,0,0,0)
			Stop
	}
}

User avatar
Ænima
Addicted to Zandronum
Posts: 3583
Joined: Tue Jun 05, 2012 6:12 pm

RE: No Sound playing in actual Multiplayer help!

#4

Post by Ænima » Mon Aug 12, 2013 12:43 pm

Why are you using the weapon channel?

If you don't want sounds to interrupt each other, they have to all go on different channels. Putting everything on CHAN_WEAPON defeats the purpose of using A_PlaySoundEx.
Last edited by Ænima on Mon Aug 12, 2013 12:44 pm, edited 1 time in total.
Reinforcements: midgame Survival joining/respawning
Doom64: Unabsolved: Doom64 + Diablo II
ZandroSkins: a pack made by our community
AeniPuffs: 3D blood and bullet puff effects, free to use for your own mods
Squad Radio: a WASD-based radio chat menu, add your own custom sounds!
Mercenaries (on hold)
Image

rico345
 
Posts: 68
Joined: Sun Jul 08, 2012 2:13 pm
Location: Republic Of Korea

RE: No Sound playing in actual Multiplayer help!

#5

Post by rico345 » Mon Aug 12, 2013 1:05 pm

Ænima wrote: Why are you using the weapon channel?

If you don't want sounds to interrupt each other, they have to all go on different channels. Putting everything on CHAN_WEAPON defeats the purpose of using A_PlaySoundEx.
I used another way to solve this problem.
Thanks to help !!

User avatar
Ænima
Addicted to Zandronum
Posts: 3583
Joined: Tue Jun 05, 2012 6:12 pm

RE: No Sound playing in actual Multiplayer help!

#6

Post by Ænima » Mon Aug 12, 2013 1:12 pm

You're welcome. @_@
Reinforcements: midgame Survival joining/respawning
Doom64: Unabsolved: Doom64 + Diablo II
ZandroSkins: a pack made by our community
AeniPuffs: 3D blood and bullet puff effects, free to use for your own mods
Squad Radio: a WASD-based radio chat menu, add your own custom sounds!
Mercenaries (on hold)
Image

Lollipop
Zandrone
Posts: 1124
Joined: Tue Jul 24, 2012 10:34 am
Location: Denmark

RE: No Sound playing in actual Multiplayer help!

#7

Post by Lollipop » Mon Aug 12, 2013 1:57 pm

And when someone finds a way they should post it, instead of just sticking it to themselfes, as others who then read this might no thave to ask the very same question to find the way rico found -.-
Combinebobnt wrote:i can see the forum league is taking off much better than the ctf ones
GalactusToday at 1:07 PM
are you getting uncomfortable jap
feeling something happen down there

false_chicken
 
Posts: 36
Joined: Sat Aug 09, 2014 10:47 pm

RE: No Sound playing in actual Multiplayer help!

#8

Post by false_chicken » Thu Dec 25, 2014 10:29 pm

I ran into this same problem and was sad to see no solution posted here. Sorry to bring this back from the dead but I found a solution that worked for me. I created a new actor that played a sound when it spawned and did nothing else (Stopped) and spawned said actor on the death of the target actor like so:

Sound "Actor":

Code: Select all

actor TargetShotSound
{
 radius 1
 height 1
 +noclip
 States
 {
 Spawn:
  TNT1 A 0
  TNT1 A 1 A_PlaySound("generic/headshot2")
  stop
 }
}
Target Actor: (One you want to play the sound.)

Code: Select all

actor Target_Nazi 14698
{
  Health 1
  Radius 16
  Height 48
  Speed 9
  PainChance 200
  Monster
  +FLOORCLIP
 States
  {
  Spawn:
    WW2A A 5
    Loop
  Pain:
	Goto Death
  Death:
    WW2A A 0 A_SpawnItemEx("TargetShotSound",0,0,0,0,0,0,0,0,0) //<- Sound played like this.
    Stop
  }
}
Hopefully someone else will see this and it will be of use. I do not know why the death sounds are not played properly in multiplayer but this work around works for me.

Post Reply