Raised This Month: $32 Target: $400
 8% 

How to make 700 sprites visible all over the map???


Post New Thread Reply   
 
Thread Tools Display Modes
Author Message
z0mbiland
Senior Member
Join Date: Jan 2013
Old 05-28-2015 , 05:36   How to make 700 sprites visible all over the map???
Reply With Quote #1

Hello,

I want to make a sprite effect with 700 sprites all over the map at the same time.

I need a code to make all sprites visible because not all of this will be appear. I want to ignore a function of invisibility somehow.

I need a answer just for this!
z0mbiland is offline
.Dare Devil.
Veteran Member
Join Date: Sep 2010
Old 05-28-2015 , 10:36   Re: How to make 700 sprites visible all over the map???
Reply With Quote #2

Depends what those sprites are.
Here are limits that are hardcoded client side:
256 entities can be rendered in one screen ( entities can be sprites/models )
512 temp entities, they can be models and sprites yet there is less control over them.

Tell me exactly what effect does, i'll tell you then if it can be done or not and
if it can be done then i shall show you a code hint.
.Dare Devil. is offline
z0mbiland
Senior Member
Join Date: Jan 2013
Old 05-28-2015 , 11:10   Re: How to make 700 sprites visible all over the map???
Reply With Quote #3

Quote:
Originally Posted by .Dare Devil. View Post
Depends what those sprites are.
Here are limits that are hardcoded client side:
256 entities can be rendered in one screen ( entities can be sprites/models )
512 temp entities, they can be models and sprites yet there is less control over them.

Tell me exactly what effect does, i'll tell you then if it can be done or not and
if it can be done then i shall show you a code hint.
The effect will be a big bomb hidden on a map with a shield protection who kill all the players. The bomb will spread 700 sprites on the map when is planted! Players must search, destroy the shield and defuse it!
z0mbiland is offline
.Dare Devil.
Veteran Member
Join Date: Sep 2010
Old 05-28-2015 , 17:38   Re: How to make 700 sprites visible all over the map???
Reply With Quote #4

how are those sprites controlled?
Also you have to take account that about 100 entities will be for cs by default.
.Dare Devil. is offline
z0mbiland
Senior Member
Join Date: Jan 2013
Old 05-28-2015 , 17:57   Re: How to make 700 sprites visible all over the map???
Reply With Quote #5

Quote:
Originally Posted by .Dare Devil. View Post
how are those sprites controlled?
Also you have to take account that about 100 entities will be for cs by default.
Will be a TE_SPRITETRAIL stock, i will hook C4!
Do you have a code hint?

https://forums.alliedmods.net/showthread.php?t=54117

Orangutanz did it but he not provide a working example!
"There doesn't seem to be a cap limit either I had over 10,000 entities."

Last edited by z0mbiland; 05-28-2015 at 18:06.
z0mbiland is offline
.Dare Devil.
Veteran Member
Join Date: Sep 2010
Old 05-29-2015 , 08:40   Re: How to make 700 sprites visible all over the map???
Reply With Quote #6

Even by changing the maximum amount of how many entities server can handle, you can't
change how many of them can be visible at once.

You just try that TE_SPRITETRAIL message out and see how many particles it allows.

If you know how blockmaker mod works then i edited that mod so you could have much much more block
entities.

All special blocks were entities and normal blocks where displayed with TE_PROJECTILE message
so i was able to have 512 normal blocks + 255 - ( player, w weapon, map entity's models that were visible )


Btw, be sure that you don't send too many messages at one server frame.
Other ways there will going to be problem. Problem may not appear if you test alone but when
there are players then player's client would crash.
.Dare Devil. is offline
z0mbiland
Senior Member
Join Date: Jan 2013
Old 05-29-2015 , 12:36   Re: How to make 700 sprites visible all over the map???
Reply With Quote #7

Quote:
Originally Posted by .Dare Devil. View Post
Even by changing the maximum amount of how many entities server can handle, you can't
change how many of them can be visible at once.

You just try that TE_SPRITETRAIL message out and see how many particles it allows.

If you know how blockmaker mod works then i edited that mod so you could have much much more block
entities.

All special blocks were entities and normal blocks where displayed with TE_PROJECTILE message
so i was able to have 512 normal blocks + 255 - ( player, w weapon, map entity's models that were visible )


Btw, be sure that you don't send too many messages at one server frame.
Other ways there will going to be problem. Problem may not appear if you test alone but when
there are players then player's client would crash.
I don't know how the block makers works - this is your code hint?! What you say about orpheu?
What function pass the visibility to integrate in TE_SPRITETRAIL stock?

engine.inc
is_visible
native is_visible(entity, target);

engine_stocks.inc
get_entity_visibility
stock get_entity_visibility(entity)
Returns 1 if entity is visible.

engine_stocks.inc
set_entity_visibility
stock set_entity_visibility(entity, visible = 1)
If visible = 1, entity will be set to be visible, else invisible.


fakemeta_util.inc
fm_is_ent_visible
stock bool:fm_is_ent_visible(index, entity, ignoremonsters = 0) {

fakemeta_util.inc
fm_is_visible
stock bool:fm_is_visible(index, const Float:point[3], ignoremonsters = 0) {

xs.inc
xs_freevisibleslots
stock bools_freevisibleslots(num)

Last edited by z0mbiland; 05-29-2015 at 14:34.
z0mbiland is offline
.Dare Devil.
Veteran Member
Join Date: Sep 2010
Old 05-29-2015 , 17:46   Re: How to make 700 sprites visible all over the map???
Reply With Quote #8

You can't change the limit that how many visible models/sprites there can be.
How can't you understand it?

The visibility is handled on client side. There no way to access client side.
.Dare Devil. is offline
fysiks
Veteran Member
Join Date: Sep 2007
Location: Flatland, USA
Old 05-29-2015 , 18:00   Re: How to make 700 sprites visible all over the map???
Reply With Quote #9

I've tried to display only a fraction of what you are requesting and they still didn't all show up. Graphics is handled client-side so you can't really do anything about it.
__________________
fysiks is offline
z0mbiland
Senior Member
Join Date: Jan 2013
Old 05-30-2015 , 01:59   Re: How to make 700 sprites visible all over the map???
Reply With Quote #10

Quote:
Originally Posted by fysiks View Post
I've tried to display only a fraction of what you are requesting and they still didn't all show up. Graphics is handled client-side so you can't really do anything about it.
I found something.
I start a server in my pc, I set unlimited ammo, ak47, fy_snow map, ALONE in the map, i play with speed cheat.

After shooting with speed this error appear:

Sentence or Pitch shift ignored. > 16 playing!
Sentence or Pitch shift ignored. > 16 playing!
Sentence or Pitch shift ignored. > 16 playin

I find the real error source!


[IMG]http://s8.************/7bigl4ps5/ENTITY.jpg[/IMG]

What i want to do to fix all of this!

Let's take a TE_SPRITETRAIL and give him a task. 10 sprites at every 3 seconds. the sprites will have the life of 7.

when task 1 is on the ground, delete task 1 sprites to start the task 2.
when task 2 is on the ground, delete task 2 sprites to start the task 3.

What i want is TO NOT OVERLAP task 1 to task2 ...

Last edited by z0mbiland; 05-30-2015 at 02:28.
z0mbiland is offline
Reply



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT -4. The time now is 14:18.


Powered by vBulletin®
Copyright ©2000 - 2024, vBulletin Solutions, Inc.
Theme made by Freecode