Skip to content

CS:S - OnServerOutput Crash #404

Description

@Frag1337

EDIT: Please check #404 (comment)

Hello,

I'm currently having an issue where Source.Python crashes when two player's are inside the same trigger_push entity.

This is the console log:

2021-08-22 06:44:52 - sp    -    EXCEPTION    
[SP] Caught an Exception:
Traceback (most recent call last):
  File "..\addons\source-python\plugins\SurfTricks\libs\misc\hooks.py", line 101, in on_touch_pre
    entity = make_object(Entity, args[1])
  File "..\addons\source-python\packages\source-python\entities\_base.py", line 293, in _obj
    return cls(index_from_pointer(ptr))

ValueError: Conversion from "Pointer" (<_memory.Pointer object at 0x011F5C50>) to "Index" failed.

<=> CRASH <=>

Code:

@EntityPreHook(EntityCondition.is_human_player, "touch")
def on_touch_pre(args):
    player = make_object(Entity, args[0])
    entity = make_object(Entity, args[1])

sp info:

sp info

IMPORTANT: Please copy the full output.
--------------------------------------------------------
Checksum      : 5e3156dad6f48fe59901274827251ec8
Date          : 2021-08-23 00:36:57.404125
OS            : Windows-10-10.0.19041
Game          : css
SP version    : 705
Github commit : 38e4fe48579f9445b878624a9439ce10e28aa7e6
Server plugins:
   00: Metamod:Source 1.12.0-dev+1145
   01: Source.Python, (C) 2012-2020, Source.Python Team.
   02: Tickrate_Enabler 0.4, Didrole
SP plugins:
   00: SurfTricks, 1.6, http://trick.surf
--------------------------------------------------------

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Fields

    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions