View unanswered posts | View active topics It is currently Wed Oct 02, 2024 6:42 pm



Reply to topic  [ 6 posts ] 
 AimRange on ACrab 
Author Message
User avatar

Joined: Wed Nov 22, 2006 3:19 pm
Posts: 2073
Reply with quote
Post AimRange on ACrab
Ok, so i'm making a ceiling turret and I have some issues with AimRange.

I need my turret's AimRange to be 90 degrees (The value being 0.785) but AimRange Works like this:
Image
Here the gray line is 0 degrees and each red line is 45 (or 45 and 315, what ever suits you best) .

I need my turret to work like this:
Image
With the gray line being 45 degrees and the red ones being 0 and 90.

Is there a way to do this without too much headache?
I know I can just set it to 1.57 for 180 degree AimRange but I don't want my turret to be able to aim up...


Fri Dec 18, 2009 9:23 pm
Profile
User avatar

Joined: Wed Sep 09, 2009 3:16 am
Posts: 3032
Location: Somewhere in the universe
Reply with quote
Post Re: AimRange on ACrab
didnt darkstorm's drone flying things and the ceiling turret not able to shoot up?
Maybe you should look at it or i will volunteer to look for the variable.


Sat Dec 19, 2009 1:22 am
Profile
REAL AMERICAN HERO
User avatar

Joined: Sat Jan 27, 2007 10:25 pm
Posts: 5655
Reply with quote
Post Re: AimRange on ACrab
Not possible without Lua, and even then not perfect, mostly because human control overrides lua settings (I'm pretty sure).


Sat Dec 19, 2009 1:35 am
Profile
User avatar

Joined: Sun Jul 13, 2008 9:57 am
Posts: 4886
Location: some compy
Reply with quote
Post Re: AimRange on ACrab
Nah, you can disable firing when above the angle easily. I think you can adjust AimAngle to change this more easily though.


Sat Dec 19, 2009 5:31 am
Profile WWW
User avatar

Joined: Wed Nov 22, 2006 3:19 pm
Posts: 2073
Reply with quote
Post Re: AimRange on ACrab
Hmmm...
Well, that blows balls.

Would something like 'if angle > 45 then angle = 45' work?


Sat Dec 19, 2009 2:59 pm
Profile
REAL AMERICAN HERO
User avatar

Joined: Sat Jan 27, 2007 10:25 pm
Posts: 5655
Reply with quote
Post Re: AimRange on ACrab
well, it's in radians, so you'd be using
actor:GetController():GetAimAngle(false)

the false argument means that hflipped is irrelevant; thus, you're only ever going to have an aimrange from 0 to math.pi.


Sat Dec 19, 2009 9:22 pm
Profile
Display posts from previous:  Sort by  
Reply to topic   [ 6 posts ] 

Who is online

Users browsing this forum: Google [Bot]


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot post attachments in this forum

Search for:
Jump to:  
Powered by phpBB © 2000, 2002, 2005, 2007 phpBB Group.
Designed by STSoftware for PTF.
[ Time : 0.028s | 14 Queries | GZIP : Off ]