Pattern script

From Blood Wiki
(Difference between revisions)
Jump to: navigation, search
Line 11: Line 11:
 
* Gamemodels damage masks (checks if could be damaged by certain weapon)
 
* Gamemodels damage masks (checks if could be damaged by certain weapon)
 
* Checking if trigger could be touched
 
* Checking if trigger could be touched
 
  
  
Line 74: Line 73:
 
| Logical Not
 
| Logical Not
 
|}
 
|}
 +
  
 
= Functions =
 
= Functions =

Revision as of 10:13, 3 July 2012

Contents

Introduction

Pattern scripts is special kind of expressions that returns 1 or 0.

Pattern scripts are used to determine availability of some functionality or event, checks for special conditions.

Pattern scripts can check for very wide range of conditions (gametime, special parms of entities, infoportions etc.).

Example of things controlled by pattern scripts:

  • Enemy appearance (some enemies are only active at night, some only at day etc.)
  • Gamemodels damage masks (checks if could be damaged by certain weapon)
  • Checking if trigger could be touched


Operators

# Operator Description # Operator Description # Operator Description
1 ( expression ) Expression 6 x > y Greater 11 x >< start end x > start And x < end
2 x & y Logical 'And' 7 x >= y Greater or equal 12 x =>< start end x >= start And x < end
3 x | y Logical 'Or' 8 x < y Lesser 13 x ><= start end x > start And x <= end
4 x = y Equal 9 x <= y Lesser or equal 14 x =><= start end x >= start And x <= end
5 x != y Not equal 10 x & not y Logical Not


Functions

Set of functinos is determined by pattern realisations. There is two pattern realizations as of yet.

GenericPattern

This is generic appearance pattern. It used on monster's appecrance, zone (check if zone is active).

GamemodelHitPattern

Personal tools
Namespaces

Variants
Actions
Navigation
Toolbox