TRollover, TOneway, TLightRollover, TTripwire, TEdgeManager ready.

This commit is contained in:
oz
2021-01-08 18:50:12 +03:00
parent 9bd064bf15
commit d19fb0476a
29 changed files with 632 additions and 160 deletions
+23
View File
@@ -1,2 +1,25 @@
#include "pch.h"
#include "TTripwire.h"
#include "control.h"
#include "loader.h"
#include "TBall.h"
#include "TPinballTable.h"
TTripwire::TTripwire(TPinballTable* table, int groupIndex) : TRollover(table, groupIndex, 1)
{
}
void TTripwire::Collision(TBall* ball, vector_type* nextPosition, vector_type* direction, float coef,
TEdgeSegment* edge)
{
ball->Position.X = nextPosition->X;
ball->Position.Y = nextPosition->Y;
ball->RayMaxDistance -= coef;
ball->not_again(edge);
if (!PinballTable->TiltLockFlag)
{
loader::play_sound(SoundIndex2);
control::handler(63, this);
}
}