void Rect<T>::set(const T &x, const T &y, const T &w, const T &h) { setXY(x, y); setWH(w, h); }
Bomb::Bomb(int _X, int _Y): Sprites("Balst.png",3 , 5){ //set fuse animation loop loopMode(true, 0 ,5); setWH(20 ,20); //this is a blastlet setBlast(true); //initialises the objects member variables setPosX(_X); setPosY(_Y); setPos(getPosX(), getPosY()); }
//constructor with button object initialised in initialiser list textIn::textIn ( int _x, int _y, int _width, int _height, sf::RenderWindow &_rw): Sprites( _rw, "media/cb.bmp") { //selected is default false setSelected(false); //set x y and width of box heights set at 30 for now setXY( _x, _y); setWH(_width, _height); setCaret(_x, _y, getHeight()); caretIndex = 1; caretPosition.push_back(caretX); if (!font.loadFromFile("media/Pink Bunny.ttf")){ std::cout<<"Likely name of font incorrect"; } setRects(); }
Bomb::Bomb(int _X, int _Y, int _F, int _T): Sprites("Balst.png",3 , 5){ //set fuse animation loop loopMode(true, 10 ,15); //initialises the objects member variables setPosX(_X); setPosY(_Y); setPos(getPosX(), getPosY()); setBombTicks(_T); setFlame(_F); setWH(20 ,20); //not used yet setUsed(false); //not igniting setIgnite(false); //is a bomb not a blast setBlast(false); }
void CSulGuiDial::init() { CSulGuiCanvas::init(); setWH( m_radius*2.0f, m_radius*2.0f ); CSulGeodeCircle* pCircle = new CSulGeodeCircle( m_radius ); pCircle->setOffset( osg::Vec3(m_radius, m_radius, 0.0f) ); addChild( pCircle ); m_mt = new osg::MatrixTransform; osg::Matrix m; m.setTrans( osg::Vec3(m_radius,m_radius,0) ); m_mt->setMatrix( m ); CSulGeomArrow2D* pArrow = new CSulGeomArrow2D( m_radius, 10.0f, 10.0f ); m_mt->addChild( pArrow ); addChild( m_mt ); getEventHandler()->wantEvent( this, this, CSulGuiEventHandler::EVENT_MOUSERELEASE ); showCanvas( false ); }
OpenShortResult::OpenShortResult(): mWidth(0) ,mHeight(0) ,mPointReulst(0) ,mLineResult(0) ,mPointNG(0) ,mSecondNG(0) ,mLineNG(0) ,mCycleTxDiff(0) ,mTXPointShortResult(0) ,mCycleRxDiff(0) ,mRXPointShortResult(0) ,mLineNearFarValue(0) ,mLineNearFarResult(0) ,lostSide(0) { mPointNG = 0; mLineNG = 0; mPointReulst = 0; mLineResult = 0; setWH(DEFAULT_W, DEFAULT_H); }
OpenShortResult::OpenShortResult(int w, int h) : mWidth(w) ,mHeight(h) ,mPointReulst(0) ,mLineResult(0) ,mPointNG(0) ,mSecondNG(0) ,mLineNG(0) ,mCycleTxDiff(0) ,mTXPointShortResult(0) ,mCycleRxDiff(0) ,mRXPointShortResult(0) ,mLineNearFarValue(0) ,mLineNearFarResult(0) ,lostSide(0) { mPointNG = 0; mLineNG = 0; mPointReulst = 0; mLineResult = 0; setWH(w, h); }