The Daily Click ::. Forums ::. Klik Coding Help ::. top view enemy eyes
 

Post Reply  Post Oekaki 
 

Posted By Message

Willy C



Registered
  14/02/2004
Points
  1524

Game of the Week WinnerKlikCast StarPicture Me This -Round8- Winner!VIP MemberWii OwnerIt's-a me, Mario!Hero of TimeThe Cake is a LiePS3 OwnerI am an April Fool
Batman!Teddy Bear
30th May, 2004 at 07:16:20 -

I want to make enemies shoot out triggers that they use to see with. But I dont want them to be shoot out in a straight line. I want them to see wider, I want them to shoot out random directions in that direction they are allready facing. I tried this i mmf: "enemy" shoot in selected directions (and make a special code thingy that "1+1" thing) rethrive data from object - get direction value + random (5) (looks like this: Dir( "Group.Bad" ) + random (5)). and I press ok then the "1+1" code thingy is erased leaving me with the code: shoot in selected directions. what should I do?

 
http://www.robocaptain.com

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!
30th May, 2004 at 07:47:00 -

Rather than shooting, try creating the 'eyes' as a ball object moving at speed 100, and set it's direction to the enemy's + rnd( 8 ) - 4.

Image Edited by the Author.

 
n/a

Willy C



Registered
  14/02/2004
Points
  1524

Game of the Week WinnerKlikCast StarPicture Me This -Round8- Winner!VIP MemberWii OwnerIt's-a me, Mario!Hero of TimeThe Cake is a LiePS3 OwnerI am an April Fool
Batman!Teddy Bear
30th May, 2004 at 07:56:21 -

That works if I have only one enemy, but when there is multiple the enemy shoots out triggers in many directions.

 
http://www.robocaptain.com

Willy C



Registered
  14/02/2004
Points
  1524

Game of the Week WinnerKlikCast StarPicture Me This -Round8- Winner!VIP MemberWii OwnerIt's-a me, Mario!Hero of TimeThe Cake is a LiePS3 OwnerI am an April Fool
Batman!Teddy Bear
30th May, 2004 at 10:23:09 -

well that doesnt work at all, phizzy. the "only one action when event loops" event, makes it create only one bouncing ball from the enemy. Really I want to know how I do this, anyone?

 
http://www.robocaptain.com

Saven (CrobaSoft)



Registered
  12/03/2004
Points
  587
30th May, 2004 at 16:25:39 -

/Always
-active 1 shoot "detector 1" at speed 100

/detector 1: internal flag 0 is off
Set direction to dir("detector 1")+Random(3)-1
Set flag 0 to on

Image Edited by the Author.

 
You shouldn't go here, there are crazy swedes who mumble about cucumbers:
http://www.crobasoft.com

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!
30th May, 2004 at 22:15:13 -

If there are multiple enemies, my favoutie method for this sort of thing is to give each enemy an identifier value in a variable, which can be a random number, or to be absolutely foolproof, it's starting X * 1000 + starting y. Then, when you create the eyes, set it an alterable value with the same ID number as the enemy who created it. Then you can test eyes value A = enemy value A in each event to set the object focus correctly.

 
n/a

Willy C



Registered
  14/02/2004
Points
  1524

Game of the Week WinnerKlikCast StarPicture Me This -Round8- Winner!VIP MemberWii OwnerIt's-a me, Mario!Hero of TimeThe Cake is a LiePS3 OwnerI am an April Fool
Batman!Teddy Bear
31st May, 2004 at 05:31:12 -

Yes, That was an idea I was going to do, becouse when only one enemy sees something mysterious I want him to go and check it out, not the entire platoon. I was not quite sure how to, but setting the x and y position at the start of level is pretty smart. And saven, thanks it works

 
http://www.robocaptain.com
   

Post Reply



 



Advertisement

Worth A Click