First of all, this is not completely converted to ZScript. You have missing semicolons, a missing Default block and the syntax to define your class is using Decorate's method:
Code: Select all
ACTOR NewShotgun : Weapon replaces Shotgun //This should read as Class instead of ACTOR
{
//Default block should start here for your properties
Weapon.SelectionOrder 1300
Weapon.AmmoUse 1
Weapon.AmmoGive 8
Weapon.AmmoType "Shell"
Inventory.PickupMessage "$GOTSHOTGUN"
Obituary "$OB_MPSHOTGUN"
//Default block should end here
States
{
Ready:
TNT1 A 0 A_JumpIf(GetCvar("ENTRY_smooth") == 1, "Ready_NoSmooth")
ESH1 A 1 A_WeaponReady
Loop
Ready_NoSmooth:
TNT1 A 0 A_JumpIf(GetCvar("ENTRY_smooth") == 0, "Ready")
SHTG A 1 A_WeaponReady
Loop
Deselect:
TNT1 A 0 A_JumpIf(GetCvar("ENTRY_smooth") == 1, "Deselect_NoSmooth")
ESH1 A 1 A_Lower
NULL AA 0 A_Lower
Loop
Deselect_NoSmooth:
TNT1 A 0 A_JumpIf(GetCvar("ENTRY_smooth") == 0, "Deselect")
SHTG A 1 A_Lower
NULL AA 0 A_Lower
Loop
Select:
TNT1 A 0 A_JumpIf(GetCvar("ENTRY_smooth") == 1, "Select_NoSmooth")
ESH1 A 1 A_Raise
NULL AA 0 A_Raise
Loop
Select_NoSmooth:
TNT1 A 0 A_JumpIf(GetCvar("ENTRY_smooth") == 0, "Select")
SHTG A 1 A_Raise
NULL AA 0 A_Raise
Loop
Fire:
TNT1 A 0 A_JumpIf(GetCvar("ENTRY_smooth") == 1, "Fire_NoSmooth")
TNT1 A 0 A_JumpIfInventory("Powersync_thecrusible",1,"Fire_Speed")
ESH1 A 3
ESH1 B 2 BRIGHT {
A_FireBullets (4.8, 1.9, 7, 8, "BulletPuff");
A_SetPitch(pitch-0.5);
A_PlaySound("weapons/shotgf",CHAN_WEAPON);
}
ESH1 CD 2 BRIGHT A_SetPitch(pitch-0.25)
ESH1 E 1 BRIGHT A_SetPitch(pitch+0.25)
ESH1 F 2 A_SetPitch(pitch+0.25)
ESH1 GH 1 A_SetPitch(pitch+0.25)
ESH1 IJKLM 1 A_SetRoll(roll-0.24)
ESH1 N 1 A_SetPitch(pitch+0.25)
ESH1 OP 2 A_SetPitch(pitch+0.25)
ESH1 Q 1 { A_FireCustomMissile("ShotShell",random(-20,-60),False,10); A_SetPitch(pitch-0.25); }
ESH1 R 2 A_SetPitch(pitch-0.25)
ESH1 S 1 A_SetPitch(pitch-0.25)
ESH1 TUVWX 1 A_SetRoll(roll+0.24)
ESH1 YZ 1
ESH1 A 1
ESH1 A 7 A_ReFire
Goto Ready
Fire_Speed:
TNT1 A 0 A_JumpIf(GetCvar("ENTRY_smooth") == 1, "Fire_NoSmooth")
ESH1 A 3
ESH1 B 2 BRIGHT {
A_FireBullets (4.8, 1.9, 10, 5, "BulletPuff");
A_PlaySound ("weapons/shotgf", CHAN_WEAPON);
A_SetPitch(pitch-0.5);
}
ESH1 C 2 BRIGHT A_SetPitch(pitch-0.5)
ESH1 E 1 BRIGHT A_SetPitch(pitch+0.25)
ESH1 F 2 A_SetPitch(pitch+0.25)
ESH1 G 1 A_SetPitch(pitch+0.5)
ESH1 IKM 1 A_SetRoll(roll-0.48)
ESH1 N 1 A_SetPitch(pitch+0.25)
ESH1 OP 2 A_SetPitch(pitch+0.25)
ESH1 Q 1 { A_FireCustomMissile("ShotShell",random(-20,-60),False,10); A_SetPitch(pitch-0.25); }
ESH1 R 2 A_SetPitch(pitch-0.25)
ESH1 S 1 A_SetPitch(pitch-0.25)
ESH1 TUW 1 A_SetRoll(roll+0.48)
ESH1 YZ 1
ESH1 A 4
ESH1 A 7 A_ReFire
Goto Ready
Fire_NoSmooth:
SHTG A 3
SHTG A 7 {
A_FireBullets (5.6, 0, 8, 5, "BulletPuff");
A_PlaySound ("weapons/shotgf", CHAN_WEAPON);
A_GunFlash;
}
SHTG BC 5
SHTG D 4 A_FireCustomMissile("ShotShell",random(-20,-60),False,10)
SHTG CB 5
SHTG A 3
SHTG A 7 A_ReFire
Goto Ready
Flash:
SHTF A 4 Bright A_Light1
SHTF B 3 Bright A_Light2
Goto LightDone
Spawn:
SHOT A -1
Stop
Spawn:
SHOT A -1
Stop
}
}
This is what it should look like:
Code: Select all
Class NewShotgun : Weapon replaces Shotgun
{
Default
{
Weapon.SelectionOrder 1300;
Weapon.AmmoUse 1;
Weapon.AmmoGive 8;
Weapon.AmmoType "Shell";
Inventory.PickupMessage "$GOTSHOTGUN";
Obituary "$OB_MPSHOTGUN";
}
States
{
Ready:
TNT1 A 0 A_JumpIf(GetCvar("ENTRY_smooth") == 1, "Ready_NoSmooth");
ESH1 A 1 A_WeaponReady;
Loop;
Ready_NoSmooth:
TNT1 A 0 A_JumpIf(GetCvar("ENTRY_smooth") == 0, "Ready");
SHTG A 1 A_WeaponReady;
Loop;
Deselect:
TNT1 A 0 A_JumpIf(GetCvar("ENTRY_smooth") == 1, "Deselect_NoSmooth");
ESH1 A 1 A_Lower;
TNT1 AA 0 A_Lower;
Loop;
Deselect_NoSmooth:
TNT1 A 0 A_JumpIf(GetCvar("ENTRY_smooth") == 0, "Deselect");
SHTG A 1 A_Lower;
TNT1 AA 0 A_Lower;
Loop;
Select:
TNT1 A 0 A_JumpIf(GetCvar("ENTRY_smooth") == 1, "Select_NoSmooth");
ESH1 A 1 A_Raise;
TNT1 AA 0 A_Raise;
Loop;
Select_NoSmooth:
TNT1 A 0 A_JumpIf(GetCvar("ENTRY_smooth") == 0, "Select");
SHTG A 1 A_Raise;
TNT1 AA 0 A_Raise;
Loop;
Fire:
TNT1 A 0 A_JumpIf(GetCvar("ENTRY_smooth") == 1, "Fire_NoSmooth");
TNT1 A 0 A_JumpIfInventory("Powersync_thecrusible",1,"Fire_Speed");
ESH1 A 3;
ESH1 B 2 BRIGHT {
A_FireBullets (4.8, 1.9, 7, 8, "BulletPuff");
A_SetPitch(pitch-0.5);
A_PlaySound("weapons/shotgf",CHAN_WEAPON);
}
ESH1 CD 2 BRIGHT A_SetPitch(pitch-0.25);
ESH1 E 1 BRIGHT A_SetPitch(pitch+0.25);
ESH1 F 2 A_SetPitch(pitch+0.25);
ESH1 GH 1 A_SetPitch(pitch+0.25);
ESH1 IJKLM 1 A_SetRoll(roll-0.24);
ESH1 N 1 A_SetPitch(pitch+0.25);
ESH1 OP 2 A_SetPitch(pitch+0.25);
ESH1 Q 1 {
A_FireCustomMissile("ShotShell",random(-20,-60),False,10);
A_SetPitch(pitch-0.25);
}
ESH1 R 2 A_SetPitch(pitch-0.25);
ESH1 S 1 A_SetPitch(pitch-0.25);
ESH1 TUVWX 1 A_SetRoll(roll+0.24);
ESH1 YZ 1;
ESH1 A 1;
ESH1 A 7 A_ReFire;
Goto Ready;
Fire_Speed:
TNT1 A 0 A_JumpIf(GetCvar("ENTRY_smooth") == 1, "Fire_NoSmooth");
ESH1 A 3;
ESH1 B 2 BRIGHT {
A_FireBullets (4.8, 1.9, 10, 5, "BulletPuff");
A_PlaySound ("weapons/shotgf", CHAN_WEAPON);
A_SetPitch(pitch-0.5);
}
ESH1 C 2 BRIGHT A_SetPitch(pitch-0.5);
ESH1 E 1 BRIGHT A_SetPitch(pitch+0.25);
ESH1 F 2 A_SetPitch(pitch+0.25);
ESH1 G 1 A_SetPitch(pitch+0.5);
ESH1 IKM 1 A_SetRoll(roll-0.48);
ESH1 N 1 A_SetPitch(pitch+0.25);
ESH1 OP 2 A_SetPitch(pitch+0.25);
ESH1 Q 1 {
A_FireCustomMissile("ShotShell",random(-20,-60),False,10);
A_SetPitch(pitch-0.25);
}
ESH1 R 2 A_SetPitch(pitch-0.25);
ESH1 S 1 A_SetPitch(pitch-0.25);
ESH1 TUW 1 A_SetRoll(roll+0.48);
ESH1 YZ 1;
ESH1 A 4;
ESH1 A 7 A_ReFire;
Goto Ready;
Fire_NoSmooth:
SHTG A 3;
SHTG A 7 {
A_FireBullets (5.6, 0, 8, 5, "BulletPuff");
A_PlaySound ("weapons/shotgf", CHAN_WEAPON);
A_GunFlash;
}
SHTG BC 5;
SHTG D 4 A_FireCustomMissile("ShotShell",random(-20,-60),False,10);
SHTG CB 5;
SHTG A 3;
SHTG A 7 A_ReFire;
Goto Ready;
Flash:
SHTF A 4 Bright A_Light1;
SHTF B 3 Bright A_Light2;
Goto LightDone;
Spawn:
SHOT A -1;
Stop;
Spawn:
SHOT A -1;
Stop;
}
}
You should also remove A_FireCustomMissile and use A_FireProjectile instead. Also, NULL is not really recommended for use. You should use TNT1 instead.