hedgewars/uVisualGears.pas
branchwebgl
changeset 8026 4a4f21070479
parent 7822 61ff669d610f
child 8330 aaefa587e277
equal deleted inserted replaced
8023:7de85783b823 8026:4a4f21070479
    80 
    80 
    81 
    81 
    82 // ==================================================================
    82 // ==================================================================
    83 
    83 
    84 // ==================================================================
    84 // ==================================================================
    85 const doStepHandlers: array[TVisualGearType] of TVGearStepProcedure =
    85 const vdoStepHandlers: array[TVisualGearType] of TVGearStepProcedure =
    86         (
    86         (
    87             @doStepFlake,
    87             @doStepFlake,
    88             @doStepCloud,
    88             @doStepCloud,
    89             @doStepExpl,
    89             @doStepExpl,
    90             @doStepExpl,
    90             @doStepExpl,
   158 New(gear);
   158 New(gear);
   159 FillChar(gear^, sizeof(TVisualGear), 0);
   159 FillChar(gear^, sizeof(TVisualGear), 0);
   160 gear^.X:= real(X);
   160 gear^.X:= real(X);
   161 gear^.Y:= real(Y);
   161 gear^.Y:= real(Y);
   162 gear^.Kind := Kind;
   162 gear^.Kind := Kind;
   163 gear^.doStep:= doStepHandlers[Kind];
   163 gear^.doStep:= vdoStepHandlers[Kind];
   164 gear^.State:= 0;
   164 gear^.State:= 0;
   165 gear^.Tint:= $FFFFFFFF;
   165 gear^.Tint:= $FFFFFFFF;
   166 gear^.uid:= VGCounter;
   166 gear^.uid:= VGCounter;
   167 gear^.Layer:= 0;
   167 gear^.Layer:= 0;
   168 
   168