Raised This Month: $48 Target: $400
 12% 

Solved VecMins, VecMaxs func_hostage_rescue


Post New Thread Reply   
 
Thread Tools Display Modes
Author Message
pride95
Senior Member
Join Date: Aug 2015
Old 02-09-2018 , 14:45   VecMins, VecMaxs func_hostage_rescue
Reply With Quote #1

PHP Code:
    float fPosition[3];
    
GetClientAbsOrigin(iClientfPosition); 

    
int ent CreateEntityByName("func_hostage_rescue");
    
DispatchKeyValue(ent"targetname""fake_hostage_rescue");
    
DispatchKeyValueVector(ent"origin"fPosition);

    
DispatchSpawn(ent);
    
ActivateEntity(ent);

    
float fMins[] = {-100.0, -100.0, -100.0};
    
float fMaxs[] = {100.0100.0100.0};
    
    
SetEntPropVector(entProp_Send"m_vecMins"fMins);
    
SetEntPropVector(entProp_Send"m_vecMaxs"fMaxs); 
the entity is created, but the zone is represented just by the origin.
how can i set vecmins and vecmaxs to this entity with dispatchkeyvalue

Last edited by pride95; 02-19-2018 at 09:53.
pride95 is offline
Neuro Toxin
Veteran Member
Join Date: Oct 2013
Location: { closing the void; }
Old 02-11-2018 , 17:38   Re: VecMins, VecMaxs func_hostage_rescue
Reply With Quote #2

I think its showpos in client console shows your coordinates as you move around on a map.
__________________
Neuro Toxin is online now
pride95
Senior Member
Join Date: Aug 2015
Old 02-18-2018 , 17:35   Re: VecMins, VecMaxs func_hostage_rescue
Reply With Quote #3

PHP Code:

    float fPosition
[3]; 
    
float fMins[] = {-200.0, -200.0, -200.0};
    
float fMaxs[] = {200.0200.0200.0};
    
GetEntPropVector(iClientProp_Send"m_vecOrigin"fPosition);

    
int ent CreateEntityByName("func_hostage_rescue");
    
DispatchKeyValue(ent"spawnflags""257");
    
DispatchKeyValueVector(ent"origin"fPosition);

    
DispatchSpawn(ent); 
    
ActivateEntity(ent);
    
    
SetEntPropVector(entProp_Send"m_vecMins"fMins);
    
SetEntPropVector(entProp_Send"m_vecMaxs"fMaxs);
    
SetEntProp(entProp_Send"m_nSolidType"2); 
the zone is still just my position, an 3d point. the vecmins and vecmaxs doesn't works for func_hostage_rescue or func_buyzone.

am i doing something wrong?
pride95 is offline
Fyren
FyrenFyrenFyrenFyrenFyren FyrenFyrenFyrenFyrenFyren FyrenFyrenFyrenFyrenFyren FyrenFyrenFyrenFyrenFyren
Join Date: Feb 2106
Old 02-18-2018 , 18:42   Re: VecMins, VecMaxs func_hostage_rescue
Reply With Quote #4

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

This old forum post claims you have to set a model even though it doesn't make any visual difference.
Fyren 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 07:09.


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