A_RadiusGive Overhaul

Post a reply

Smilies
:D :) :( :o :shock: :? 8-) :lol: :x :P :oops: :cry: :evil: :twisted: :roll: :wink: :geek: :ugeek: :!: :?: :idea: :arrow: :| :mrgreen: :3: :wub: >:( :blergh:
View more smilies

BBCode is OFF
Smilies are ON

Topic review
   

Expand view Topic review: A_RadiusGive Overhaul

Re: A_RadiusGive Overhaul

by NeuralStunner » Thu Jul 23, 2015 1:53 pm

Major Cooke wrote:thing->IsKindOf(RUNTIME_CLASS(AInventory))
Oh right, I forgot you could do this. Nevermind me. :P

Re: A_RadiusGive Overhaul

by Major Cooke » Thu Jul 23, 2015 7:25 am

Not a problem! I've updated the wiki too.

It should be noted I didn't touch the radius code. I'm going nowhere near it as I'm rather horrible at that kind of thing.

Re: A_RadiusGive Overhaul

by Xtyfe » Thu Jul 23, 2015 7:18 am

Oh wow, this is very useful for me. Thanks for fixing it up :)

Re: A_RadiusGive Overhaul

by Major Cooke » Thu Jul 23, 2015 6:56 am

You can always tell me how I can improve upon it and I'll do my best to do so.

I had the uneasy feeling that a bunch of booleans would be frowned upon, but I didn't want to make as much of a mess.

Re: A_RadiusGive Overhaul

by Graf Zahl » Thu Jul 23, 2015 5:14 am

Merged, although I'll freely admit that I only superficially reviewed the code - it can only get better from what was there... :twisted:

Re: A_RadiusGive Overhaul

by Major Cooke » Wed Jul 22, 2015 6:25 pm

They were working fine for me to begin with.

And, I'm not the best. Once they pointed out that it was flawed logic, the problem was much easier to fix than thought. :P

Re: A_RadiusGive Overhaul

by Beed28 » Wed Jul 22, 2015 6:23 pm

Amazing! You truly are the best!

Can map-wide radiuses work reliably now, as well?

Re: A_RadiusGive Overhaul

by Major Cooke » Wed Jul 22, 2015 4:14 pm

Only reason to do that is for state jumps, I think.

Graf: Fixed. No longer uses MF_SPECIAL, now uses thing->IsKindOf(RUNTIME_CLASS(AInventory)) instead.

Re: A_RadiusGive Overhaul

by NeuralStunner » Wed Jul 22, 2015 4:12 pm

Seems like you'd have to check the inheritance chain.

Re: A_RadiusGive Overhaul

by Major Cooke » Wed Jul 22, 2015 4:09 pm

Fixing now.

Re: A_RadiusGive Overhaul

by Graf Zahl » Wed Jul 22, 2015 4:01 pm

One note:

MF_SPECIAL is NOT the same as being an inventory item. Strife's Spectres also use this flag.

A_RadiusGive Overhaul

by Major Cooke » Wed Jul 22, 2015 3:53 pm

Pull Request.

Fixed a lot of things wrong with A_RadiusGive, and added some goodies. See the pull request for more info.

If you're wondering, KILLED != CORPSE at all times. If you want true results of who is truly dead and whose not, use RGF_KILLED.

One thing I forgot to mention in the request is RGF_GIVESELF, the pointer flags and the species processing comes first. RGF_GIVESELF will always succeed now.

Top