Pattern script

From Blood Wiki
(Difference between revisions)
Jump to: navigation, search
(Operators)
(Introduction)
Line 2: Line 2:
 
Pattern scripts is special kind of expressions that returns 1 or 0. Pattern scripts are used to determine availability of some functionality or event.
 
Pattern scripts is special kind of expressions that returns 1 or 0. Pattern scripts are used to determine availability of some functionality or event.
  
Pattern scripts are used:
+
Pattern scripts are used by:
  
* By monsters to check if its a time to spawn/hide
+
* Enemy appearance (some enemies are only activa at night, some only at day etc.)
* By gamemodels to check if could be damaged by certain weapon
+
* Gamemodels (could be damaged by certain weapon)
  
 
= Operators =
 
= Operators =

Revision as of 09:46, 3 July 2012

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.

Pattern scripts are used by:

  • Enemy appearance (some enemies are only activa at night, some only at day etc.)
  • Gamemodels (could be damaged by certain weapon)

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
Personal tools
Namespaces

Variants
Actions
Navigation
Toolbox