Author Topic: Aim getting WAAAAAY too big  (Read 9974 times)

Offline Numsgil

  • Administrator
  • Bot God
  • *****
  • Posts: 7742
    • View Profile
Aim getting WAAAAAY too big
« Reply #15 on: October 27, 2005, 03:51:27 PM »
You tell me the ansewr and I'll let you know if I saw it or not  :lol:

Offline Ulciscor

  • Moderator
  • Bot Destroyer
  • *****
  • Posts: 401
    • View Profile
Aim getting WAAAAAY too big
« Reply #16 on: October 27, 2005, 03:51:32 PM »
How can you take the absolute value of a boolean?!
:D Ulciscor :D

I used to be indecisive, but now I'm not so sure.

Offline PurpleYouko

  • Bot God
  • *****
  • Posts: 2556
    • View Profile
Aim getting WAAAAAY too big
« Reply #17 on: October 27, 2005, 03:51:47 PM »
:P
There are 10 kinds of people in the world
Those who understand binary.
and those who don't

:D PY :D

Offline PurpleYouko

  • Bot God
  • *****
  • Posts: 2556
    • View Profile
Aim getting WAAAAAY too big
« Reply #18 on: October 27, 2005, 03:52:10 PM »
What do I have to do? Hold your hand?
There are 10 kinds of people in the world
Those who understand binary.
and those who don't

:D PY :D

Offline Numsgil

  • Administrator
  • Bot God
  • *****
  • Posts: 7742
    • View Profile
Aim getting WAAAAAY too big
« Reply #19 on: October 27, 2005, 03:52:32 PM »
The only blaring mistake I see is that it should be If Abs(.mem(aimsx)) > 1256 Then

Offline Ulciscor

  • Moderator
  • Bot Destroyer
  • *****
  • Posts: 401
    • View Profile
Aim getting WAAAAAY too big
« Reply #20 on: October 27, 2005, 03:53:12 PM »
Yes! I agree!
:D Ulciscor :D

I used to be indecisive, but now I'm not so sure.

Offline PurpleYouko

  • Bot God
  • *****
  • Posts: 2556
    • View Profile
Aim getting WAAAAAY too big
« Reply #21 on: October 27, 2005, 03:54:34 PM »
WOOHOOO  :clap:  :party:

You got it.

The way it was written, it didn't matter how big .aimsx got. The function always returned 0 as the condition. I.e. it NEVER fulfilled the condition and limited .aimsx to 1256.
There are 10 kinds of people in the world
Those who understand binary.
and those who don't

:D PY :D

Offline Numsgil

  • Administrator
  • Bot God
  • *****
  • Posts: 7742
    • View Profile
Aim getting WAAAAAY too big
« Reply #22 on: October 27, 2005, 03:55:18 PM »
Weren't we saying that way back at the beginning though?  I thought there was something else I wasn't seeing.

Offline PurpleYouko

  • Bot God
  • *****
  • Posts: 2556
    • View Profile
Aim getting WAAAAAY too big
« Reply #23 on: October 27, 2005, 03:56:21 PM »
So here is the crash fix for those of out there who give a crap.

Code: [Select]
If Abs(.mem(aimsx) > 1256) Then .mem(aimsx) = 1256 * Sgn(.mem(aimsx)) 'new crash fix?
   If Abs(.mem(aimdx) > 1256) Then .mem(aimdx) = 1256 * Sgn(.mem(aimdx))

becomes
Code: [Select]
If Abs(.mem(aimsx)) > 1256 Then .mem(aimsx) = 1256 * Sgn(.mem(aimsx)) 'new crash fix?
   If Abs(.mem(aimdx)) > 1256 Then .mem(aimdx) = 1256 * Sgn(.mem(aimdx))
There are 10 kinds of people in the world
Those who understand binary.
and those who don't

:D PY :D

Offline Ulciscor

  • Moderator
  • Bot Destroyer
  • *****
  • Posts: 401
    • View Profile
Aim getting WAAAAAY too big
« Reply #24 on: October 27, 2005, 03:57:06 PM »
Quote
I'm guessing you need

Code: [Select]
(Abs(.mem(aimsx)) > 1256)
instead?
is different from

Code: [Select]
If Abs(.mem(aimsx)) > 1256 Then
How?
:D Ulciscor :D

I used to be indecisive, but now I'm not so sure.

Offline Numsgil

  • Administrator
  • Bot God
  • *****
  • Posts: 7742
    • View Profile
Aim getting WAAAAAY too big
« Reply #25 on: October 27, 2005, 03:59:49 PM »
An extra set of parenthesese  :lol:

Offline Ulciscor

  • Moderator
  • Bot Destroyer
  • *****
  • Posts: 401
    • View Profile
Aim getting WAAAAAY too big
« Reply #26 on: October 27, 2005, 04:00:21 PM »
Ah they can make all the difference!  :ph43r:
:D Ulciscor :D

I used to be indecisive, but now I'm not so sure.

Offline PurpleYouko

  • Bot God
  • *****
  • Posts: 2556
    • View Profile
Aim getting WAAAAAY too big
« Reply #27 on: October 27, 2005, 04:00:43 PM »
Sorry Ulc. I didn't notice you had moved a bracket. All I noticed was the extra one before the ABS.

The way you wrote it should work OK but the outer bracket set is just superfluous.
There are 10 kinds of people in the world
Those who understand binary.
and those who don't

:D PY :D

Offline Numsgil

  • Administrator
  • Bot God
  • *****
  • Posts: 7742
    • View Profile
Aim getting WAAAAAY too big
« Reply #28 on: October 27, 2005, 04:04:24 PM »
Ah, isn't coding wonderful ;)