Author Topic: [SOURCEMOD] Brutal-OXCE 7.12.1  (Read 74521 times)

Offline Reuged

  • Sergeant
  • **
  • Posts: 15
    • View Profile
Re: [SOURCEMOD] Brutal-OXCE 7.12.1
« Reply #615 on: March 23, 2024, 10:13:07 pm »
maybe the targeting calculations is mess up when you re-work the targeting system cuz whenever i move the mouse off the limits, the values decrease to zero as intended but it quickly come back to original values
« Last Edit: March 23, 2024, 10:15:37 pm by Reuged »

Offline Xilmi

  • Moderator
  • Commander
  • ***
  • Posts: 605
    • View Profile
Re: [SOURCEMOD] Brutal-OXCE 7.12.1
« Reply #616 on: March 23, 2024, 10:29:05 pm »
maybe the targeting calculations is mess up when you re-work the targeting system cuz whenever i move the mouse off the limits, the values decrease to zero as intended but it quickly come back to original values
I think I found it. It's not the targeting-calculations itself that are faulty but the cursor-drawing. There he replaced the line:

totalDamage -= rule->getPowerRangeReduction(distance * 16);

with

totalDamage -= rule->getPowerRangeReduction(distanceTiles * 16);

In this case "distanceTiles" is supposed to be the same that "distance" previously was. However, "distanceTiles" is initialized with 0 and only calculated for the accuracy-dropoff-part wheras distance was initialized like this:

int distance = (int)std::ceil(sqrt(float(distanceSq)));

I think that simply initializing distanceTiles the same way distance was initialized should fix the issue.

Offline Reuged

  • Sergeant
  • **
  • Posts: 15
    • View Profile
Re: [SOURCEMOD] Brutal-OXCE 7.12.1
« Reply #617 on: March 23, 2024, 10:33:46 pm »
 :) :) :) :) :) :) :) :) :) :) :) :) :) :) :) :) :) :) :) :) :) :) cool let's try it out
« Last Edit: March 23, 2024, 10:35:35 pm by Reuged »

Offline jnarical

  • Captain
  • ***
  • Posts: 50
    • View Profile
Re: [SOURCEMOD] Brutal-OXCE 7.12.1
« Reply #618 on: April 09, 2024, 08:31:36 am »
I think that simply initializing distanceTiles the same way distance was initialized should fix the issue.

Does that work?

Offline Xilmi

  • Moderator
  • Commander
  • ***
  • Posts: 605
    • View Profile
Re: [SOURCEMOD] Brutal-OXCE 7.12.1
« Reply #619 on: April 09, 2024, 11:56:12 am »
Does that work?
Yes, this helped for this issue. But I've found a new issue with something else since.