Adrian Ilie
University of North Carolina at Chapel Hill
Computer Science Department
Home
Research
Publications
Coursework
Personal
Links
 

Half-Life 2 Entity Controller

EntCon is a plugin for EventScripts Python, which is a server-side plugin for Valve's Source Games. It can be used to manipulate entities (NPCs) in ObjectVideo's Virtual Video Tool. It consists of two parts: a Python script that runs on the game server and a C++ class that can be incorporated into a client application.

Usage:

Game server:

  • Download and install EventScripts Python from http://python.eventscripts.com/
  • Consult the EventScripts documentation for installation instructions.
  • Put entcon.py into an entcon subdirectory inside the EventScripts directory.
  • Load entcon with the "es_load entcon" console command.

Client application:

  • Copy EntCon.h and EntCon.cpp into your application directory.
  • Add EntCon.h and EntCon.cpp to your application source.
  • Create an instance of the EntCon class.
  • Call the constructor and the Connect() function.
  • Call the List() function with a properly initialized buffer and entity name (ex: "npc_citizen") to get a list of entities.
  • Call the GetPos(), SetPos(), GetAng(), SetAng() and MoveBy() functions using one of the ids from List().
  • Note: The entity with id 0 is the player, which can be moved but not oriented.

Links:

The latest version of EntCon can be downloaded frome here.

 
Zipcar: wheels when you want them. Learn more. Locations of visitors to this page
Last modified Tuesday, Jun 23, 2009 by Adrian Ilie
eXTReMe Tracker Site Meter