• 🏆 Texturing Contest #33 is OPEN! Contestants must re-texture a SD unit model found in-game (Warcraft 3 Classic), recreating the unit into a peaceful NPC version. 🔗Click here to enter!

Replace Building - Collision Problems

Status
Not open for further replies.
Level 4
Joined
Feb 23, 2020
Messages
33
Hi all,

I'm trying to replace a building (Demonic Gate model) with itself, because the model doesn't have selection through an upgrade. However, when I do it, and there are units surrounding the unit, the building jumps to another location (because of collision I'm assuming).

I've read a few posts and found that 'Chaos' can be used to help with this. Could someone help me understand how to use it properly?

Any other suggestions about how to replace the building without it moving around?

Cheers
 

Uncle

Warcraft Moderator
Level 64
Joined
Aug 10, 2018
Messages
6,580
You could pick every unit within close range of the Gate and store them in a temporary Unit Group, pick through and hide them, then replace the gate, and then pick through and unhide them, destroying the Unit Group afterwards.

This will interrupt the orders of those units but it should guarantee that the gate is placed exactly where it needs to be.

You could also potentially turn the collision off for those units instead of hiding them, not sure if that would work.
 
Level 9
Joined
Mar 26, 2017
Messages
376
I was going to suggest that but if I recall correctly it screws with the pathing texture. The pathing texture doesn't move along with the structure. Haven't tested it in a while though.

Ah, that I don't know. For the buildings in my map that use this I don't use path textures.
Before I posted this I tested in 1.32 editor on moving a regular Town Hall and I didn't see anything unusual about it though.
 
Level 4
Joined
Feb 23, 2020
Messages
33
Yeah I am using reforged. Don't know if I'll be shunned for that here lol. Also having issues with the client crashing after 20 or so minutes, although I know that's an entirely separate issue. I was just testing before I replied here, after my game crashed. I've looked at reasons for crashing and trigger leaks and everything, fixed it all up but it's still happening! So annoying.
 

Uncle

Warcraft Moderator
Level 64
Joined
Aug 10, 2018
Messages
6,580
Yeah I am using reforged. Don't know if I'll be shunned for that here lol. Also having issues with the client crashing after 20 or so minutes, although I know that's an entirely separate issue. I was just testing before I replied here, after my game crashed. I've looked at reasons for crashing and trigger leaks and everything, fixed it all up but it's still happening! So annoying.
Nope, matter of fact you're my favorite kind of newcomer.

There's all sorts of useful new Editor tools that come with the recent patches, and the people living in the past (although I fully respect and agree with their opinions to do so) are missing out on a lot of good stuff.

Not sure about the crashing though. Does it only happen in your map?
 
Level 4
Joined
Feb 23, 2020
Messages
33
Good question, actually. I haven't actually played another custom map yet! I finished the main campaigns and then dived into making my map (which is pretty simple - 8 players, a few gold mines, and just changing models around, and about 30-40 simple triggers). I'll play some other maps and get back to you when I have the time. Maybe it isn't my map at all but something wrong with my drivers.
 

Uncle

Warcraft Moderator
Level 64
Joined
Aug 10, 2018
Messages
6,580
Well, if it ONLY happens in your custom map then I'd assume it's a trigger that has an infinite loop that's causing the crash. Something along the lines of:

Event:
A unit is issued an order targeting a point
Action:
Order triggering unit to move to center of the map

So in the above example the Action is causing the Event to go off, and the Event is causing the Action to go off, creating an infinite loop. A nice trick to get around this is to temporarily Turn Off the trigger like so:

Event:
A unit is issued an order targeting a point
Action:
Turn off this trigger
Order triggering unit to move to center of the map
Turn on this trigger

So the Trigger will be turned off when you issue the move order which allows us to ignore the Event. This works without any issues.
 
Last edited:
Status
Not open for further replies.
Top