Panda3D
Loading...
Searching...
No Matches
pointParticle.cxx
Go to the documentation of this file.
1/**
2 * PANDA 3D SOFTWARE
3 * Copyright (c) Carnegie Mellon University. All rights reserved.
4 *
5 * All use of this software is subject to the terms of the revised BSD
6 * license. You should have received a copy of this license along
7 * with this source code in a file named "LICENSE."
8 *
9 * @file pointParticle.cxx
10 * @author charles
11 * @date 2000-06-19
12 */
13
14#include "pointParticle.h"
15
16/**
17 * simple constructor
18 */
20PointParticle(PN_stdfloat lifespan, bool alive) :
21 BaseParticle(lifespan, alive) {
22 set_oriented(false);
23}
24
25/**
26 * copy constructor
27 */
29PointParticle(const PointParticle &copy) :
30 BaseParticle(copy) {
31 set_oriented(false);
32}
33
34/**
35 * simple destructor
36 */
40
41/**
42 * dynamic copier
43 */
45make_copy() const {
46 return new PointParticle(*this);
47}
48
49/**
50 * particle death routine
51 */
53die() {
54}
55
56/**
57 * particle init routine
58 */
60init() {
61}
62
63/**
64 * particle update
65 */
67update() {
68}
69
70/**
71 * Write a string representation of this instance to <out>.
72 */
74output(std::ostream &out) const {
75 #ifndef NDEBUG //[
76 out<<"PointParticle";
77 #endif //] NDEBUG
78}
79
80/**
81 * Write a string representation of this instance to <out>.
82 */
84write(std::ostream &out, int indent) const {
85 #ifndef NDEBUG //[
86 out.width(indent); out<<""; out<<"PointParticle:\n";
88 #endif //] NDEBUG
89}
An individual, physically-modelable particle abstract base class.
virtual void write(std::ostream &out, int indent=0) const
Write a string representation of this instance to <out>.
A body on which physics will be applied.
set_oriented
Set flag to determine whether this object should do any rotation or orientation calculations.
Describes a particle that requires representation by a point (pixel, sparkle, billboard)
virtual void die()
particle death routine
virtual PhysicsObject * make_copy() const
dynamic copier
virtual void write(std::ostream &out, int indent=0) const
Write a string representation of this instance to <out>.
virtual void output(std::ostream &out) const
Write a string representation of this instance to <out>.
virtual void init()
particle init routine
virtual void update()
particle update
virtual ~PointParticle()
simple destructor
PointParticle(PN_stdfloat lifespan=0.0f, bool alive=false)
simple constructor
std::ostream & indent(std::ostream &out, int indent_level)
A handy function for doing text formatting.
Definition indent.cxx:20
PANDA 3D SOFTWARE Copyright (c) Carnegie Mellon University.