Be a Supporter!

As3 Ai Starting Help

  • 121 Views
  • 2 Replies
New Topic Respond to this Topic
Dupre
Dupre
  • Member since: Oct. 3, 2002
  • Offline.
Forum Stats
Member
Level 02
Blank Slate
As3 Ai Starting Help 2014-03-28 15:59:36 Reply

So I'm creating a "bullet hell" game (not sure the actual name of them honestly, unless that's it) and I've got two MVCs, one for the player and one for the boss. Currently I have the boss only moving side to side, and there is only the one boss for now. What I want it to do is shoot a projectile based on it's X movement, but I'm honestly drawing a blank.

I'm doing all of this using Sprites not MovieClips, and I've created a separate .as file for the projectiles. With everything else I've written so far this would probably be one of the easiest, but I'm having a coders case of writer's block.

Etherblood
Etherblood
  • Member since: Apr. 14, 2013
  • Offline.
Forum Stats
Member
Level 12
Game Developer
Response to As3 Ai Starting Help 2014-03-29 09:59:17 Reply

At 3/28/14 03:59 PM, Dupre wrote: What I want it to do is shoot a projectile based on it's X movement, but I'm honestly drawing a blank.

Im not exactly sure I understand your problem. You want to use the bosses speed in x direction to adjust your projectiles?
Like setting the projectile speedX to the bosses speedX?

GeoKureli
GeoKureli
  • Member since: Apr. 1, 2003
  • Offline.
Forum Stats
Supporter
Level 19
Game Developer
Response to As3 Ai Starting Help 2014-03-29 13:23:09 Reply

At 3/29/14 09:59 AM, Etherblood wrote:
At 3/28/14 03:59 PM, Dupre wrote: What I want it to do is shoot a projectile based on it's X movement, but I'm honestly drawing a blank.
Im not exactly sure I understand your problem. You want to use the bosses speed in x direction to adjust your projectiles?
Like setting the projectile speedX to the bosses speedX?

Yeah, I'm not understanding either. Do you want the boss to shoot towards the player X, like an angled shot? or do you want to take the boss's speed and add it to the bullets he shoots?