AlliedModders

AlliedModders (https://forums.alliedmods.net/index.php)
-   Scripting Help (https://forums.alliedmods.net/forumdisplay.php?f=11)
-   -   C4 Size. (https://forums.alliedmods.net/showthread.php?t=54632)

Rolnaaba 04-30-2007 11:13

C4 Size.
 
In this tut, the sizes in section two:
Code:
new Float:maxs[3] = {16.0,16.0,36.0} new Float:mins[3] = {-16.0,-16.0,-36.0} entity_set_size(ent,mins,maxs) entity_set_int(ent,EV_INT_solid, 2)
what would be the sizes for the c4?

Orangutanz 04-30-2007 11:54

Re: C4 Size.
 
Code:

pev_origin = Vector (-1530.9, 2548.3, 0.0)
pev_absmin = Vector (-1531.9, 2547.3, -0.9) // Origin + Mins
pev_absmax = Vector (-1521.9, 2557.3, 9.0) // Origin + Maxs
pev_mins = Vector (0.0, 0.0, 0.0)
pev_maxs = Vector (8.0, 8.0, 8.0)
pev_size = Vector (8.0, 8.0, 8.0)

Doesn't look right does it, but that is the data I gathered from the c4 when I planted it!

Rolnaaba 04-30-2007 12:26

Re: C4 Size.
 
so this is how I would do the above in fakemeta?
Code:
new Float:mins[3] = {0.0, 0.0, 0.0} new Float:maxs[3] = {8.0, 8.0, 8.0}   set_pev(ent, pev_size, mins, maxs);
think thats wrong but I dont know the aurgument order for pev_size :)
[rethink] would i just do:
Code:
new Float:size[3] = {8.0, 8.0, 8.0} set_pev(ent, pev_size, size);
??

Orangutanz 04-30-2007 12:55

Re: C4 Size.
 
Its best to call:

Code:
engfunc(EngFunc_SetSize, ent, Float:{0.0,0.0,0.0}, Float:{8.0,8.0,8.0})
Else the entity won't update correctly.

Also note that if your manually placing the c4 bomb, to set the origin before the above! engfunc(EngFunc_SetOrigin, ent, ORIGIN)

Rolnaaba 04-30-2007 13:03

Re: C4 Size.
 
did set origin, just needed a size declaration in good ol' fakemeta lol, thanks orang


All times are GMT -4. The time now is 06:38.

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