The "How do I..." Thread
Forum rules
Before asking on how to use a ZDoom feature, read the ZDoom wiki first. This forum is archived - please use this set of forums to ask new questions.
Before asking on how to use a ZDoom feature, read the ZDoom wiki first. This forum is archived - please use this set of forums to ask new questions.
-
- Posts: 220
- Joined: Thu Sep 25, 2014 2:20 pm
- Location: Renton, Washington, USA
Re: The "How do I..." Thread
How can I get and return the damagetype in acs?
Something like this;
str type = damagetype[notsurewhatgoesehere];
int deathtype = strparam(s:"Death.", s:type);
But I'm not entirely sure how to go about storing damage types...
Can someone help me with this?
Or is what I'm trying to do not possible?
Something like this;
str type = damagetype[notsurewhatgoesehere];
int deathtype = strparam(s:"Death.", s:type);
But I'm not entirely sure how to go about storing damage types...
Can someone help me with this?
Or is what I'm trying to do not possible?
Re: The "How do I..." Thread
It's not possible. Damage types aren't actually strings, for starters. 

-
- Posts: 220
- Joined: Thu Sep 25, 2014 2:20 pm
- Location: Renton, Washington, USA
Re: The "How do I..." Thread
How do I use hudmessage to display the count of an item in the player inventory?
Re: The "How do I..." Thread
Is there a way to move the player to an arbitrary location? SetActorPosition doesn't seem to work.
EDIT: I hacked around it by spawning a teleport destination, but this seems like an ugly way to do it, so my question still remains.
EDIT: I hacked around it by spawning a teleport destination, but this seems like an ugly way to do it, so my question still remains.
Re: The "How do I..." Thread
SetActorPosition is one of the many ways you can do it, so something else is wrong with how you've done it.XCVG wrote:Is there a way to move the player to an arbitrary location? SetActorPosition doesn't seem to work.
EDIT: I hacked around it by spawning a teleport destination, but this seems like an ugly way to do it, so my question still remains.
d:[wiki]CheckInventory[/wiki]("Shell")loismustdie555 wrote:How do I use hudmessage to display the count of an item in the player inventory?
- DoomKrakken
- Posts: 3489
- Joined: Sun Oct 19, 2014 6:45 pm
- Location: Plahnit Urff
- Contact:
Re: The "How do I..." Thread
Just in case this got buried...
It's been edited, btw...
It's been edited, btw...
DoomKrakken wrote:Still working on the Brutal Guncaster patch. I have a couple things to ask...
Firstly, I want the Pulverizer, Strucker, and Longhorn to fire tracer projectiles. I'm using the A_FireCustomMissile command to do it.
I'm not entirely sure how it works though... I want those weapons to have the same kind of spread as they normally do, however, I cannot find anything in the A_FireCustomMissile command that relates to the "angle spread_horz" and "angle spread_vert" variables in A_FireBullets.
For example... the Strucker has a horizontal spread of 7 and a vertical spread of 3 (I think). How would I make the tracer projectiles have that spread?
Secondly, I have a new idea on how Corpseblast should work in Brutal Guncaster (since the way it originally works doesn't work in Brutal Doom).
I was thinking that the spell would deal 1 damage (with damagetypes Corpseblast, or Corspeblast2 if tomed, assigned to them), and every actor but the corpses would have DamageFactor "Corpseblast", 0.0 and DamageFactor "Corpseblast2", 0.0. The corpses themselves would probably have DamageFactor "Corpseblast", 50000; DamageFactor "Corpseblast2", 0.0; DamageFactor "Flesh", 0.0; and PainChance "Corpseblast2", 255.
That being said, if the corpse actor is hit with "Corpseblast", then it'll go to Death.Corpseblast, and from there, spawn the corresponding blasted corpse actor. If hit with a tomed Corpseblast, "Corpseblast2", then the corpse actor will go to Pain.Corpseblast2, so that it doesn't die when it spawns the corresponding blasted corpse actor. My question here is what part of the Corpseblast DECORATE code should deal the damage in the first place?
Spoiler: CorpseBlast DECORATE Code, for those of you who do not have Guncaster open at the moment...Thanks.
P.S.: Can an actor go into a pain state from another actor that deals no damage to it?
-
- Posts: 220
- Joined: Thu Sep 25, 2014 2:20 pm
- Location: Renton, Washington, USA
Re: The "How do I..." Thread
In my mod it doesn't seem to want to refresh the count.
Am I doing something wrong?
script 3794 OPEN
{
HudMessage(s:"XP: ",d:CheckInventory("555PointDummy");1,4,CR_GREEN, 0, 2, 0.1, 0.8, 3.7);
Delay(1);
Restart;
}
Am I doing something wrong?
script 3794 OPEN
{
HudMessage(s:"XP: ",d:CheckInventory("555PointDummy");1,4,CR_GREEN, 0, 2, 0.1, 0.8, 3.7);
Delay(1);
Restart;
}
Re: The "How do I..." Thread
Yes. The world doesn't have an inventory, so an OPEN script is obviously not what you want, there. 

-
- Posts: 220
- Joined: Thu Sep 25, 2014 2:20 pm
- Location: Renton, Washington, USA
Re: The "How do I..." Thread
I assumed an ENTER script?edward850 wrote:Yes. The world doesn't have an inventory, so an OPEN script is obviously not what you want, there.
It doesn't work either

-
- Posts: 220
- Joined: Thu Sep 25, 2014 2:20 pm
- Location: Renton, Washington, USA
Re: The "How do I..." Thread
I had 555PointDummy as custominventory, I set it to ammo and it worked fine.edward850 wrote:You've missed something, because it works absolutely fine.

- zrrion the insect
- Posts: 2432
- Joined: Thu Jun 25, 2009 1:58 pm
- Location: Time Station 1: Moon of Glendale
Re: The "How do I..." Thread
How would I add an intro sequence to a wad?
I'm looking for something similar to the intro for strife, but using a mapinfo intermission doesn't seem the way to go as Inter_Strife_Intro is commented out in mapinfo/strife.txt. Am I missing something?
I'm looking for something similar to the intro for strife, but using a mapinfo intermission doesn't seem the way to go as Inter_Strife_Intro is commented out in mapinfo/strife.txt. Am I missing something?
- Vincent(PDP)
- Posts: 60
- Joined: Fri May 16, 2014 3:49 pm
- Location: Sweden
- Contact:
Re: The "How do I..." Thread
Also see the Inventory class.loismustdie555 wrote:I had 555PointDummy as custominventory, I set it to ammo and it worked fine.
-
- Posts: 5
- Joined: Sun Aug 16, 2015 2:28 pm
Re: The "How do I..." Thread
Okay, I am really stumped. How do I make it so an actor enters a pain state when players and only players touch it and change the target to them for an A_GiveToTarget. I spent 2 days trying to figure this out yet I can't.
Re: The "How do I..." Thread
Use these flags:
BUMPSPECIAL
THINGSPEC_ThingTargets
and set the actors action special to ACS_EXECUTE, pointing to a script which contains GiveActorInventory(0, "Bumpcounter",1);
Then have your custom inventory item "bumpcounter" put it's carrier into a custom pain2 or something state where an A_GiveToTarget is executed.
I haven't tested this though, but I believe it should work. Rather convoluted, and there might be some other, obvious way I'm not seeing.
BUMPSPECIAL
THINGSPEC_ThingTargets
and set the actors action special to ACS_EXECUTE, pointing to a script which contains GiveActorInventory(0, "Bumpcounter",1);
Then have your custom inventory item "bumpcounter" put it's carrier into a custom pain2 or something state where an A_GiveToTarget is executed.
I haven't tested this though, but I believe it should work. Rather convoluted, and there might be some other, obvious way I'm not seeing.