MCPcopy Create free account
hub / github.com/OpenDungeons/OpenDungeons / getCurrentXLeft

Method getCurrentXLeft

source/camera/SlopeWalk.cpp:155–163  ·  view source on GitHub ↗

get the value of slope currently pointed by index on the left path

Source from the content-addressed store, hash-verified

153
154// get the value of slope currently pointed by index on the left path
155int64_t SlopeWalk::getCurrentXLeft(int64_t yy)
156{
157 if(mLeftSlopeIndex != mLeftSlopes.begin())
158 {
159 return getPreviousLeftVertex().x + ((*mLeftSlopeIndex) * (yy - getPreviousLeftVertex().y))/VectorInt64::UNIT ;
160 }
161 else
162 return getCurrentLeftVertex().x;
163}
164
165// get the value of slope currently pointed by index on the right path
166int64_t SlopeWalk::getCurrentXRight(int64_t yy)

Callers 1

newBashAndSplashTilesMethod · 0.80

Calls

no outgoing calls

Tested by

no test coverage detected