Gamestudio Links
Zorro Links
Newest Posts
What are you working on?
by CocaCola
Today at 02:42
CyberCycle Adaptive Cy
by AndrewAMD
Yesterday at 18:54
How does Zorro handle new strategy/asset?
by Seymour
Yesterday at 15:29
About 1M entities!
by txesmi
Yesterday at 14:16
Montecarlo statistical mode parameter optimization
by AndrewAMD
Yesterday at 13:36
Strategy Development
by OptimusPrime
Yesterday at 02:08
Intercept Friday Daily Close
by tradingest
12/12/18 21:40
AUM Magazine
Latest Screens
Worst Case Z
AckCon'18 - Lotter vs the World 2 - Preview Release
Evonet Beta v1.0 : Online Project Development Template
Lake scene
Who's Online
10 registered (Ayumi, MINER, wdlmaster, kvm, MatPed, 3run, jenGs, 3 invisible), 488 Guests and 6 Spiders online.
Key: Admin, Global Mod, Mod
Newest Members
rssflc, mahomed, bondz, Neil_G, bobby4h
18118 Registered Users
Topic Options
Rate This Topic
#471295 - 02/27/18 05:20 About entity_max error E1513 or E1005
20BN Offline
Member

Registered: 02/08/03
Posts: 116
Loc: RP China
Hi all.
About entity_max error E1513 or E1005.
how to set entity_max(unlimited, ent_create(...) ) use sys_malloc?
THANKS.

Top
#471297 - 02/27/18 08:28 Re: About entity_max error E1513 or E1005 [Re: 20BN]
Kartoffel Offline
Expert

Registered: 06/11/09
Posts: 2210
Loc: Bavaria, Germany
there's a variable called max_entities that you can set at the start of the main function:

Code:
void main()
{
   max_entities = 5000;

_________________________
POTATO-MAN saves the day! - Random

Top
#471298 - 02/27/18 10:08 Re: About entity_max error E1513 or E1005 [Re: Kartoffel]
20BN Offline
Member

Registered: 02/08/03
Posts: 116
Loc: RP China
@Kartoffel
THANKS your time.

I need more than 100K entities in level.( my dynamic system render less than 500 entities in area, not all render in screen).
The engine crash when i set entity_max > 100000. But i need more entities support.

Top
#471299 - 02/27/18 12:27 Re: About entity_max error E1513 or E1005 [Re: 20BN]
BlackJack Offline
Member

Registered: 02/10/11
Posts: 118
Loc: Germany Nrw Herford
I mark myself here quickly - had a similar question for some time.

Top
#471318 - 02/27/18 23:58 Re: About entity_max error E1513 or E1005 [Re: BlackJack]
Kartoffel Offline
Expert

Registered: 06/11/09
Posts: 2210
Loc: Bavaria, Germany
I don't think that's possible.

I think the best way is to create entities only when they are needed.
_________________________
POTATO-MAN saves the day! - Random

Top
#471790 - 03/19/18 21:51 Re: About entity_max error E1513 or E1005 [Re: 20BN]
Dooley Offline
User

Registered: 05/12/05
Posts: 593
Loc: Chicago, IL
Originally Posted By: 20BN
@Kartoffel
THANKS your time.

I need more than 100K entities in level.( my dynamic system render less than 500 entities in area, not all render in screen).
The engine crash when i set entity_max > 100000. But i need more entities support.


I think you need to think about optimizing your game. If you are only rendering 500 at a time, you can use some clever programming to change/reposition entities when you enter a new area. Having 100000 or more entities will make any game run very slow if at all.

Can I ask what kind of things you need so much of in your game?


Edited by Dooley (03/19/18 21:52)
_________________________
Check out "Star Explorers" on Steam:
http://store.steampowered.com/app/502720/Star_Explorers/

Anomalies released on Steam: http://store.steampowered.com/app/546780


Top
#471804 - 03/20/18 06:45 Re: About entity_max error E1513 or E1005 [Re: Dooley]
20BN Offline
Member

Registered: 02/08/03
Posts: 116
Loc: RP China
Originally Posted By: Dooley
Originally Posted By: 20BN
@Kartoffel
THANKS your time.

I need more than 100K entities in level.( my dynamic system render less than 500 entities in area, not all render in screen).
The engine crash when i set entity_max > 100000. But i need more entities support.


I think you need to think about optimizing your game. If you are only rendering 500 at a time, you can use some clever programming to change/reposition entities when you enter a new area. Having 100000 or more entities will make any game run very slow if at all.

Can I ask what kind of things you need so much of in your game?


less than 5000.

Top
#471888 - 03/23/18 00:06 Re: About entity_max error E1513 or E1005 [Re: 20BN]
Dooley Offline
User

Registered: 05/12/05
Posts: 593
Loc: Chicago, IL
So you could use "ent_create()" to create new entities when they are needed, and "ent_remove()" to remove the ones that you don't need any more. This way it is possible to have many more entities in a level.

You will still have to be careful with memory usage, and may need to use "ent_purge()" to remove resources from memory.
_________________________
Check out "Star Explorers" on Steam:
http://store.steampowered.com/app/502720/Star_Explorers/

Anomalies released on Steam: http://store.steampowered.com/app/546780


Top


Moderator:  HeelX, Lukas, Rei_Ayanami, VeT 

Gamestudio download | chip programmers | Zorro platform | shop | Data Protection Policy

oP group Germany GmbH | Birkenstr. 25-27 | 63549 Ronneburg / Germany | info (at) opgroup.de