the problem im having is that i cant get the players to change to load
a particular datablock.
for example:
i have a 4 different datablocks for crossbow projectiles.
and i noticed in crossbowimage::onFire(...) there are calls to the
projectile datablock
at the top it looks i modified:
function CrossbowImage::onFire(%this, %obj, %slot)
{
//%projectile = %this.projectile //original
switch$(%this.playerClass.playerClassId)
{
case 1:
%projectile = CrossbowProjectileStrength; //modified
projectile datablock
case 2:
%projectile = CrossbowProjectileAccuracy; //modified
}
....//more code
}
I guess the problem is that there is no "this" associated with the
modified datablocks.
My question is how can i get this to work the way i want to?
Or this:
%obj.getDatablock().playerClass.playerClassId
Inside the Image::onFire method, %this is the Image Datablock and
%obj, if I recall correctly, the player it is mounted to. Remember,
that's Player, not PlayerData. If you need something from PlayerData
you call getDatablock.
Hope that helps.
~Zeus