Unit 'agraphics' Package
[Overview][Constants][Types][Procedures and functions][Variables][Index] [#os4units]

TVSprite

Sprite description

Declaration

Source position: agraphics.pas line 745

type TVSprite = record

  NextVSprite: PVSprite;

  

GEL linked list forward pointer sorted by y,x value

  PrevVSprite: PVSprite;

  

GEL linked list backward pointer sorted by y,x value

  DrawPath: PVSprite;

  

Pointer of overlay drawing

  ClearPath: PVSprite;

  

Pointer for overlay clearing

  OldY: SmallInt;

  

Previous x position

  OldX: SmallInt;

  

Previous y position

  Flags: SmallInt;

  

VSprite flags

  Y: SmallInt;

  

Screen y position

  X: SmallInt;

  

Screen x position

  Height: SmallInt;

  

Number of lines of image data

  Width: SmallInt;

  

Number of words per row of image data

  Depth: SmallInt;

  

Number of planes

  MeMask: SmallInt;

  

Which types can collide with this VSprite

  HitMask: SmallInt;

  

Which types this VSprite can collide with

  ImageData: PSmallInt;

  

Pointer to VSprite image

  BorderLine: PSmallInt;

  

Logical OR of all VSprite bits

  CollMask: PSmallInt;

  

Similar to above except this is a matrix

  SprColors: PSmallInt;

  

Pointer to this VSprite's color definitions (not used by Bobs)

  VSBob: PBob;

  

(PBob) points home if this VSprite is part of a Bob

  PlanePick: ShortInt;

  

Plane flags

  PlaneOnOff: ShortInt;

  

  VUserExt: SmallInt;

  

User definable

end;

Description

The VSprite positions are defined in (y,x) order to make sorting sorting easier, since (y,x) as a long Longint.

BorderLine is the one-dimensional logical OR of all the VSprite bits, used for fast collision detection of edge

PlanePick flag: set bit selects a plane from image, clear bit selects use of shadow mask for that plane OnOff flag: if using shadow mask to fill plane, this bit (corresponding to bit in planePick) describes whether to fill with 0's or 1's

There are two uses for these flags:


Documentation generated on: 2021-07-30