AlliedModders

AlliedModders (https://forums.alliedmods.net/index.php)
-   Scripting Help (https://forums.alliedmods.net/forumdisplay.php?f=11)
-   -   Model over Floor (https://forums.alliedmods.net/showthread.php?t=84964)

AntiBots 02-03-2009 14:33

Model over Floor
 
Well I need to set this model into the floor

PHP Code:

 
public fwdplayerkill(idattackid)
{
 if( !
is_user_connected(attackid) )
  return 
HAM_IGNORED
 
 
new Float:origin[3]
 
pev(idpev_originorigin)
 
 new 
ent engfunc(EngFunc_CreateNamedEntityengfunc(EngFunc_AllocString"info_target"));
 
set_pev(entpev_classname"fake_deadbody");
 
 
set_pev(entpev_solidSOLID_NOT)
 
set_pev(entpev_movetypeMOVETYPE_NONE)
 
engfunc(EngFunc_SetModelentBODYMODEL)
 
engfunc(EngFunc_SetSizeentFloat:{-100.0, -100.0, -100.0}, Float:{100.0100.0100.0});
 
engfunc(EngFunc_SetOriginentorigin)
 
//engfunc(EngFunc_DropToFloor, ent)
 
 
return HAM_IGNORED
 


I try with fm_distance_to_floor but i cant.

Sn!ff3r 02-04-2009 04:50

Re: Model over Floor
 
I also need this.

xPaw 02-04-2009 08:24

Re: Model over Floor
 
PHP Code:

engfunc(EngFunc_DropToFloorent); 

not works?

Dores 02-04-2009 09:14

Re: Model over Floor
 
Code:
new Float:origin[3]; pev(id, pev_origin, origin); origin[2] -= 35.0; engfunc(EngFunc_SetOrigin, ent, origin);

Sn!ff3r 02-04-2009 11:16

Re: Model over Floor
 
Quote:

Originally Posted by xPaw (Post 755507)
PHP Code:

engfunc(EngFunc_DropToFloorent); 

not works?

Sometimes entity is too high.

AntiBots 02-04-2009 11:25

Re: Model over Floor
 
Well here my final version... for mi Work:

PHP Code:

new Float:origin[3], Float:velo[3]
pev(idpev_originorigin)
pev(idpev_velocityvelo)
 
new 
newent engfunc(EngFunc_CreateNamedEntityengfunc(EngFunc_AllocString,"info_target"))
 
velo[2] += 100
set_pev
(newentpev_originorigin)
set_pev(newentpev_classname"block_muerte")
engfunc(EngFunc_SetModelnewentMODEL_FILE)
engfunc(EngFunc_SetSize,newent, {-8.0, -16.0, -8.0} ,{8.016.08.0})
set_pev(newentpev_solidSOLID_TRIGGER)
set_pev(newentpev_movetype,MOVETYPE_TOSS)
set_pev(newentpev_velocity,velo)
engfunc(EngFunc_DropToFloor,newent

Dont need to spawn ent with EngFunc_DropToFloor


All times are GMT -4. The time now is 01:45.

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