The Daily Click ::. Forums ::. Klik Coding Help ::. IS THERE A WAY?
 

Post Reply  Post Oekaki 
 

Posted By Message

KevinHaag



Registered
  28/01/2005
Points
  266

VIP Member
13th April, 2005 at 20:02:38 -

Is there a way in TGF to make a gun follow the mouse pointer and go in a 360 degree circle, so that the gun is always facing the mouse pointer but stays in the same place? I also want it not to look jumpy

 
Image
http://www.kevinhaag.ca

Radix

hot for teacher

Registered
  01/10/2003
Points
  3139

Has Donated, Thank You!VIP MemberGOTW WINNER CUP 1!GOTW WINNER CUP 2!GOTW WINNER CUP 3!GOTW WINNER CUP 4!
13th April, 2005 at 20:06:02 -

Urr, yeah. It's easy. Just make sure your hotspot is in the right place at each angle.

 
n/a

ChrisB

Crazy?

Registered
  16/08/2002
Points
  5457
13th April, 2005 at 20:34:25 -

There is a way, as long as you have a will

 
n/a

The Chris Street

Administrator
Unspeakably Lazy Admin

Registered
  14/05/2002
Points
  48488

Game of the Week WinnerClickzine StaffAcoders MemberKlikCast StarVIP MemberPicture Me This Round 35 Winner!Second GOTW AwardYou've Been Circy'd!Picture Me This Round 38 Winner!GOTM December Third Place!!
I am an April FoolKliktober Special Award Tag
14th April, 2005 at 15:47:04 -

TGF doesnt have an Active Picture Object, does it? Otherwise that would allow smooth rotation towards the mouse.

 
n/a

Phredreeke

Don't listen to this idiot

Registered
  03/08/2002
Points
  4504

You've Been Circy'd!VIP MemberPS3 Owner
14th April, 2005 at 16:25:03 -

hmmm... make a support object, set that object's X position to XMouse and Y position to YMouse, then make the gun object look in direction of the support object.

 
- Ok, you must admit that was the most creative cussing this site have ever seen -

Make some more box arts damnit!
http://create-games.com/forum_post.asp?id=285363

The Chris Street

Administrator
Unspeakably Lazy Admin

Registered
  14/05/2002
Points
  48488

Game of the Week WinnerClickzine StaffAcoders MemberKlikCast StarVIP MemberPicture Me This Round 35 Winner!Second GOTW AwardYou've Been Circy'd!Picture Me This Round 38 Winner!GOTM December Third Place!!
I am an April FoolKliktober Special Award Tag
14th April, 2005 at 16:55:33 -

That basic way only does 32 directions though. A bit of trigonometry is in order:

http://www.create-games.com/article.asp?id=1322



 
n/a
   

Post Reply



 



Advertisement

Worth A Click