created / added resources (sounds, sprites, ...)
This commit is contained in:
parent
fa1a095cde
commit
2239dd0828
Binary file not shown.
After Width: | Height: | Size: 5.8 KiB |
|
@ -0,0 +1,115 @@
|
|||
<?xml version="1.0" encoding="UTF-8" standalone="no"?>
|
||||
<!-- Created with Inkscape (http://www.inkscape.org/) -->
|
||||
|
||||
<svg
|
||||
xmlns:dc="http://purl.org/dc/elements/1.1/"
|
||||
xmlns:cc="http://creativecommons.org/ns#"
|
||||
xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#"
|
||||
xmlns:svg="http://www.w3.org/2000/svg"
|
||||
xmlns="http://www.w3.org/2000/svg"
|
||||
xmlns:sodipodi="http://sodipodi.sourceforge.net/DTD/sodipodi-0.dtd"
|
||||
xmlns:inkscape="http://www.inkscape.org/namespaces/inkscape"
|
||||
width="210mm"
|
||||
height="297mm"
|
||||
viewBox="0 0 210 297"
|
||||
version="1.1"
|
||||
id="svg8"
|
||||
inkscape:version="0.92.2 2405546, 2018-03-11"
|
||||
sodipodi:docname="crosshair.svg">
|
||||
<defs
|
||||
id="defs2" />
|
||||
<sodipodi:namedview
|
||||
id="base"
|
||||
pagecolor="#ffffff"
|
||||
bordercolor="#666666"
|
||||
borderopacity="1.0"
|
||||
inkscape:pageopacity="0.0"
|
||||
inkscape:pageshadow="2"
|
||||
inkscape:zoom="3.959798"
|
||||
inkscape:cx="216.55066"
|
||||
inkscape:cy="679.99479"
|
||||
inkscape:document-units="mm"
|
||||
inkscape:current-layer="layer1"
|
||||
showgrid="false"
|
||||
showguides="true"
|
||||
inkscape:guide-bbox="true"
|
||||
inkscape:window-width="3840"
|
||||
inkscape:window-height="2047"
|
||||
inkscape:window-x="0"
|
||||
inkscape:window-y="57"
|
||||
inkscape:window-maximized="1">
|
||||
<sodipodi:guide
|
||||
position="59.247767,182.70425"
|
||||
orientation="0,1"
|
||||
id="guide4522"
|
||||
inkscape:locked="false" />
|
||||
<sodipodi:guide
|
||||
position="72.807662,188.42114"
|
||||
orientation="1,0"
|
||||
id="guide4524"
|
||||
inkscape:locked="false" />
|
||||
<sodipodi:guide
|
||||
position="72.80766,225.2414"
|
||||
orientation="0,1"
|
||||
id="guide4541"
|
||||
inkscape:locked="false" />
|
||||
<sodipodi:guide
|
||||
position="72.80766,140.24969"
|
||||
orientation="0,1"
|
||||
id="guide4543"
|
||||
inkscape:locked="false" />
|
||||
<sodipodi:guide
|
||||
position="115.3268,167.77845"
|
||||
orientation="1,0"
|
||||
id="guide4545"
|
||||
inkscape:locked="false" />
|
||||
<sodipodi:guide
|
||||
position="30.268273,177.33334"
|
||||
orientation="1,0"
|
||||
id="guide4547"
|
||||
inkscape:locked="false" />
|
||||
</sodipodi:namedview>
|
||||
<metadata
|
||||
id="metadata5">
|
||||
<rdf:RDF>
|
||||
<cc:Work
|
||||
rdf:about="">
|
||||
<dc:format>image/svg+xml</dc:format>
|
||||
<dc:type
|
||||
rdf:resource="http://purl.org/dc/dcmitype/StillImage" />
|
||||
<dc:title></dc:title>
|
||||
</cc:Work>
|
||||
</rdf:RDF>
|
||||
</metadata>
|
||||
<g
|
||||
inkscape:label="Ebene 1"
|
||||
inkscape:groupmode="layer"
|
||||
id="layer1">
|
||||
<circle
|
||||
style="fill:none;fill-opacity:1;stroke:#000000;stroke-width:1.25;stroke-miterlimit:4;stroke-dasharray:none;stroke-dashoffset:0;stroke-opacity:1"
|
||||
id="path4520"
|
||||
cx="72.831284"
|
||||
cy="114.36663"
|
||||
r="34.041481" />
|
||||
<path
|
||||
style="fill:none;stroke:#000000;stroke-width:0.75;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1;stroke-miterlimit:4;stroke-dasharray:none"
|
||||
d="m 72.80766,71.7586 v 36.82026"
|
||||
id="path4549"
|
||||
inkscape:connector-curvature="0" />
|
||||
<path
|
||||
style="fill:none;stroke:#000000;stroke-width:0.75;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1;stroke-miterlimit:4;stroke-dasharray:none"
|
||||
d="M 115.3268,114.29575 H 79.111778"
|
||||
id="path4551"
|
||||
inkscape:connector-curvature="0" />
|
||||
<path
|
||||
style="fill:none;stroke:#000000;stroke-width:0.75;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1;stroke-miterlimit:4;stroke-dasharray:none"
|
||||
d="M 72.80766,156.75031 V 114.29575"
|
||||
id="path4553"
|
||||
inkscape:connector-curvature="0" />
|
||||
<path
|
||||
style="fill:none;stroke:#000000;stroke-width:0.75;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1;stroke-miterlimit:4;stroke-dasharray:none"
|
||||
d="M 30.268272,114.29575 H 66.015573"
|
||||
id="path4555"
|
||||
inkscape:connector-curvature="0" />
|
||||
</g>
|
||||
</svg>
|
After Width: | Height: | Size: 3.8 KiB |
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
After Width: | Height: | Size: 36 KiB |
|
@ -27,7 +27,11 @@ FireUnit::FireUnit()
|
|||
jet->addAnimator(a);
|
||||
a->drop();
|
||||
|
||||
crosshair = Globals::getVideoDriver()->getTexture("../res/crosshair.png");
|
||||
|
||||
auto b = Globals::getSceneManager()->addBillboardSceneNode(turretElevation, dimension2df(1.f, 1.f), vector3df(.14f, 1.5f, 1.89f));
|
||||
b->setMaterialTexture(0, Globals::getVideoDriver()->getTexture("../res/mflash.png"));
|
||||
b->setMaterialType(video::EMT_TRANSPARENT_ALPHA_CHANNEL_REF);
|
||||
}
|
||||
|
||||
FireUnit::~FireUnit()
|
||||
|
@ -96,3 +100,11 @@ bool FireUnit::OnEvent(const SEvent& e)
|
|||
|
||||
return false;
|
||||
}
|
||||
|
||||
|
||||
void FireUnit::draw()
|
||||
{
|
||||
auto& res = Globals::getVideoDriver()->getScreenSize();
|
||||
|
||||
Globals::getVideoDriver()->draw2DImage(crosshair, position2di(res.Width / 2 - 128, res.Height / 2 - 128), recti(0, 0, 256, 256), nullptr, video::SColor(255,255,255,255), true );
|
||||
}
|
||||
|
|
|
@ -10,11 +10,13 @@ public:
|
|||
~FireUnit();
|
||||
|
||||
bool OnEvent(const irr::SEvent&);
|
||||
void draw();
|
||||
|
||||
private:
|
||||
irr::scene::ICameraSceneNode *cam;
|
||||
irr::scene::ISceneNode *turretElevation, *turretAzimuth;
|
||||
irr::scene::ISceneNodeAnimator *turretCamAnimator;
|
||||
irr::video::ITexture *crosshair;
|
||||
};
|
||||
|
||||
#endif // FIREUNIT_HPP
|
||||
|
|
|
@ -49,6 +49,7 @@ void FlaSimApp::execute()
|
|||
drv->beginScene(true, true, SColor(255, 128, 128, 128));
|
||||
sman->drawAll();
|
||||
drawScreenSpace();
|
||||
fireUnit.draw();
|
||||
drv->endScene();
|
||||
}
|
||||
}
|
||||
|
|
|
@ -25,7 +25,7 @@ void TurretCamAnimator::animateNode(scene::ISceneNode* node, u32)
|
|||
absTrans.rotateVect(nodeUpVector, core::vector3df(0.f, 1.f, 0.f));
|
||||
absTrans.transformVect(nodeTarget, core::vector3df(0.f, 0.f, 100.f));
|
||||
|
||||
node->setPosition(parent->getAbsolutePosition() + core::vector3df(0.f, 1.65f, 0.f));
|
||||
node->setPosition(parent->getAbsolutePosition() + core::vector3df(0.f, 1.75f, 0.f));
|
||||
if (node->getType() == scene::ESNT_CAMERA)
|
||||
{
|
||||
static_cast<scene::ICameraSceneNode*>(node)->setUpVector(nodeUpVector);
|
||||
|
|
Loading…
Reference in New Issue