GoldenEye: Source Forums

  • November 14, 2024, 10:08:35 pm
  • Welcome, Guest
Advanced search  

News:

Pages: [1]   Go Down

Author Topic: [BUG] 4.2.3: GEUtil.Trace() Can't Ignore A Bot Unless It's Told To DetectPlayers  (Read 6546 times)

0 Members and 1 Guest are viewing this topic.

Joe

  • Secret Agent
  • **
  • Posts: 139
  • Reputation Power: 54
  • Joe has an aura about them.Joe has an aura about them.Joe has an aura about them.Joe has an aura about them.Joe has an aura about them.Joe has an aura about them.Joe has an aura about them.Joe has an aura about them.Joe has an aura about them.Joe has an aura about them.
  • Offline Offline

Hi,

I discovered this yesterday when I was working on the new DAD mode version. This won't be a problem for this version.

So this function's GEUtil.Trace() call has to use the "GEUtil.TraceOpt.PLAYER" parameter even though this trace should only be searching for the ground beneath a player:

Code: [Select]
#maxSeperationDistanceBetweenGroundAndGroundedPlayer = 8.04
def isPlayerTouchingGround(self,player):
        playersLocation = player.GetAbsOrigin()
        endV = GEUtil.VectorMA(playersLocation,GEUtil.Vector(0,0,-1),self.maxSeperationDistanceBetweenGroundAndGroundedPlayer)
        return GEUtil.Trace(playersLocation,endV,GEUtil.TraceOpt.WORLD | GEUtil.TraceOpt.PLAYER,player)

When GEUtil.Trace() fails to ignore a bot it returns nothing.
« Last Edit: July 07, 2013, 10:06:24 am by Joe »
Logged
Free games:FPS + RTS: Renegade X & Battlezone 1.5,RTS: 7 Kingdoms & Open Red Alert, TBS:Hedgewars, playcatan.com & www.wesnoth.org
Pages: [1]   Go Up