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

Function cCircleAround

source/modes/ConsoleCommands.cpp:334–352  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

332}
333
334Command::Result cCircleAround(const Command::ArgumentList_t& args, ConsoleInterface& c, AbstractModeManager&)
335{
336 if(args.size() < 4)
337 {
338 c.print("\nERROR: You need to specify an circle center "
339 "(two coordinates) and circle radius\n");
340 return Command::Result::INVALID_ARGUMENT;
341 }
342
343 ODFrameListener& frameListener = ODFrameListener::getSingleton();
344 CameraManager* cm = frameListener.getCameraManager();
345 int centerX = Helper::toDouble(args[1]);
346 int centerY = Helper::toDouble(args[2]);
347 unsigned int radius = Helper::toDouble(args[3]);
348
349
350 cm->circleAround(centerX, centerY, radius);
351 return Command::Result::SUCCESS;
352}
353
354Command::Result cHermiteCatmullSpline(const Command::ArgumentList_t& args, ConsoleInterface& c, AbstractModeManager&)
355{

Callers

nothing calls this directly

Calls 4

toDoubleFunction · 0.85
getCameraManagerMethod · 0.80
circleAroundMethod · 0.80
printMethod · 0.45

Tested by

no test coverage detected