Shield Effects [OpenGL]
-
- Posts: 91
- Joined: Sun Oct 19, 2008 5:29 pm
- Location: Valencia (Spain)
- Contact:
-
- Posts: 226
- Joined: Fri Aug 22, 2008 8:50 pm
- Contact:
I don't know if you wanted this but I did it anyway because frankly changing the site from what you chose is worth anything!!
MIRRORED ON MEDIAFIRE
removed - old version
MIRRORED ON MEDIAFIRE
removed - old version
Last edited by Midnight on Tue May 25, 2010 10:24 am, edited 1 time in total.
Shader compile error :
I've changed :
float intensity=1/pow(dist,2)*radius*0.01;
to :
float intensity=1/pow(dist,2.0)*radius*0.01;
It've worked perfect ! Thanks freetimecoder !
Code: Select all
0(1) : error C1115: unable to find compatible overloaded function "pow(float, int)"
float intensity=1/pow(dist,2)*radius*0.01;
to :
float intensity=1/pow(dist,2.0)*radius*0.01;
It've worked perfect ! Thanks freetimecoder !
There's something is fantastic, there's nothing is absolute.
-
- Posts: 226
- Joined: Fri Aug 22, 2008 8:50 pm
- Contact:
@trivtn: This is an old error, sorry forgot to edit the code in the first post.
@Midnight: You can upload it if you like, but you uploaded the older version.
I removed the old link in the first post now to prevent more confusion.
Sorry, I am a bit sloppy with version control in this thread
As soon as I finished including Viz_Fuerte's arb shader I will update all code and downloads to the newest version.
edit: done
greetings
@Midnight: You can upload it if you like, but you uploaded the older version.
I removed the old link in the first post now to prevent more confusion.
Sorry, I am a bit sloppy with version control in this thread
![Embarassed :oops:](./images/smilies/icon_redface.gif)
As soon as I finished including Viz_Fuerte's arb shader I will update all code and downloads to the newest version.
edit: done
greetings
-
- Posts: 91
- Joined: Sun Oct 19, 2008 5:29 pm
- Location: Valencia (Spain)
- Contact:
-
- Posts: 226
- Joined: Fri Aug 22, 2008 8:50 pm
- Contact:
This is certainly something that I'll be implementing as well.
The Open Descent Foundation is always looking for programmers! http://www.odf-online.org
"I'll find out if what I deleted was vital here shortly..." -d3jake
"I'll find out if what I deleted was vital here shortly..." -d3jake
hm, i got an error:
I looked at CShieldManager.cpp and can't find removeshield() where is it?
MfG
Scarabol
Code: Select all
error LNK2019: Verweis auf nicht aufgelöstes externes Symbol ""public: bool __thiscall CShieldManager::removeShield(class irr::scene::ISceneNode *)" (?removeShield@CShieldManager@@QAE_NPAVISceneNode@scene@irr@@@Z)" in Funktion ""public: __thiscall star::spaceobject::~spaceobject(void)" (??1spaceobject@star@@QAE@XZ)".
MfG
Scarabol
Irrlicht 1.7.2
Eclipse
Boost
Eclipse
Boost
-
- Posts: 226
- Joined: Fri Aug 22, 2008 8:50 pm
- Contact:
Uhm must have forgotten it ![Embarassed :oops:](./images/smilies/icon_redface.gif)
Add that to the CShieldManager.cpp:
greetings
![Embarassed :oops:](./images/smilies/icon_redface.gif)
Add that to the CShieldManager.cpp:
Code: Select all
bool CShieldManager::removeShield(scene::ISceneNode *node){
//Check if shield exists
for(u32 i=0; i<array_Shields.size();i++){
if(array_Shields[i].shieldNode == node){
//Erase all impacts of the shield
while(!array_Shields[i].array_Impacts.empty()){
array_Shields[i].array_Impacts.erase(0);
}
array_Shields.erase(i);
return true;
}
}
return false;
}
Hi,
did you check your program with another video driver?
Im using Directx9 and i cant see any shield.
Is this line ok? I think it should work with DirectX too, because off arb shader?
What is the difference between Local- Global- und AddImpact?
MfG
Scarabol
did you check your program with another video driver?
Im using Directx9 and i cant see any shield.
Is this line ok? I think it should work with DirectX too, because off arb shader?
Edit://Witout OpenGL these shaders won't work
if(!(driver->getDriverType()==video::EDT_OPENGL))
return;
What is the difference between Local- Global- und AddImpact?
MfG
Scarabol
Irrlicht 1.7.2
Eclipse
Boost
Eclipse
Boost