by Niphura » Fri May 18, 2018 5:27 pm
m8f wrote: I don't know how it is implemented in Brutal Doom, but this is how it's done in Complex Doom:
Spoiler:1. First, a gun fires bullets with custom puff:
Weapons.dec:
Code: Select all
SHTF A 2 Bright A_FireBullets(3.8,2.4,7,Random(5,7),"ModdedBulletPuff")
2. Then the puff spawns two actors that check for floor and ceiling (DetectFloorPuff, DetectCeilingPuff).
SFX.dec:
Code: Select all
...
ACTOR ModdedBulletPuff replaces BulletPuff
{
Radius 0
Height 0
Scale 0.75
RenderStyle Translucent
Alpha 0.5
+NOBLOCKMAP
+NOGRAVITY
+ALLOWPARTICLES
States
{
Spawn:
TNT1 A 0
TNT1 A 0 A_SpawnItemEx("DetectFloorPuff",0,0,0,0,0,0,0,SXF_NOCHECKPOSITION|SXF_CLIENTSIDE)
TNT1 A 0 A_SpawnItemEx("DetectCeilingPuff",0,0,0,0,0,0,0,SXF_NOCHECKPOSITION|SXF_CLIENTSIDE)
...
3. Then DetectFloorPuff checks floor, and if it is on floor, spawns an actor that looks like a decal (FloorPuffDecal).
DetectCeilingPuff does the same thing, but for ceiling.
Code: Select all
ACTOR DetectFloorPuff
{
Radius 1
Height 4
+MISSILE
+NOTELEPORT
+NOBLOCKMAP
+THRUACTORS
+MOVEWITHSECTOR
+NODAMAGETHRUST
-DONTSPLASH
States
{
Spawn:
TNT1 A 4
Stop
Death:
TNT1 A 0 A_CheckFloor("FloorPuff")
Stop
FloorPuff:
TNT1 A 0 A_SpawnItemEx("FloorPuffDecal",0,0,0,0,0,0,0,SXF_NOCHECKPOSITION|SXF_CLIENTSIDE)
Stop
}
}
What does this line mean? SXF_NOCHECKPOSITION|SXF_CLIENTSIDE, it´s necessary to put it if i define a different Actor decal?
Also...how would the Decal actor look like?
[quote="m8f"]I don't know how it is implemented in Brutal Doom, but this is how it's done in Complex Doom: [spoiler]1. First, a gun fires bullets with custom puff: Weapons.dec: [code]SHTF A 2 Bright A_FireBullets(3.8,2.4,7,Random(5,7),"ModdedBulletPuff")[/code] 2. Then the puff spawns two actors that check for floor and ceiling (DetectFloorPuff, DetectCeilingPuff). SFX.dec: [code] ... ACTOR ModdedBulletPuff replaces BulletPuff { Radius 0 Height 0 Scale 0.75 RenderStyle Translucent Alpha 0.5 +NOBLOCKMAP +NOGRAVITY +ALLOWPARTICLES States { Spawn: TNT1 A 0 TNT1 A 0 A_SpawnItemEx("DetectFloorPuff",0,0,0,0,0,0,0,SXF_NOCHECKPOSITION|SXF_CLIENTSIDE) TNT1 A 0 A_SpawnItemEx("DetectCeilingPuff",0,0,0,0,0,0,0,SXF_NOCHECKPOSITION|SXF_CLIENTSIDE) ...[/code] 3. Then DetectFloorPuff checks floor, and if it is on floor, spawns an actor that looks like a decal (FloorPuffDecal). DetectCeilingPuff does the same thing, but for ceiling. [code]ACTOR DetectFloorPuff { Radius 1 Height 4 +MISSILE +NOTELEPORT +NOBLOCKMAP +THRUACTORS +MOVEWITHSECTOR +NODAMAGETHRUST -DONTSPLASH States { Spawn: TNT1 A 4 Stop Death: TNT1 A 0 A_CheckFloor("FloorPuff") Stop FloorPuff: TNT1 A 0 A_SpawnItemEx("FloorPuffDecal",0,0,0,0,0,0,0,SXF_NOCHECKPOSITION|SXF_CLIENTSIDE) Stop } }[/code][/spoiler][/quote] What does this line mean? SXF_NOCHECKPOSITION|SXF_CLIENTSIDE, it´s necessary to put it if i define a different Actor decal? Also...how would the Decal actor look like?