|
fixed point help |
chaseC
Member #8,368
February 2007
|
Hi, I am trying to use rotate sprite and when I just do something like rotate_sprite(buffer, image, 0, 0, itofix(angle); it works fine, but if I try to make it rotate int the direction of the mouse like thisint angle = atan2(int(mouse_y), int(mouse_x)); it gives me the error error: conversion from `int' to non-scalar type `fix' requested Can someone help? |
gnolam
Member #2,030
March 2002
|
1) atan2() returns radians, so an integer wouldn't have been of much use anyway. [EDIT] -- |
chaseC
Member #8,368
February 2007
|
Oh yeah, I forgot the 128/&pi but it works now Thanks:) |
|