[Done] A_JumpIfLineOfSight and/or new CposRefire/SpidRefire action.

Moderator: GZDoom Developers

A_JumpIfLineOfSight and/or new CposRefire/SpidRefire action.

Postby Killo Zapit » Tue Jun 28, 2005 6:44 pm

I have some small need for something like the A_CposRefire and A_SpidRefire codepointers that don't randomly continue anyway. That or a jump codepointer that worked similarly.

I am trying to make a monster that switches between walk/heal mode (A_VileChase) and dash mode (A_FastChase) depending on if it's in line of sight with it's target. Until then, I could just use A_SpidRefire, even if that will cause it to sometimes go into dash mode when it's out of sight anyway.
User avatar
Killo Zapit
PIGBUTT LIVES AGAIN!
 
Joined: 16 Jul 2003
Location: Most likely sleeping.

Postby Graf Zahl » Wed Jun 29, 2005 2:13 am

You can reduce the probability of miscalculation dramatically if you put another A_SpidRefire in the following state as well - ot even more if that is not enough.
User avatar
Graf Zahl
Lead GZDoom+Raze Developer
Lead GZDoom+Raze Developer
 
Joined: 19 Jul 2003
Location: Germany

Postby Killo Zapit » Wed Jun 29, 2005 8:24 pm

I guess... I was actually sort of hoping for A_JumpIfLineOfSight for other reasons too... But for my immediate concerns two A_SpidRefires works well enough.
User avatar
Killo Zapit
PIGBUTT LIVES AGAIN!
 
Joined: 16 Jul 2003
Location: Most likely sleeping.

Postby Daniel » Wed Jun 29, 2005 8:30 pm

Btw, what is the main difference between A_SpidReFire and A_CPosReFire?
User avatar
Daniel
 
Joined: 04 Jul 2004

Postby Anakin S. » Wed Jun 29, 2005 9:40 pm

I think A_CPosRefire just has a higher probability that it will continue firing than A_SpidRefire.
User avatar
Anakin S.
Am I evil?
 
Joined: 28 Nov 2003
Location: A long time ago in a galaxy far, far away...

Postby Kirby » Wed Jun 29, 2005 9:42 pm

I thought it the opposite way, cause that wouls seem to make more sense wouldn't it?
User avatar
Kirby
Soon to be chastized
 
Joined: 26 Aug 2004

Postby Graf Zahl » Thu Jun 30, 2005 1:40 am

Anakin is right. A_CPosRefire has the higher probability.
User avatar
Graf Zahl
Lead GZDoom+Raze Developer
Lead GZDoom+Raze Developer
 
Joined: 19 Jul 2003
Location: Germany

Postby Kirby » Thu Jun 30, 2005 10:28 am

Heh, I guess spidey ain't so great after all :P
User avatar
Kirby
Soon to be chastized
 
Joined: 26 Aug 2004

Postby Graf Zahl » Thu Jun 30, 2005 11:54 am

No, Spidey is better! It's the chaingunner who tends to shoot at nothing.
User avatar
Graf Zahl
Lead GZDoom+Raze Developer
Lead GZDoom+Raze Developer
 
Joined: 19 Jul 2003
Location: Germany

Postby Kirby » Thu Jun 30, 2005 1:29 pm

So, he sacrifices accuracy for a better refire chance? I see......
User avatar
Kirby
Soon to be chastized
 
Joined: 26 Aug 2004

Postby Anakin S. » Thu Jun 30, 2005 9:42 pm

Graf Zahl wrote:No, Spidey is better! It's the chaingunner who tends to shoot at nothing.


But that's because Spidey uses a rapid fire sergeant shotgun!
User avatar
Anakin S.
Am I evil?
 
Joined: 28 Nov 2003
Location: A long time ago in a galaxy far, far away...


Return to Closed Feature Suggestions

Who is online

Users browsing this forum: No registered users and 0 guests