A Flash Developer Resource Site

Results 1 to 8 of 8

Thread: Script help in my game

Hybrid View

  1. #1
    Junior Member
    Join Date
    Jan 2005
    Posts
    13

    Script help in my game

    Okay i used brets beercatch and another little shooter example i found on here to im trying to make clones of the orcs taht follow the cross bow/ when shot turn in to a red dot that fades away after a while. im uploading the graphics and game
    Attached Files Attached Files

  2. #2
    Game Master ConnELITE's Avatar
    Join Date
    Apr 2005
    Location
    United States, DC
    Posts
    474
    yeh so whats your question? please be specific.
    BC

  3. #3
    Senior Member
    Join Date
    Feb 2005
    Posts
    177

    not sure what your asking

    not sure what your asking but it seems to me that you used the examples and put them together. Then you created new objects with names of your choice, but for the coding from the examples, you need to change the coding with the appropriate elements names you made.

  4. #4
    Junior Member
    Join Date
    Jan 2005
    Posts
    13

    Sorry i was tired

    My question is how should i code the orc so they follow the "hero" and die when shot by a bolt and i tried for hours to get the bolt to leave the cross bow on time but it never worked.

  5. #5
    Game Master ConnELITE's Avatar
    Join Date
    Apr 2005
    Location
    United States, DC
    Posts
    474
    to make em follow run a script every frame saying...
    if (hero.x<badguy.x){
    badguy.x+=1
    }
    if (hero.x>badguy.x){
    badguy.x-=1
    }
    if (hero.y<badguy.y){
    badguy.y+=1
    }
    if (hero.y>badguy.y){
    badguy.y-=1
    }
    if (hero.x==badguy.x){
    badguy.x=hero.x
    }
    if (hero.y==badguy.y){
    badguy.y=hero.y
    }
    BC

  6. #6
    Game Master ConnELITE's Avatar
    Join Date
    Apr 2005
    Location
    United States, DC
    Posts
    474
    for the dieing just say if bolt.collideRect(badguy){ badguy.hide()}

    if its clones I suggest looking at lopezes clone movie for examples on how clone collisions are detected.
    BC

  7. #7
    MSPaint Master
    Join Date
    Dec 2005
    Location
    Texas
    Posts
    71
    I really have to tell you somethin Conn, you have helped me and alot of other people in there game making, and I give thanks to all your help=)


    Ce-Bro Productions, an online game making a web comic community

    Ce-Bro.com

  8. #8
    Game Master ConnELITE's Avatar
    Join Date
    Apr 2005
    Location
    United States, DC
    Posts
    474
    urwelcome, its great to hear stuff like that. I have to say it was blanius and forumnewbie who helped me a lot and since blanius is gone I'm actually trying to become a moderator. Anyways I hope to release a huge amount of tutorials in awhile, unfourtunatly the other flash people have droped out for the site I'm working for so I'm forced to put in more time. I'll try to get something out soon though.
    BC

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  




Click Here to Expand Forum to Full Width

HTML5 Development Center