Discuss Scratch
- Discussion Forums
- » Help with Scripts
- » Help with AI for Super Smash Bros game
- Silenttaco99
-
58 posts
Help with AI for Super Smash Bros game
Hello I need help with creating AI for a super smash bros game. I just need a basic idea of what to start with. I don't want to create something simple because there are usually flaws that can be exploited and I want to reduce that by making it complex.
- -Scratchdotmit-
-
49 posts
Help with AI for Super Smash Bros game
Hello I need help with creating AI for a super smash bros game. I just need a basic idea of what to start with. I don't want to create something simple because there are usually flaws that can be exploited and I want to reduce that by making it complex.
So basically what exactly do you want it to do?? I don't play super smash bros
- Silenttaco99
-
58 posts
Help with AI for Super Smash Bros game
I want to add a mode where you fight a.i. before fighting a boss. Super smash bros is like any arcade fighter game except its more complex. I just want to make an AI that knows how to move back when your gonna attack for example and it attacks you when its close.
- -Scratchdotmit-
-
49 posts
Help with AI for Super Smash Bros game
I want to add a mode where you fight a.i. before fighting a boss. Super smash bros is like any arcade fighter game except its more complex. I just want to make an AI that knows how to move back when your gonna attack for example and it attacks you when its close.
That would be super hard because you know, the AI would knwo what to do and when. I guess you could do some stuff, like for example
when green flag clicked
forever
if <(distance to [ Player]) < [10]> then
switch costume to [ Punch]
end
end
(for the punch)
I guess I could help you on this project if you like

Last edited by -Scratchdotmit- (Sept. 10, 2020 01:44:37)
- Silenttaco99
-
58 posts
Help with AI for Super Smash Bros game
Ok thank you, maybe I can make a studio. I just need to fix many bugs in my game.
- Wyan100
-
1000+ posts
Help with AI for Super Smash Bros game
i would recommend looking up some Popular Scratch Smash games (such as this one) and seeing what they do, maybe you could find some inspiration.
- -Scratchdotmit-
-
49 posts
Help with AI for Super Smash Bros game
Simple Crouch
when green flag clicked
forever
if <key [ c (crouch key)] pressed?> then
if <(distance to [ Player]) < [10]> then
if <(pick random (1) to (2)) = [1]> then
switch costume to [ crouch]
else
end
end
end
end
- NANI_Studios
-
4 posts
Help with AI for Super Smash Bros game
This is how i learned to do the AI left and right movement
define (move speed)(friction)(gravity)(jump height)
if <(direction) > [0]> then
if <(distance to [ player]) > [50]> then
point towards [player ]
change [x vel] by (move speed)
end
end
if <(direction) < [0]> then
if <(distance to [ player]) > [50]> then
point towards [player ]
change [x vel] by (move speed)
end
end
change [x vel ] by ((x vel) * (friction))
change x by (x vel)
Last edited by NANI_Studios (Dec. 7, 2020 00:01:42)
- Discussion Forums
- » Help with Scripts
-
» Help with AI for Super Smash Bros game