EVENT

From MyGamingTalk
Revision as of 20:05, 13 July 2021 by Palota (talk | contribs) (1 revision imported)
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)
Script Reference EVENT Constant

Event Usage

Events can be assigned callbacks in scripts, normally in the bot scripts.

For Example:

 this.Events[EVENT.TEAM_CHAT_MSG] = function(WhoSaidIt, Message)
 {
 	n = GetEntName(WhoSaidIt);
 	this.Say(n, "said: ", Message);
 	print(n, "said: ", Message);
 };

Common Events

ADDWEAPON

Parameters:

  • weaponId

CHANGECLASS

Parameters:

  • newclass

CHANGETEAM

Parameters:

  • newteam

DEATH

Parameters:

  • inflictor
  • meansofdeath

DISCONNECTED

Parameters: none

ENT_ENTER_RADIUS

Parameters:

  • ent

ENT_LEAVE_RADIUS

Parameters:

  • ent

FEEL_PAIN

Parameters:

  • inflictor
  • previoushealth
  • currenthealth

GLOBAL_CHAT_MSG

Parameters:

  • whosaidit
  • whattheysaid

GLOBAL_VOICE

Parameters:

  • source
  • macro id

HEALED

Parameters:

  • whohealedme

KILLEDSOMEONE

Parameters:

  • victim
  • meansofdeath

MG_ENTER_RADIUS

Parameters:

  • MapGoal

MG_LEAVE_RADIUS

Parameters:

  • MapGoal

PRIV_CHAT_MSG

Parameters:

  • whosaidit
  • whattheysaid

PRIVATE_VOICE

Parameters:

  • macro id

PROXIMITY_TRIGGER

Parameters:

  • owner
  • ent
  • position

REFRESH_WEAPON

Parameters:

  • weapon

REMOVEWEAPON

Parameters:

  • weaponId

RESET_WEAPONS

Parameters: none

REVIVED

Parameters:

  • whorevivedme

SCRIPTMSG

Parameters:

  • msg
  • data1
  • data2
  • data3

SPAWNED

Parameters: none

TEAM_CHAT_MSG

Parameters:

  • whosaidit
  • whattheysaid

TEAM_VOICE

Parameters:

  • source
  • macro id

WEAPON_CHANGE

Parameters:

  • weaponId

WEAPON_FIRE

Parameters:

  • weaponId
  • projectile entity

Enemy Territory Events

AMMO_RECIEVED

Parameters:

  • whogaveammo

FIRETEAM_CHAT_MSG

Parameters:

  • whosaidit
  • whattheysaid

FIRETEAM_CREATED

Parameters:

  • fireteamnum

FIRETEAM_DISBANDED

Parameters:

  • none

FIRETEAM_JOINED

Parameters:

  • teamleader

FIRETEAM_LEFT

Parameters:

  • none

FIRETEAM_INVITED

Parameters:

  • teamleader

FIRETEAM_PROPOSAL

Parameters:

  • invitee

FIRETEAM_WARNED

Parameters:

  • warnedby

MORTAR_IMPACT

Parameters:

  • position

POSTTRIGGERED_MINE

Parameters:

  • mine_entity

PRETRIGGERED_MINE

Parameters:

  • mine_entity

Fortress Forever Events

DETPACK_ALREADYBUILT

Parameters: none

DETPACK_BUILDING

Parameters:

  • detpack entity

DETPACK_BUILT

Parameters:

  • detpack entity

DETPACK_CANTBUILD

Parameters: none

DETPACK_DETONATED

Parameters: none

DETPACK_NOAMMO

Parameters: none

DISGUISED

Parameters:

  • asTeam
  • asClass

DISGUISING

Parameters:

  • asTeam
  • asClass

DISPENSER_ALREADYBUILT

Parameters: none

DISPENSER_BUILDING

Parameters:

  • dispenser entity

DISPENSER_BUILT

Parameters:

  • dispenser entity

DISPENSER_CANTBUILD

Parameters: none

DISPENSER_DAMAGED

Parameters:

  • inflictor

DISPENSER_DESTROYED

Parameters: none

DISPENSER_DETONATED

Parameters: none

DISPENSER_DISMANTLED

Parameters: none

DISPENSER_ENEMYUSED

Parameters:

  • user entity

DISPENSER_NOAMMO

Parameters: none

INVALID_DISGUISE_CLASS

Parameters:

  • class

INVALID_DISGUISE_TEAM

Parameters:

  • team

RADAR_DETECTENEMY

Parameters:

  • detected

RADIOTAG_UPDATE

Parameters:

  • detected

SENTRY_ALREADYBUILT

Parameters: none

SENTRY_BUILDING

Parameters:

  • sentry entity

SENTRY_BUILT

Parameters:

  • sentry entity

SENTRY_CANTBUILD

Parameters: none

SENTRY_DAMAGED

Parameters:

  • inflictor

SENTRY_DESTROYED

Parameters: none

SENTRY_DETONATED

Parameters: none

SENTRY_DISMANTLED

Parameters: none

SENTRY_NOAMMO

Parameters: none

SENTRY_SPOTENEMY

Parameters:

  • enemy entity seen

SENTRY_UPGRADED

Parameters:

  • level


Other Events

GROUP_CHAT_MSG

Parameters:

  • whosaidit
  • whattheysaid

HEAR_SOUND

Parameters:

  • source
  • origin
  • soundId
  • soundName

PLAYER_USE

Parameters:

  • whotouchedme

SENSE_ENTITY

Parameters:

  • sensedclass
  • sensedentity


See also: Events