1 //////////////////////////////////////////////////////////////////////////////// 2 // Scorched3D (c) 2000-2011 3 // 4 // This file is part of Scorched3D. 5 // 6 // Scorched3D is free software; you can redistribute it and/or modify 7 // it under the terms of the GNU General Public License as published by 8 // the Free Software Foundation; either version 2 of the License, or 9 // (at your option) any later version. 10 // 11 // Scorched3D is distributed in the hope that it will be useful, 12 // but WITHOUT ANY WARRANTY; without even the implied warranty of 13 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 14 // GNU General Public License for more details. 15 // 16 // You should have received a copy of the GNU General Public License along 17 // with this program; if not, write to the Free Software Foundation, Inc., 18 // 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA. 19 //////////////////////////////////////////////////////////////////////////////// 20 21 #if !defined(AFX_ShieldRound_H__F9BCDF39_FB62_4BB4_9D64_C70215669F9C__INCLUDED_) 22 #define AFX_ShieldRound_H__F9BCDF39_FB62_4BB4_9D64_C70215669F9C__INCLUDED_ 23 24 #include <weapons/Shield.h> 25 26 class ShieldRound : public Shield 27 { 28 public: 29 ShieldRound(); 30 virtual ~ShieldRound(); 31 32 virtual bool parseXML(AccessoryCreateContext &context, 33 XMLNode *accessoryNode); 34 35 // ShieldRound attributes getActualRadius()36 fixed getActualRadius() { return radius_; } getHalfShield()37 bool getHalfShield() { return halfShield_; } getGlow()38 bool getGlow() { return glow_; } 39 40 virtual bool inShield(FixedVector &offset); 41 virtual bool tankInShield(FixedVector &offset); 42 virtual ShieldType getShieldType(); getRound()43 virtual bool getRound() { return true; } getBoundingSize()44 virtual fixed getBoundingSize() { return radius_; } 45 46 REGISTER_ACCESSORY_HEADER(ShieldRound, AccessoryPart::AccessoryShield); 47 48 protected: 49 fixed radius_; 50 bool halfShield_; 51 bool glow_; 52 }; 53 54 #endif // !defined(AFX_ShieldRound_H__F9BCDF39_FB62_4BB4_9D64_C70215669F9C__INCLUDED_) 55