SpaceCadetPinball/SpaceCadetPinball/TPlunger.h

28 lines
739 B
C
Raw Permalink Normal View History

#pragma once
#include "TCollisionComponent.h"
class TPlunger :
public TCollisionComponent
{
public:
2021-01-07 17:00:38 +01:00
TPlunger(TPinballTable* table, int groupIndex);
~TPlunger() override = default;
2022-05-20 10:51:00 +02:00
void Collision(TBall* ball, vector2* nextPosition, vector2* direction, float distance,
2021-01-07 17:00:38 +01:00
TEdgeSegment* edge) override;
int Message(MessageCode code, float value) override;
2021-01-07 17:00:38 +01:00
static void BallFeedTimer(int timerId, void* caller);
static void PullbackTimer(int timerId, void* caller);
static void ReleasedTimer(int timerId, void* caller);
2021-01-07 17:00:38 +01:00
int PullbackTimer_;
int BallFeedTimer_;
float MaxPullback;
float PullbackIncrement;
float PullbackDelay;
2021-01-07 17:00:38 +01:00
int SoundIndexP1;
int SoundIndexP2;
bool PullbackStartedFlag{};
int SomeCounter{};
};