pablogener Posted May 16, 2013 sometimes (and sometimes not) I can't pick up the items I made myself in DECORATE. I just don't know how to reproduce the errors... sometimes I can, and sometimes I just can't pick them up. What could be wrong? why would zdoom not let you pick up a custom item? I just walk all over the damn thing and I don't pick it up. It's insane. It should pick it up and a script would run after that. I'll give you the 'DECORATE' code: actor CellReg : Ammo 6668 { Game Doom SpawnID 75 Inventory.PickupMessage "Picked up the Regenerative Cell Pack" // "Picked up an energy cell." Inventory.Amount 600 Inventory.MaxAmount 600 Ammo.BackpackAmount 600 Ammo.BackpackMaxAmount 600 Inventory.Icon "CERGA0" States { Spawn: CERG A -1 Stop } } the CERGA0 png is something I imported into my pwad, like many other things I already have included in it. everything else works fine. When I pick this up a script runs that keeps your cells at the top of your inventory. I tested this the various times I could pick it up. I really hope anyone could help me. 0 Share this post Link to post
GreyGhost Posted May 16, 2013 Judging by the Inventory.Amount, it looks like you can only carry one fully charged cell at a time. 0 Share this post Link to post
Kappes Buur Posted May 16, 2013 I know just enough about DECORATE it get by. So this may not be the correct way to do this. As it is, I assume you use the plasma gun, which will run out of cells and you cannot pick up any CellRegs. It seems, that this is because the plasma gun uses the original Cells. You could do the DECORATE for a new plasma gun to use CellReg: actor CellReg : Ammo 16666 { Game Doom SpawnID 75 Inventory.PickupMessage "Picked up the Regenerative Cell Pack" // "Picked up an energy cell." Inventory.Amount 600 Inventory.MaxAmount 600 Ammo.BackpackAmount 600 Ammo.BackpackMaxAmount 600 Inventory.Icon "CERHA0" States { Spawn: CERG A -1 Stop } } ACTOR newPR : PlasmaRifle replaces PlasmaRifle 16667 { Weapon.AmmoType "CellReg" } Example Also: http://zdoom.org/wiki/DECORATE http://gunlabs.blogspot.ca/2012/06/tutorial-new-ammo-types-and-weapons.html 0 Share this post Link to post
pablogener Posted May 16, 2013 I changed the 'DECORATE' code and left in only those parts that I want to change from 'Cell'. I assume anything else will be 'inherited' from it, since I'm defining my item as "[...] : Cell" this is how it appears now: actor CellReg : Cell 6668 { Inventory.PickupMessage "Picked up the Regenerative Cell Pack" // "Picked up an energy cell." Inventory.Icon "CERGA0" States { Spawn: CERG A -1 Stop } } There's one thing I do get from testing, is that I can pick up this item if I test the map this item is in right from Doom Builder 2. But if I'm playing on from the previous map, then I just can't pick it up. I really don't know what could be wrong. If I load this map from the commandline or from Doom Builder, everything is ok and I can get the item. But if I start playing at a previous map and play on till I get to this item, I can't pick it up. What could be the cause of this?? 0 Share this post Link to post
Kappes Buur Posted May 16, 2013 Take a look at some DECORATE items from REALM667. Lots of examples 0 Share this post Link to post
pablogener Posted May 17, 2013 sorry and thanks kappes, I didn't see the post you made right before MY last reply. I'll be checking out everything you posted. thanks for all the help. The 'Regenerating Cells' are for the final boss. You know, there's no 'Soul Cube' in DooM 1 and trying to get 1 to work (collecting 'souls' from dead enemies and using it as a weapon, just seemed too much...), so I want to lock the player up with the Cyberdemon and have him flood it with plasma from a BFG, with self-regenerating cells. 0 Share this post Link to post
Necromancer-AMV Posted May 17, 2013 pablogener said:...a BFG, with self-regenerating cells. You could make an ACS script that gives 1 of the ammo every specified amount of tics, or for something simpler you could put it in the weapon's Ready state. EX: ACTOR OneCellAmmo : Cell { Inventory.Amount 1 } ACTOR RegenBFG : BFG9000 { States { Ready: TNT1 A 0 A_GiveInventory("OneCellAmmo") BFG9 AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA 1 A_WeaponReady Loop } } The above example would add 1 unit of cell ammo for every second that it is equipped and not firing. But unlike the ACS route, it only would work with that weapon and when it is in the applicable state. 0 Share this post Link to post
pablogener Posted May 17, 2013 ok guys, I see we're trying to approach the answer the wrong way. All I need is one simple thing: I NEED TO PICK UP SOMETHING! just anything just pickup something (to trigger an ACS script). I need to define a new 'something' that would be pickup-able. After I pick it up, I'll go into an infinite loop to keep the cell count right at the top, until the end of the level. That's it. That would make my day. How do I define just something that would be pickaup-able. that's it. I don't care if it's cells, ammo, it affects or not a weapon.. I just need to make sure that I'll pick up the damn thing! :D thanks for all the help you guys. 0 Share this post Link to post
Necromancer-AMV Posted May 17, 2013 Actors that inherit from CustomInventory can execute scripts on the player, and to make sure that the player will always pick up the item, use the +ALWAYSPICKUP flag. 0 Share this post Link to post
pablogener Posted May 19, 2013 thanks Necro, that did the trick. and thank you all who contributed to answer my question. Now I can finish my game. All there is left is programming the intermissions, doing a few good posters, a couple more videos, and I can start packing up a final release candidate. Necromancer-AMV said:Actors that inherit from CustomInventory can execute scripts on the player, and to make sure that the player will always pick up the item, use the +ALWAYSPICKUP flag. 0 Share this post Link to post