Difference between revisions of "Half-Life 1 Game Events"
Line 4: | Line 4: | ||
In [[Pawn]] you are able to hook in-game events with [http://www.amxmodx.org/funcwiki.php?go=func&id=26 register_event]. Here are the list of the standard Half-Life 1 and Counter-Strike events and their parameters which can be read with [http://www.amxmodx.org/funcwiki.php?go=func&id=132 read_data] | In [[Pawn]] you are able to hook in-game events with [http://www.amxmodx.org/funcwiki.php?go=func&id=26 register_event]. Here are the list of the standard Half-Life 1 and Counter-Strike events and their parameters which can be read with [http://www.amxmodx.org/funcwiki.php?go=func&id=132 read_data] | ||
− | See [[Advanced Scripting (AMX Mod X)]] for more on events and messages. | + | See [[Advanced Scripting (AMX Mod X)#Events.2FMessages]] for more on events and messages. |
== ADStop == | == ADStop == |
Revision as of 07:04, 23 August 2006
Contents
- 1 Half-Life Events
- 1.1 ADStop
- 1.2 AllowSpec
- 1.3 AmmoPickup
- 1.4 AmmoX
- 1.5 BarTime
- 1.6 BarTime2
- 1.7 Battery
- 1.8 BlinkAcct
- 1.9 BombDrop
- 1.10 BombPickup
- 1.11 BotProgress
- 1.12 BotVoice
- 1.13 Brass
- 1.14 BuyClose
- 1.15 ClCorpse
- 1.16 Crosshair
- 1.17 CurWeapon
- 1.18 CZCareer
- 1.19 CZCareerHUD
- 1.20 Damage
- 1.21 DeathMsg
- 1.22 FlashBat
- 1.23 Flashlight
- 1.24 Fog
- 1.25 ForceCam
- 1.26 HostageK
- 1.27 HostagePos
- 1.28 NVGToggle
- 1.29 ResetHUD
- 1.30 RoundTime
- 1.31 SayText
- 1.32 Scenario
- 1.33 ScoreAttrib
- 1.34 StatusIcon
- 1.35 StatusText
- 1.36 StatusValue
- 1.37 TaskTime
- 1.38 TeamInfo
- 1.39 TeamScore
- 1.40 TextMsg
- 1.41 Train
- 1.42 TutorClose
- 1.43 TutorLine
- 1.44 TutorState
- 1.45 TutorText
- 1.46 VGUIMenu
- 1.47 ViewMode
- 1.48 VoiceMask
- 1.49 WeapPickup
- 1.50 Money
Half-Life Events
In Pawn you are able to hook in-game events with register_event. Here are the list of the standard Half-Life 1 and Counter-Strike events and their parameters which can be read with read_data
See Advanced Scripting (AMX Mod X)#Events.2FMessages for more on events and messages.
ADStop
Note: No Information available for this event
Name: | ADStop | |
Structure: |
|
AllowSpec
Note: No Information available for this event
Name: | AllowSpec | ||
Structure: |
|
AmmoPickup
Temporarily draws HUD the ammo amount and ammo type HUD icon in the middle of the right side of the screen.
Note: Draw time is dependent on the hud_drawhistory_time client CVAR value
Name: | AmmoPickup | ||||
Structure: |
|
AmmoX
Updates green bar indicator in the HUD weapons-list. Also updates HUD backpack ammo number in the lower right corner of the screen in case the given ammo type are compatible with the current weapon.
Name: | AmmoX | ||||
Structure: |
|
BarTime
Draws a HUD progress bar which is filled from 0% to 100% for the time Duration seconds and then disappeared.
Note: Set Duration to 0 to hide the bar.
Name: | BarTime | ||
Structure: |
|
BarTime2
The same as BarTime but StartPC is specify how many per cents of the bar are (already) filled.
Note: Display time can be calculated with this formula: (1 - StartPC/100) / Duration
Name: | BarTime2 | ||||
Structure: |
|
Battery
Updates the icon and number of the armor on the HUD.
Name: | Battery | ||
Structure: |
|
BlinkAcct
Note: No Information available for this event
Name: | BlinkAcct | |
Structure: |
|
BombDrop
The first three arguments are the origin of the dropped bomb. The last argument is set to 1 if the bomb has been planted. It is 0 if the bomb was dropped due to voluntary dropping or death/disconnect. Setting the last argument 1, will also trigger the round timer to hide. It also will show the dropped bomb on the Terrorist team's radar in the location specified by the first three arguments.
Name: | BombDrop | ||||||||
Structure: |
|
BombPickup
This message just tells the game that the bomb has been picked up. It will cause the dropped/planted bomb to disappear from the Terrorist team's radar.
Name: | BombPickup | |
Structure: |
|
BotProgress
Note: No Information available for this event
Name: | BotProgress | |
Structure: |
|
BotVoice
Note: No Information available for this event
Name: | BotVoice | ||||
Structure: |
|
Brass
Note: No Information available for this event
Name: | Brass | |
Structure: |
|
BuyClose
Note: No Information available for this event
Name: | BuyClose | |
Structure: |
|
ClCorpse
Spawns a player's corpse. Model is the player's model, for example: "leet". Delay is the delay before animation plaback, can be negative value.
Note: The Origin and Delay is in non-standard format.
Name: | ClCorpse | ||||||||||||||||||||||||
Structure: |
|
Crosshair
Draws/removes the crosshair. If Flag is set to 1 the crosshair will be drawn.
Name: | Crosshair | ||
Structure: |
|
CurWeapon
Updates the clip ammo number and weapon's corresponding ammo type icon on the HUD.
Name: | CurWeapon | ||||||
Structure: |
|
CZCareer
Note: No Information available for this event
Name: | CZCareer | |
Structure: |
|
CZCareerHUD
Note: No Information available for this event
Name: | CZCareerHUD | |
Structure: |
|
Damage
Note: No Information available for this event
Name: | Damage | ||||||||||||
Structure: |
|
DeathMsg
Fired to all players (MSG_ALL or MSG_BROADCAST) to notify them of a death. This generates the HUD message the client sees in the upper right corner of their screen.
Also prints the console text message "KillerName killed VictimName with WeaponName" or "*** KillerName killed VictimName with a headshot from WeaponName ***"
Name: | DeathMsg | ||||||||
Structure: |
|
FlashBat
Updates the flashlight battery charge on the HUD. ChargePC is in per cents.
Name: | FlashBat | ||
Structure: |
|
Flashlight
Updates the flashlight state and battery charge on the HUD. If Flag is set to 1 the flashlight HUD icon will be shown as active.
Name: | Flashlight | ||||
Structure: |
|
Fog
Note: No Information available for this event
Name: | Fog | |
Structure: |
|
ForceCam
Note: No Information available for this event
Name: | ForceCam | |
Structure: |
|
HostageK
Temporary draws a blinking red dot on the CT players' radar when hostage is killed.
Name: | HostageK | ||
Structure: |
|
HostagePos
Draws/updates the blue mark on the CT players' radar which represents the corresponding hostage's position.
Name: | HostagePos | ||||||||||
Structure: |
|
NVGToggle
Toggles night vision mode. For Flag: 1 is on, 0 is off.
Name: | NVGToggle | ||
Structure: |
|
ResetHUD
Resets the HUD.
Name: | ResetHUD | |
Structure: |
|
RoundTime
Updates the round timer on the HUD. Time is in seconds.
Name: | RoundTime | ||
Structure: |
|
SayText
Prints say HUD text. Second parameter can be a predefined string or a custom one. In the last case the last two parameters isn't required.
Some values of the predifined string: #Cstrike_Chat_AllDead, #Cstrike_Chat_All
Name: | SayText | ||||||||
Structure: |
|
Scenario
Note: No Information available for this event
Name: | Scenario | ||
Structure: |
|
ScoreAttrib
Updates the scoreboard's attribute for the specified player. For the 2nd argument, 0 is nothing, 1 is dead, 2 is bomb, 4 is VIP.
Note: Flag is a bitwise value so if VIP player dying with the bomb the Flag will be 7
Name: | ScoreAttrib | ||||
Structure: |
|
StatusIcon
Draws/removes the specified status HUD icon. For Status, 0 is Hide Icon, 1 is Show Icon, 2 is Flash Icon. Red, Green and Blue arguments is optional and is specified only when Status are not 0.
Name: | StatusIcon | ||||||||||
Structure: |
|
StatusText
Specifies the status text format.
Name: | StatusText | ||||
Structure: |
|
StatusValue
Sends/updates the status values. For the Flag 1 the Value is TeamRelation, for 2 is PlayerID, for 3 is Health. For TeamRelation, 1 is Teammate player, 2 is Non-Teammate player, 3 is Hostage. If TeamRelation is the Hostage, PlayerID will be always 0.
Note: Usually is fired as a triple message, for example:
(1, 2) - non-teammate player
(2, 7) - player index is 7
(3, 59) - health is 59
Name: | StatusValue | ||||
Structure: |
|
TaskTime
Note: No Information available for this event
Name: | TaskTime | |
Structure: |
|
TeamInfo
TeamName is either "UNASSIGNED", "TERRORIST" or "CT".
Name: | TeamInfo | ||||
Structure: |
|
TeamScore
Updates the team score on the score board. TeamName is either "TERRORIST" or "CT".
Name: | TeamScore | ||||
Structure: |
|
TextMsg
Note: There does not necessarily have to be a total of 6 arguments, there could be as little as 2. For example you can send a message with the following:
Arg1: 1
Arg2: #Game_join_ct
Arg3: 4HM
Name: | TextMsg | ||||||||||||
Structure: |
|
Train
Note: No Information available for this event
Name: | Train | ||
Structure: |
|
TutorClose
Note: No Information available for this event
Name: | TutorClose | |
Structure: |
|
TutorLine
Note: No Information available for this event
Name: | TutorLine | |
Structure: |
|
TutorState
Note: No Information available for this event
Name: | TutorState | |
Structure: |
|
TutorText
Note: No Information available for this event
Name: | TutorText | |
Structure: |
|
VGUIMenu
Displays a predefined VGUI menu. Keys is a keys bit sum.
Name: | VGUIMenu | ||||||||||
Structure: |
|
ViewMode
Note: No Information available for this event
Name: | ViewMode | |
Structure: |
|
VoiceMask
Note: No Information available for this event
Name: | VoiceMask | ||||
Structure: |
|
WeapPickup
Fired right before weapon is picked up.
Note: Notice: "right before".
Name: | WeapPickup | ||
Structure: |
|
Money
Updates the Amount of money on the HUD. If the Flag is 1, the additional new-old HUD money amount difference will be also displayed.
Name: | Money | ||||
Structure: |
|