X-Git-Url: https://git.jsancho.org/?a=blobdiff_plain;f=Source%2FWeapons.cpp;h=2f6a1ffd65106ed999e25df90608104433b89347;hb=9e06cb73424ca3f0eb971350c5dfb3cdaec0d5bf;hp=f6cf200fe8d5ef519b3d0222bb62796c292eea38;hpb=46cff1de1e828cb8c04a5dc5377bc07baae57858;p=lugaru.git diff --git a/Source/Weapons.cpp b/Source/Weapons.cpp index f6cf200..2f6a1ff 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