Skip to main content

Python library for capturing and handling game events in Plutonium T6

Project description

GSC Events for Plutonium T6

A GSC script and Python library for capturing and handling game events in Plutonium T6 (Call of Duty: Black Ops 2).

Features

  • Captures various in-game events and saves them to JSONL files
  • Python library to read and process these events in real-time
  • Supports the following events:
    • Player Connected/Disconnected
    • Player Spawned/Death
    • Player Killed (with killer and weapon information)
    • Player Chat Messages
    • Killcam Start/End

Installation

Option 1: From GitHub Repository

1. Clone the repository:

git clone https://github.com/Yallamaztar/gsc-events.git

Option 2: Direct Installation

1. Copy gsc-events.gsc to your Plutonium T6 scripts folder:

%localappdata%\Plutonium\storage\t6\scripts\

2. Install the Python package:

pip install gsc-events

Event Format

Events are stored in JSONL format (one JSON object per line) in separate files for each event type. For example:

{ "event": "player_connected", "args": ["PlayerName"] }
{ "event": "player_say", "args": ["PlayerName", "message"] }
{ "event": "player_killed", "args": ["VictimName", "KillerName", "WeaponName"] }

Python Usage

from gsc_events import GSCClient

client = GSCClient()

@client.on("player_connected")
def on_connected(player: str) -> None:
    print(f"{player} Connected")

@client.on("player_spawned")
def on_spawned(player: str) -> None:
    print(f"{player} Spawned")

@client.on("player_death")
def on_death(player: str) -> None:
    print(f"{player} Died")

@client.on("player_killed")
def on_killed(player: str, attacker: str, reason: str) -> None:
    print(f"{player} was killed by {attacker} with {reason}")

@client.on("player_disconnect")
def on_disconnect() -> None:
    print(f"player Disconnected")

@client.on("player_say")
def on_say(player: str, message: str) -> None:
    print(f"{player} said {message}")

@client.on("killcam")
def on_killcam() -> None:
    print(f"Killcam started")

@client.on("killcam_end")
def on_killcam_end() -> None:
    print(f"Killcam ended")

client.run()

Events Reference

Event Name Arguments Description
player_connected player_name Triggered when a player connects
player_disconnected none Triggered when a player disconnects
player_spawned player_name Triggered when a player spawns
player_death player_name Triggered when a player dies
player_killed victim_name, killer_name, weapon Triggered when a player is killed by another player
player_say player_name, message Triggered when a player sends a chat message
killcam none Triggered when final killcam starts
killcam_end none Triggered when final killcam ends

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

gsc_events-0.1.0.tar.gz (4.3 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

gsc_events-0.1.0-py3-none-any.whl (5.4 kB view details)

Uploaded Python 3

File details

Details for the file gsc_events-0.1.0.tar.gz.

File metadata

  • Download URL: gsc_events-0.1.0.tar.gz
  • Upload date:
  • Size: 4.3 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.1.0 CPython/3.13.4

File hashes

Hashes for gsc_events-0.1.0.tar.gz
Algorithm Hash digest
SHA256 3dac852bc13743e35981e88f6ef513625e150a956356c88181e4b9990c1adaef
MD5 14a8b54811cf4ecf435eb41be60f72d1
BLAKE2b-256 ac38b0b18eadc9de0f60acb436891eb66e0a2be52d04c8146e6203e1367a3860

See more details on using hashes here.

File details

Details for the file gsc_events-0.1.0-py3-none-any.whl.

File metadata

  • Download URL: gsc_events-0.1.0-py3-none-any.whl
  • Upload date:
  • Size: 5.4 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.1.0 CPython/3.13.4

File hashes

Hashes for gsc_events-0.1.0-py3-none-any.whl
Algorithm Hash digest
SHA256 82db88d0d3580658febc0006a57a3d9ba8d6b9bb7aa8732c62033dbed184f628
MD5 b495c8fb43bf0db84f56a53ba4aa3fe3
BLAKE2b-256 8fcfc5df735a5de370ed6ff93f91fd019fbd9b3480001b409daa764ff8b3eb46

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page