Duke4.net Forums: Numsprites var inaccurate - Duke4.net Forums

Jump to content

Page 1 of 1
  • You cannot start a new topic
  • You cannot reply to this topic

Numsprites var inaccurate

User is offline   Danukem 

  • Duke Plus Developer

#1

http://wiki.eduke32....wiki/Numsprites

My code had been depending on this variable being accurate, but apparently it's not! In one map, the var had a value of 407 when there were actually over 600 sprites in the map (which can be easily verified in mapster). I was using Numsprites to check when to stop processing sprites during EVENT_ENTERLEVEL. I could see during the game that a large number of sprites were not being processed by my code. As a substitute, my code now checks all 16384 sprites and just ignores those with a statnum of 1024 -- it works fine now.

EDIT: And before anyone asks -- yes, EVENT_LOADACTOR would be a more natural place to put code that processes sprites before the game starts, but for reasons I won't go into, the code is currently in EVENT_ENTERLEVEL.

This post has been edited by Trooper Dan: 20 February 2017 - 03:55 AM

0

Share this topic:


Page 1 of 1
  • You cannot start a new topic
  • You cannot reply to this topic


All copyrights and trademarks not owned by Voidpoint, LLC are the sole property of their respective owners. Play Ion Fury! ;) © Voidpoint, LLC

Enter your sign in name and password


Sign in options