javascript - How do I make bullets trajectory not be slowed down when I move the player? -
//the bullet appears @ right position slowed down when player move. please me make this:
theweapon.x -= 10; theweapon.style.left = (688 - bulletincrement - (playerhorizontal - shootedsince)) + "px";
//work this:
for(i = 0; < nodechild.length; ++i) { if(theplayername != nodechild[i].id) { mychildpropertie = nodechild[i].style.left; mychildpropertie = parseint(mychildpropertie.substring(0,(mychildpropertie.length - 2))); mychildpropertie += -15; if(nodechild[i].playerpart != 'yup'){ nodechild[i].style.left = mychildpropertie + "px"; } } }
Comments
Post a Comment