我希望我的图像在到达某一点时能够顺利转动。但我不知道你有多希望能提供帮助?我试图在css中编码这个只是因为我不知道javascript和ajax那么好
//image
div {
width: 100px;
height: 100px;
background: red;
position: relative;
//attrib
-webkit-animation-name: Player1;
-webkit-animation-duration: 5s;
-webkit-animation-timing-function: ease-in;
-webkit-animation-delay: 2s;
-webkit-animation-iteration-count: 5;
-webkit-animation-direction: normal;
-webkit-animation-play-state: running;
}
//path
@-webkit-keyframes Player1 {
0% {background:red; left:0px; top:0px;}
25% {background:yellow; left:200px; top:0px;}
50% {background:blue; left:200px; top:200px;}
75% {background:green; left:0px; top:200px;}
100% {background:red; left:0px; top:0px;}
}
如果它是汽车的图像,我该如何让它面向它正在行进的路径?