Page 1 of 1
customrailgun
Posted: Mon Aug 10, 2009 14:25
by brick
before all, I am brick. I enjoy your work so much, it's realy incredible the mods for doom.
I am with some doubts with railgun. How Can I put the Y offset
ex:
a_customrailgun(damage, spawnoft_x"y", ...)
thank you
Re: customrailgun
Posted: Mon Aug 10, 2009 14:57
by Rachael
This is not a feature suggestion. The topic has been moved.
Re: customrailgun
Posted: Mon Aug 10, 2009 15:12
by brick
sorry, my inglish is not good
Re: customrailgun
Posted: Mon Aug 10, 2009 15:28
by Gez
brick wrote:before all, I am brick. I enjoy your work so much, it's realy incredible the mods for doom.
I am with some doubts with railgun. How Can I put the Y offset
ex:
a_customrailgun(damage, spawnoft_x"y", ...)
thank you
That's a bit misleading, you do not set the X and Y offsets separately. Instead, you just specify the distance away from the center of the shooter. X and Y are then calculated by trigonometry from the shooter's angle and that distance.
Re: customrailgun
Posted: Mon Aug 10, 2009 15:39
by brick
Gez wrote:That's a bit misleading, you do not set the X and Y offsets separately. Instead, you just specify the distance away from the center of the shooter. X and Y are then calculated by trigonometry from the shooter's angle and that distance.
ok, I found a way (difficult) to do a height.
Code: Select all
actor mekanos
{
...
States
{
Railgun:
NUL2 IJKLM 4 A_FaceTarget
NUL2 N 10 A_CustomMissile("RailgunSpawner", 57, 0)
NUL2 OPQR 6
Goto Decision
...
}
Actor RailgunSpawner
{
Radius 4
Height 4
Speed 10
Damage 0
+RIPPER
+DOOMBOUNCE
PROJECTILE
States
{
Spawn:
NULL A 1
NULL A 1 A_SpawnItem("RailMonster",1,0,0)
Stop
}
}
Actor RailMonster
{
MONSTER
Radius 1
Height 1
Speed 0
+NOGRAVITY
+NOCLIP
+FRIENDLY
States
{
Spawn:
NULL A 0 A_UnSetShootable
NULL A 0 A_Look
See:
NULL A 0 A_Chase
Missile:
NULL A 0 A_FaceTarget
NULL A 0 A_CustomRailgun(random(5, 50),0,"blue","white",1,10,3)
Stop
}
}
the actor mekanos is null beacuse he is a model.
Re: customrailgun
Posted: Mon Aug 10, 2009 16:02
by Gez
brick wrote:Gez wrote:That's a bit misleading, you do not set the X and Y offsets separately. Instead, you just specify the distance away from the center of the shooter. X and Y are then calculated by trigonometry from the shooter's angle and that distance.
ok, I found a way (difficult) to do a height.
Yeah, that's X and Y relative to the world (so, horizontal, the height is the Z axis), not relative to the screen.
Re: customrailgun
Posted: Mon Aug 10, 2009 16:08
by brick
Gez wrote:brick wrote:Gez wrote:That's a bit misleading, you do not set the X and Y offsets separately. Instead, you just specify the distance away from the center of the shooter. X and Y are then calculated by trigonometry from the shooter's angle and that distance.
ok, I found a way (difficult) to do a height.
Yeah, that's X and Y relative to the world (so, horizontal, the height is the Z axis), not relative to the screen.
ok, my quake bfg I do the samething, but cant anyone do a new action to stay more easy, like this:
A_CustomRailgunEX(damage, "damagetype", spawnofs_xy, "spawn height", ringcolor, corecolor, flags, float max diff)
guy what is "float max diff"?