Gonubax Posted February 10, 2019 Hey guys, it is my first time to make weapons, and i cannot equip or spawn the one i created (ShellChaingun). No bugs and when i type "Summon ShellChaingun" it does nothing. What am i doing wrong? Here's the code of the Decorate : ACTOR ShellChaingun: DoomWeapon 22222{ Weapon.SelectionOrder 2500 Weapon.AmmoUse 1 Weapon.AmmoGive 20 Weapon.AmmoType "Shell" Weapon.SlotNumber 3 Inventory.PickupSound "weapon/getshellchaingun" Inventory.PickupMessage "You got the shell chaingun! Now you're in the big leagues!" Obituary "%o was slaughtered with a fucking shell chaingun." Tag "ShellChaingun" States { Spawn: SCGN A -1 Stop Select: SCGG A 1 A_Raise Loop Deselect: SCGG A 1 A_Lower Loop Ready: SCGG A 0 A_WeaponReady Loop Fire: SCGG A 0 A_FireBullets (5.6, 0, 7, 5, "BulletPuff") SCGG A 0 A_PlaySound ("weapon/fireshellchaingun", CHAN_WEAPON) SCGG AB 4 SCGG B 1 A_ReFire Goto Ready } } 0 Quote Share this post Link to post
Empyre Posted February 10, 2019 You have a runaway loop in your ready state. Make its duration 1 or more tics to fix that problem. About it not appearing when you summon it, do you have its sprites in the correct name space (between SS_START and SS_END in a wad, or the Sprites folder in a pk3)? You will also need to make a custom player class inheriting from DoomPlayer with that weapon in its list. https://zdoom.org/wiki/Creating_new_player_classes 2 Quote Share this post Link to post
Gonubax Posted February 11, 2019 (edited) Is what you're saying should look like this ? Sorry if i look dumb: it is my very first time with modding, but i once started making a map for freedoom. ACTOR LethalWeaponsDude: DoomPlayer { Player.DisplayName "Lethal weapons dude" Player.WeaponSlot 1, Fist, Chainsaw Player.WeaponSlot 2, Pistol Player.WeaponSlot 3, Shotgun, SuperShotgun, ShellChaingun Player.WeaponSlot 4, Chaingun Player.WeaponSlot 5, RocketLauncher Player.WeaponSlot 6, PlasmaRifle Player.WeaponSlot 7, BFG9000 } ACTOR ShellChaingun: DoomWeapon 22222{ Weapon.SelectionOrder 2500 Weapon.AmmoUse 1 Weapon.AmmoGive 20 Weapon.AmmoType "Shell" Weapon.SlotNumber 3 Inventory.PickupSound "weapon/getshellchaingun" Inventory.PickupMessage "You got the shell chaingun! Now you're in the big leagues!" Obituary "%o was slaughtered with a fucking shell chaingun." Tag "ShellChaingun" States { Spawn: SCGN A -1 Stop Select: SCGG A 1 A_Raise Loop Deselect: SCGG A 1 A_Lower Loop Ready: SCGG A 1 A_WeaponReady Loop Fire: SCGG A 0 A_FireBullets (5.6, 0, 7, 5, "BulletPuff") SCGG A 0 A_PlaySound ("weapon/fireshellchaingun", CHAN_WEAPON) SCGG AB 4 SCGG B 1 A_ReFire Goto Ready } } Edit : I tested that and it still doesn't work somehow Edited February 11, 2019 by Gonubax Didn't tested, but now i have 0 Quote Share this post Link to post
Empyre Posted February 11, 2019 Did you make the Gaminfo section in Mapinfo, like it said to do on that page I linked? If you don't, the player will be playing the regular DoomPlayer class, not your custom class. Are your sprites in the right place (between SS_START and SS_END in a wad, or the Sprites folder in a pk3)? If the sprites can't be found, the actor will either be invisible, or it won't work at all. 0 Quote Share this post Link to post
Bauul Posted February 11, 2019 You could try "Give ShellChaingun" rather than "Summon ShellChaingun", as that will give it to you directly rather than having to spawn it first to see if you can pick it up. At least that way you can start to narrow down what the issue is. On 2/10/2019 at 1:38 PM, Empyre said: You will also need to make a custom player class inheriting from DoomPlayer with that weapon in its list. https://zdoom.org/wiki/Creating_new_player_classes You do? I've added a few new weapons and never knowingly done that. Are you sure you need to? 0 Quote Share this post Link to post
Gonubax Posted February 12, 2019 I tried what you all were saying and now it works finally :D Thank you all very much! 0 Quote Share this post Link to post
Empyre Posted February 12, 2019 19 hours ago, Bauul said: You could try "Give ShellChaingun" rather than "Summon ShellChaingun", as that will give it to you directly rather than having to spawn it first to see if you can pick it up. At least that way you can start to narrow down what the issue is. You do? I've added a few new weapons and never knowingly done that. Are you sure you need to? If you don't, the player could have trouble switching to and/or from the custom weapon. I don't think it is necessary if you are simply replacing a weapon, only when adding a new one. 0 Quote Share this post Link to post
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.