X-Git-Url: https://git.jsancho.org/?a=blobdiff_plain;f=Source%2FWeapons.cpp;h=4d8f32ec7cddf536780d416e701cdadd3df2986d;hb=12421cc17c6176a16ec18901e02d760ccd0b28ad;hp=f6cf200fe8d5ef519b3d0222bb62796c292eea38;hpb=2f6f7fe7b9562156a966b6cfd62afb2dc69734f7;p=lugaru.git diff --git a/Source/Weapons.cpp b/Source/Weapons.cpp index f6cf200..4d8f32e 100644 --- a/Source/Weapons.cpp +++ b/Source/Weapons.cpp @@ -159,11 +159,11 @@ void Weapon::DoStuff(int i) { int k=terrain.patchobjects[whichpatchx][whichpatchz][j]; start=oldtippoint; end=tippoint; - whichhit=objects.model[k].LineCheck(&start,&end,&colpoint,&objects.position[k],&objects.rotation[k]); + whichhit=objects.model[k].LineCheck(&start,&end,&colpoint,&objects.position[k],&objects.yaw[k]); if(whichhit!=-1) { if(objects.type[k]==treetrunktype){ - objects.model[k].MakeDecal(breakdecal,DoRotation(colpoint-objects.position[k],0,-objects.rotation[k],0),.1,1,Random()%360); - normalrot=DoRotation(objects.model[k].facenormals[whichhit],0,objects.rotation[k],0); + objects.model[k].MakeDecal(breakdecal,DoRotation(colpoint-objects.position[k],0,-objects.yaw[k],0),.1,1,Random()%360); + normalrot=DoRotation(objects.model[k].facenormals[whichhit],0,objects.yaw[k],0); velocity=0; if(type==knife) position=colpoint-normalrot*.1; @@ -214,7 +214,7 @@ void Weapon::DoStuff(int i) { if(velocity.x||velocity.y||velocity.z) { for(int j=0;j