OP limit?

Status
Not open for further replies.
Level 8
Joined
Aug 2, 2006
Messages
346
I remember a while back I gave up on one of my warcraft 3 maps because of some kind of infinite loop safety BS that people were calling the "OP limit" or something like that, basically a trigger could only execute a certain number of lines of code before it was cut off.

Does this still exist in starcraft 2?
 
Yes and it is believed to be even more strick that WC3s as you now have thread limits and lots of other limits.

I have no idea how the opperation limit could have been a problem for you in WC3, there were a millin ways to create new "threads" of execution with totally reset op limits.

Actually I lie a bit, SC2 has a more strict op limit but allows easier creation of threads with reset op limits however those are limited in quantity.

What on earth could you want to do which could hit the op limit.
 
haha, well back in wc3, I was trying to make a map like "Soldiers" (map by exilus, or something like that). I was trying to make a sniper rifle that hit instantly, so I needed a point trace function. Since it was stopped by the terrain, I couldn't simply check distances and angles between units, I had to literally trace out the object's path. I'm sure there was a better way to do it then that, but oh well. Also, I wasn't SUPER great at coding, so I had no clue what a thread was.

As for now, I was really just curious.
 
You just have to trace out he contour of the terrain below the bullet not measure a million points. Basically due to the terrain being made of triangles the elevation only changes in certain ways. Infact there can atmost be 2 terrain gradient changes per tile this you need 1 measurement per tile the line crosses and then you should get a huge ammount of intersection data (line data) which if any cross your line it obviously has hit the ground.

I can not give you the exact method offhand but this is by far the most efficent way to atleast have a potential solution.
 
Status
Not open for further replies.
Back
Top