⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 perfectparticledlg.h

📁 这是一款游戏中的粒子系统
💻 H
字号:
// PerfectParticleDlg.h : 头文件
//

#pragma once
#define  M_RENDER WM_USER+1
#include "Camera.h"
#include "InitEnviroment.h"
#include "BaseHeader.h"
#include "ParticleSystem.h"
#include "ParticleEmitter.h"
#include "resource.h"
#include "AxisForceLogic.h"
#include "BoxCreator.h"
#include "CenterForceLogic.h"
#include "afxwin.h"
#include "afxcmn.h"

#include "CreateCenterForce.h"
#include "CreateAxisForce.h"
#include "CreateBoxCreator.h"
#include "DownData.h"
#include "ParticleAffector.h"
#include "PreInfo.h"
#include "TestParticleSystem.h"
//设置调试窗口
class CPerfectParticleDlg : public CDialog
{
public:
	CPerfectParticleDlg(CWnd* pParent = NULL);	// 标准构造函数
	enum { IDD = IDD_PERFECTPARTICLE_DIALOG };
protected:
	virtual void DoDataExchange(CDataExchange* pDX);	// DDX/DDV 支持
protected:
	HICON m_hIcon;
    LRESULT Render(WPARAM w,LPARAM l);
	virtual BOOL OnInitDialog();
	afx_msg void OnPaint();
	afx_msg HCURSOR OnQueryDragIcon();
	DECLARE_MESSAGE_MAP()
public:
	afx_msg void OnDestroy();
public:
	CRect            m_renderRect;
	CWinThread       *m_renderThread;
	CInitEnviroment  *m_device;
	CCamera          *m_camera;
	CParticleSystem  *m_sys;
	CParticleEmitter *m_emitter;
	CParticleAffector *m_affect;
	afx_msg void OnBnClickedButton1();
	afx_msg void OnCbnSelchangeCombox();

public:
	CString path;
	void ControlToParameter();
	void ParameterToControl();
public:
	CSliderCtrl m_PS;
	CSliderCtrl m_LifeBase;
	CSliderCtrl m_LifeVar;
	CSliderCtrl m_SizeBase;
	CSliderCtrl m_SizeVar;
	CSliderCtrl m_PosX;
	CSliderCtrl m_PosY;
	CSliderCtrl m_PosZ;
	CSliderCtrl m_ABase;
	CSliderCtrl m_AVar;
	CSliderCtrl m_RBase;
	CSliderCtrl m_RVar;
	CSliderCtrl m_GBase;
	CSliderCtrl m_GVar;
	CSliderCtrl m_BBase;
	CSliderCtrl m_BVar;
	CSliderCtrl m_DirXBase;
	CSliderCtrl m_DirXVar;
	CSliderCtrl m_DirYBase;
	CSliderCtrl m_DirYVar;
	CSliderCtrl m_DirZBase;
	CSliderCtrl m_DirZVar;

	CComboBox   m_comBox;
	afx_msg void OnCenterForce();
	afx_msg void OnAxisForce();
	afx_msg void OnCreatepos();

public:
	//向心力影响子
	struct CenterForce{
		float force;
		float nr;
		float fr;
		float cut;
	};
	CList<CenterForce,CenterForce> m_forceParam;

	//轴向力影响子
	CList<D3DXVECTOR3,D3DXVECTOR3> m_vecList;

	//发射区域影响子
	struct BoxForce{
		D3DXVECTOR3 one;
		D3DXVECTOR3 two;
	};
	CList<BoxForce,BoxForce> m_box;

public:
	CCreateCenterForce *m_centerForce;
	CCreateAxisForce   *m_axisForce;
	CCreateBoxCreator  *m_boxCreator;
	CSliderCtrl m_Speed;
	afx_msg void OnExportConfig();
	void ResetAffector();
public:
	bool  m_IsChange;
	afx_msg void OnBnClickedCreate();
	afx_msg void OnBnClickedDelete();
};

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -