#pragma once
#include "Entity.h"
#define PESPARK_CREATENAME L"pe_spark"
//颗粒实体：火花
class PeSpark :
    public Entity
{
public:
    PeSpark();
    void Step() override;
    void DeltaTime(float deltaTime) override;//绘制更新
    float angle;
    float length;
    float lenstart;
    float r = 0;
    void SetShape();
    std::vector<PenVertex> lineList_set;
    std::vector<PenVertex> lineList_set_last;
};

std::shared_ptr<Entity> CreatePeSpark();

//产生一些火花效果
void SetPeSpark(std::shared_ptr<Entity> parent, float x, float y, int nMin, int nMax, float angle);
void SetPeSparkSmall(std::shared_ptr<Entity> parent, float x, float y, int nMin, int nMax, float angle);