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

Attach model and shift


Post New Thread Reply   
 
Thread Tools Display Modes
Author Message
Srutz
Junior Member
Join Date: Dec 2015
Old 12-30-2015 , 18:56   Attach model and shift
Reply With Quote #1

Hello,
I attach entity1 to another entity2 but i want to shift entity1 on the left (x + 10 for exemple), how can i do this ?

PHP Code:
char name[256];
GetEntPropString(entity2Prop_Data"m_iName"namesizeof(name));
SetVariantString(name);
AcceptEntityInput(entity1"SetParent");
SetVariantString("point");
AcceptEntityInput(entity1"SetParentAttachment");

And 
shift entity1 :
10 
Thanks for reading
Srutz is offline
Mitchell
~lick~
Join Date: Mar 2010
Old 12-30-2015 , 19:33   Re: Attach model and shift
Reply With Quote #2

TeleportEntity

Also you shouldn't set the target name of the entity, just use !activator.
Mitchell is offline
Srutz
Junior Member
Join Date: Dec 2015
Old 12-30-2015 , 21:43   Re: Attach model and shift
Reply With Quote #3

Quote:
Originally Posted by Mitchell View Post
TeleportEntity

Also you shouldn't set the target name of the entity, just use !activator.
Ok and do you have exemple based on my code on the top ?
Thanks
Srutz is offline
Chdata
Veteran Member
Join Date: Aug 2012
Location: Computer Chair, Illinois
Old 12-31-2015 , 19:35   Re: Attach model and shift
Reply With Quote #4

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

also note that the offset thing here is untested lol
__________________

Last edited by Chdata; 12-31-2015 at 19:35.
Chdata 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 19:34.


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