Razor
DonCorleone
Dołączył: 22 Maj 2008
Posty: 3029
Przeczytał: 0 tematów
Ostrzeżeń: 0/5
|
Wysłany:
Pon 11:38, 12 Mar 2012 |
|
[link widoczny dla zalogowanych]
Kod: |
LOCATE CHARACTER ANY MEANS
Waits for a particular character to enter a particular 'location', ie an (X,Y,Z) with a (width,height) giving the ability to check a 'box' rather than just one particular block. This 'box' can be less than a block in width/height.
This is NOT a blocking function, it will return TRUE when this character enters the box whether on foot or driving a car, FALSE otherwise. If necessary, I can change it to return TRUE if a passenger inside a car - this will complicate the code however.
LOCATE_CHARACTER_ANY_MEANS (charname, X,Y,Z, width,height)
Example:
LOCATE_CHARACTER_ANY_MEANS (playerone, 123.5,45.5,2.0, 3.0,1.0)
This would check for the player entering the box (120.5,44.5,2.0) to (126.5,46.5,2.0).
Parameters
charname Name of a previously created character, including the player character.
X,Y,Z float centre point of 'box' to check
width,height float dimensions of box to check for character.
LOCATE CHARACTER ON FOOT
Waits for a particular character to enter a particular 'location', ie an (X,Y,Z) with a (width,height) giving the ability to check a 'box' rather than just one particular block. This 'box' can be less than a block in width/height.
This is NOT a blocking function, it will return TRUE ONLY when this character enters the box on foot, FALSE otherwise
LOCATE_CHARACTER_ON_FOOT (charname, X,Y,Z, width,height)
This would check for the player entering the box 120.5, 44.5, 2.0 to 126.5, 46.5, 2.0 on foot only:
LOCATE_CHARACTER_ON_FOOT (playerone, 123.5,45.5,2.0, 3.0,1.0)
Parameters
charname Name of a previously created character, including the player character.
X,Y,Z float centre point of 'box' to check
width,height float dimensions of box to check for character.
LOCATE CHARACTER BY CAR
Waits for a particular character to enter a particular ‘location’, ie an (X,Y,Z) with a (width,height) giving the ability to check a box rather than just one particular block. This box can be less than a block in width or height.
This is not a blocking function, it will return TRUE only when this character enters the box driving a car, FALSE otherwise. As with ANY_MEANS, I may change this to return TRUE if the character is a passenger in a car.
LOCATE_CHARACTER_BY_CAR (charname, X,Y,Z, width,height)
This would check for the player entering the box (120.5,44.5,2.0) to (126.5,46.5,2.0) on foot only:
LOCATE_CHARACTER_BY_CAR (playerone, 123.5,45.5,2.0, 3.0,1.0)
Parameters
charname Name of a previously created character, including the player character.
X,Y,Z float Centre point of 'box' to check
width,height float Dimensions of box to check for character:
LOCATE STOPPED CHARACTER
These operate exactly like LOCATE_CHARACTER, except for one difference: the character must *stationary* inside the box, ie have zero speed. Returns TRUE when character fulfils condition, FALSE otherwise.
LOCATE_STOPPED_CHARACTER_ANY_MEANS (charname, X,Y,Z, Width,float Height)
LOCATE_STOPPED_CHARACTER_ON_FOOT (charname, X,Y,Z, Width,float Height)
LOCATE_STOPPED_CHARACTER_BY_CAR (charname, X,Y,Z, Width,float Height)
Example
LOCATE_STOPPED_CHARACTER_ON_FOOT (dummychar, 253.0,12.0,3.0, 1.0,5.0)
This will return TRUE when the character dummychar stops in the box (252.0,7.0) to 254.0,17.0) at height 3.0 |
|
|
|