Datablock inheritence
by gamer · in Torque Game Engine · 10/13/2006 (6:09 pm) · 3 replies
I have
datablock ProjectileData (pchild:pParent){
}
function pParent::onCollision(%this,%obj,%col,%fade,%pos,%normal){
}
it doesn't seem to work in the sense that pParent::onCollission is not called when the pchild projectile gets fired onto something. the function does get called pParent projectile gets fired onto something work of course.
does datablock inheritence only copies data over and serves no other purpose?
thanks
datablock ProjectileData (pchild:pParent){
}
function pParent::onCollision(%this,%obj,%col,%fade,%pos,%normal){
}
it doesn't seem to work in the sense that pParent::onCollission is not called when the pchild projectile gets fired onto something. the function does get called pParent projectile gets fired onto something work of course.
does datablock inheritence only copies data over and serves no other purpose?
thanks
About the author
#2
whats the difference with my code and yours, my code:
datablock ProjectileData(pchild::pParent)
your code:
datablock Projectiledata(pchild:pparent)
notice the "::" with myn and yours has ":"
10/15/2006 (4:12 am)
Something wrong with your code see the datablock ProjectileData (pchild:pParent)whats the difference with my code and yours, my code:
datablock ProjectileData(pchild::pParent)
your code:
datablock Projectiledata(pchild:pparent)
notice the "::" with myn and yours has ":"
#3
yes, sorry that was a typo in the post, but I had datablock ProjectileData (pchild::pParent) in my actual code. Thanks!
10/15/2006 (1:06 pm)
Saska,yes, sorry that was a typo in the post, but I had datablock ProjectileData (pchild::pParent) in my actual code. Thanks!
Torque Owner J "hplus" W