Skip to content

Papa #203

@hafsaboudechicha2-ops

Description

@hafsaboudechicha2-ops

class Point:
def init(self, x=0.0, y=0.0):
self.x = x
self.y = y

class Settings:
class Particles:
def init(self):
self.effect = 0.05 # نفس فكرة settings.particles.effect

def __init__(self):
    self.particles = self.Particles()

settings = Settings()

class Particle:
def init(self):
self.position = Point()
self.velocity = Point()
self.acceleration = Point()
self.age = 0

def initialize(self, x, y, dx, dy):
    self.position.x = x
    self.position.y = y

    self.velocity.x = dx
    self.velocity.y = dy

    self.acceleration.x = dx * settings.particles.effect
    self.acceleration.y = dy * settings.particles.effect

    self.age = 0

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions