mirror of
https://github.com/ZDoom/qzdoom.git
synced 2024-11-28 15:02:01 +00:00
Fixed initialization of BlockThingsIterator objects
https://forum.zdoom.org/viewtopic.php?t=58945
This commit is contained in:
parent
2c4eae7487
commit
be8147406e
1 changed files with 5 additions and 4 deletions
|
@ -1275,20 +1275,21 @@ void FMultiBlockThingsIterator::Reset()
|
|||
//
|
||||
//===========================================================================
|
||||
|
||||
class DBlockThingsIterator : public DObject, public FMultiBlockThingsIterator
|
||||
class DBlockThingsIterator : public DObject
|
||||
{
|
||||
DECLARE_ABSTRACT_CLASS(DBlockThingsIterator, DObject);
|
||||
FPortalGroupArray check;
|
||||
FMultiBlockThingsIterator iterator;
|
||||
public:
|
||||
FMultiBlockThingsIterator::CheckResult cres;
|
||||
|
||||
bool Next()
|
||||
{
|
||||
return FMultiBlockThingsIterator::Next(&cres);
|
||||
return iterator.Next(&cres);
|
||||
}
|
||||
|
||||
DBlockThingsIterator(AActor *origin, double checkradius = -1, bool ignorerestricted = false)
|
||||
: FMultiBlockThingsIterator(check, origin, checkradius, ignorerestricted)
|
||||
: iterator(check, origin, checkradius, ignorerestricted)
|
||||
{
|
||||
cres.thing = nullptr;
|
||||
cres.Position.Zero();
|
||||
|
@ -1296,7 +1297,7 @@ public:
|
|||
}
|
||||
|
||||
DBlockThingsIterator(double checkx, double checky, double checkz, double checkh, double checkradius, bool ignorerestricted, sector_t *newsec)
|
||||
: FMultiBlockThingsIterator(check, checkx, checky, checkz, checkh, checkradius, ignorerestricted, newsec)
|
||||
: iterator(check, checkx, checky, checkz, checkh, checkradius, ignorerestricted, newsec)
|
||||
{
|
||||
cres.thing = nullptr;
|
||||
cres.Position.Zero();
|
||||
|
|
Loading…
Reference in a new issue