UGX-Mods Login

or login with an authentication provider below
Sign In with Google
Sign In with Twitter
Sign In with Discord
Sign In with Steam
Sign In with Facebook
Sign In with Twitch

[SOLVED] Make model spawned in via script collidable (Spawn in collision)

broken avatar :(
Created 11 years ago
by Deleted User
0 Members and 1 Guest are viewing this topic.
2,720 views
broken avatar :(
  • DeletedUser
  • Deleted Member
×
broken avatar :(
DeletedUser
This user is deleted :(
Yes i know what your thinking couldn't you just use (see code below in the code box) but the thing is i have tried this on Nacht (the map im modding) and it doesn't seem to work when i was modding Der Riese this worked perfectly fine :(

Anyone know of a way to spawn in a collision box or something another way

Code Snippet
Plaintext
spawnCollision("collision_geo_64x64x128", "collider", origin, angles);

Places im using this

perk spawn: https://github.com/WARDOGSK93/NDU-Revamp/blob/master/maps/_wardog_perks.gsc#L420
pack-a-punch spawn: https://github.com/WARDOGSK93/NDU-Revamp/blob/master/maps/_sanchez_pap.gsc#L24


I have done one of 2 things to solve this

1. Added all of the collisions to my mod.csv and precached them all (this is the most likely solution)
2. I linked my collision to my model (I doubt it but this is the only other thing i have changed) clip LinkTo(model);
broken avatar :(
×
broken avatar :(
Location: us
Date Registered: 11 March 2014
Last active: 5 years ago
Posts
264
Respect
Forum Rank
Mr. Elemental
Primary Group
Member
Signature
"Always code as if the guy who ends up maintaining your code will be a violent psychopath who knows where you live."
×
buttkicker845's Groups
buttkicker845's Contact & Social Links
 i believe(not positive) but if you make a collision map for a model it makes those models spawn solid so that might be a way around spawning collision in script

and did you include the collision_geo_64x64x12 in a csv someplace?
broken avatar :(
  • DeletedUser
  • Deleted Member
×
broken avatar :(
DeletedUser
This user is deleted :(
i believe(not positive) but if you make a collision map for a model it makes those models spawn solid so that might be a way around spawning collision in script

and did you include the collision_geo_64x64x12 in a csv someplace?
(i half know what a collision map is, if you clarify that would be nice) isnt a collision map only for models used in Radiant?

Double Post Merge: July 09, 2015, 12:30:13 am
Read the end of the OP for the solution
broken avatar :(
×
broken avatar :(
Location: gbMilton Keynes
Date Registered: 17 January 2014
Last active: 6 years ago
Posts
6,875
Respect
Forum Rank
Immortal
Primary Group
Scripter
My Groups
More
My Contact & Social Links
More
Signature
If you want scripts / features made for you, then contact me by PM or email / skype etc
it will cost you tho so if you have no intention of reciprocating don't even waste my time ;)
×
Harry Bo21's Groups
Donator ♥ Benevolent Soul who has our eternal gratitude and exclusive access to betas and the donator section of the forum.
Scripter Has shown effort and knowledge in the area of scripting while being a part of the UGX-Mods community.
Harry Bo21's Contact & Social LinksHarryBo000[email protected]HarryBo21
Collision maps (Otherwise referred to as "col" maps) I believe are set in asset manager

However all it does is practically create a clip of that shape, its rarely required as the odd shapes of most models allow you to do stuff like climb them (which in zombies we usually dont want), so the collisions (the way youve done it) are prob more suitable for this one

Quote
2. I linked my collision to my model (I doubt it but this is the only other thing i have changed) clip LinkTo(model);
Might be that it needed spawn flags, and doing that has "also" given it flags, not sure, but linking shouldnt make a difference
Last Edit: July 09, 2015, 12:37:12 am by Harry Bo21
broken avatar :(
  • DeletedUser
  • Deleted Member
×
broken avatar :(
DeletedUser
This user is deleted :(
Collision maps (Otherwise referred to as "col" maps) I believe are set in asset manager

However all it does is practically create a clip of that shape, its rarely required as the odd shapes of most models allow you to do stuff like climb them (which in zombies we usually dont want), so the collisions (the way youve done it) are prob more suitable for this one
Might be that it needed spawn flags, and doing that has "also" given it flags, not sure, but linking shouldnt make a difference

Thanks for the update on col maps and i didn't think that the second solution was the real one

 
Loading ...