Raised This Month: $ Target: $400
 0% 

Entity disappearing under the ground


Post New Thread Reply   
 
Thread Tools Display Modes
Author Message
abdelwahab
Member
Join Date: Aug 2019
Old 04-14-2024 , 09:12   Entity disappearing under the ground
Reply With Quote #1

Hello!,
So here is the thing i created entity when i say ent
PHP Code:
        static Float:flOrigin[3]; get_entvar(plrvar_originflOrigin);
        
engfunc(EngFunc_SetModelg_pPlayerEnt[plr], g_szModel);
        
set_entvar(g_pPlayerEnt[plr], var_originflOrigin);
        
set_entvar(g_pPlayerEnt[plr], var_mins, {-19.3, -8.970.0});
        
set_entvar(g_pPlayerEnt[plr], var_maxs, {19.38.9712.76});
        
set_entvar(g_pPlayerEnt[plr], var_solidSOLID_NOT);
        
set_entvar(g_pPlayerEnt[plr], var_movetypeMOVETYPE_TOSS);
        
set_entvar(g_pPlayerEnt[plr], var_gravity1.0); 
the thing is when im near the wall and create the ent, the ent goes under the ground and disappear totally, it disappear slowing the gravity don't effect it.
Thanks!
abdelwahab is offline
mlibre
Veteran Member
Join Date: Nov 2015
Location: return PLUGIN_CONTINUE
Old 04-14-2024 , 14:17   Re: Entity disappearing under the ground
Reply With Quote #2

I guess you have to upload it more than the current origin

according to the "Z" coordinates
__________________

Last edited by mlibre; 04-17-2024 at 13:40. Reason: Z
mlibre is offline
JocAnis
Veteran Member
Join Date: Jun 2010
Old 04-17-2024 , 04:57   Re: Entity disappearing under the ground
Reply With Quote #3

@mlibre do you understand [2] is axis for the Z/height? better remove that drawing
__________________
KZ Public Autocup - PrimeKZ

My blog: http://primekz.xyz (in progress...) - not active (dec 2022)
JocAnis is offline
georgik57
Veteran Member
Join Date: Oct 2008
Location: 🎧Music World
Old 04-17-2024 , 09:56   Re: Entity disappearing under the ground
Reply With Quote #4

it's because of the size. you spawn it inside the wall so it goes through.
edit: and the solid_not property. pretty self explanatory. if it's not solid it will be able to move through walls.
__________________

Last edited by georgik57; 04-17-2024 at 09:57.
georgik57 is offline
Send a message via MSN to georgik57 Send a message via Yahoo to georgik57 Send a message via Skype™ to georgik57
Natsheh
Veteran Member
Join Date: Sep 2012
Old 04-17-2024 , 10:12   Re: Entity disappearing under the ground
Reply With Quote #5

You are spawning the entity origin inside the world.
__________________
@Jailbreak Main Mod v2.7.0 100%
@User Tag Prefix 100% done !
@Mystery Box 100% done !
@VIP System 100% done !


Last edited by Natsheh; 04-17-2024 at 10:15.
Natsheh is offline
Send a message via MSN to Natsheh Send a message via Skype™ to Natsheh
mlibre
Veteran Member
Join Date: Nov 2015
Location: return PLUGIN_CONTINUE
Old 04-17-2024 , 13:41   Re: Entity disappearing under the ground
Reply With Quote #6

@JocAnis fixed you understand me where things were going ;)
__________________
mlibre is offline
abdelwahab
Member
Join Date: Aug 2019
Old 04-17-2024 , 14:10   Re: Entity disappearing under the ground
Reply With Quote #7

Quote:
Originally Posted by mlibre View Post
I guess you have to upload it more than the current origin

according to the "Z" coordinates

This didn't help, thanks tho
abdelwahab is offline
abdelwahab
Member
Join Date: Aug 2019
Old 04-17-2024 , 14:30   Re: Entity disappearing under the ground
Reply With Quote #8

Quote:
Originally Posted by Natsheh View Post
You are spawning the entity origin inside the world.
Any ideas how to fix that, thx
abdelwahab is offline
mlibre
Veteran Member
Join Date: Nov 2015
Location: return PLUGIN_CONTINUE
Old 04-17-2024 , 19:10   Re: Entity disappearing under the ground
Reply With Quote #9

how have you applied it
__________________
mlibre is offline
abdelwahab
Member
Join Date: Aug 2019
Old 04-18-2024 , 05:14   Re: Entity disappearing under the ground
Reply With Quote #10

I added what u said to the z axis flOrigin[2] += 10.0
abdelwahab is offline
Reply


Thread Tools
Display Modes

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 05:48.


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