Hello I have no clue but windows defender is flagging my program but there is nothing in the code that should set it of. is there anyway to stop this? Could this be the turtle because it is making a screen? Or because of the random numbers?
import time
import random
import turtle
def click(x,y):
player.penup()
x = random.randint(-200, 200)
y = random.randint(-250, 200)
player.hideturtle()
player.setpos(int(x), int(y))
player.showturtle()
def stop():
exit()
# The Screen
Screen = turtle.Screen()
Screen.bgcolor('black')
Screen.setup(900,900)
Screen.title('Triangle Game')
# Border Line
bl = turtle.Turtle()
bl.color('white')
bl.speed(9000)
bl.penup()
bl.setposition(-250, -250)
bl.pendown()
for i in range(4):
bl.forward(500)
bl.left(90)
bl.hideturtle()
# Player Thing
player = turtle.Turtle()
player.shape('triangle')
player.color('white')
# click the player
player.onclick(click)
# Short Cut Keys
turtle.listen()
turtle.onkey(stop, 'e')
Screen.mainloop()
Yes, I faced similar issue and added below exception:
Go to Start > Settings > Update & Security > Windows Security > Virus & threat protection. Under Virus & threat protection settings, select Manage settings, and then under Exclusions, select Add or remove exclusions.
We can use virustotal website to analyse the possible cause.
Hope this helps.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With