Summoning Pistol Crashes GZDoom

Ask about ACS, DECORATE, ZScript, or any other scripting questions here!
Forum rules
Before asking on how to use a ZDoom feature, read the ZDoom wiki first. If you still don't understand how to use a feature, then ask here.

Summoning Pistol Crashes GZDoom

Postby Beetow Brode » Tue Nov 13, 2018 10:08 pm

So I made A Pistol and when I try to use it it doesnt show up like for example when I use the give command
but when I typed in summon it crashed, no crash message just GZDoom is not responding and it took quite a while to close
User avatar
Beetow Brode
 
Joined: 24 Sep 2016
Location: Canadia, Im Serious
Discord: Punkin#8267

Re: Summoning Pistol Crashes GZDoom

Postby Beetow Brode » Tue Nov 13, 2018 10:08 pm

Oh S*&% I forgot the code here you go

Code: Select allExpand view
ACTOR PISTOLA : Weapon
{
Weapon.SelectionOrder 2900
Weapon.AmmoUse 1
Weapon.SlotNumber 2
Weapon.AmmoGive 40
Weapon.AmmoType "Clip"
scale 1.5
AttackSound "SNDGN1"
+WEAPON.WIMPY_WEAPON
Inventory.Pickupmessage "Picked up a Shitty Pistol."
States
{
Spawn:
PISO E 0
loop
Ready:
PISO A 1 A_WeaponReady
Loop
Select:
PISO A 1 A_WeaponReady
Loop
Deselect:
PISO A 1 A_WeaponReady
Loop
Fire:
PISO A 1
PISO B 2
PISO C 2 A_FireBullets(5.2,1,1,75)
PISO D 1
Loop
}
}
User avatar
Beetow Brode
 
Joined: 24 Sep 2016
Location: Canadia, Im Serious
Discord: Punkin#8267

Re: Summoning Pistol Crashes GZDoom

Postby Arctangent » Tue Nov 13, 2018 11:16 pm

Beetow Brode wrote:
Code: Select allExpand view
Spawn:
PISO E 0
loop

welcome to zero-duration infinite loops, bud

they'll stick with you throughout your entire coding career, you'll just get better at spotting them after the fact
User avatar
Arctangent
squawky
 
Joined: 06 Nov 2014
Discord: SquawkyAtan#2371


Return to Scripting

Who is online

Users browsing this forum: No registered users and 1 guest