SRL Archive - Help and Support

Area Recognition


Total

2012-10-24 15:43:28

I have an agility script that has been around for a while and I was thinking of updating it but I can't think of a reliable way to do it. What I want it to do is to recognize which part of the course it is on so that it doesn't always have to start at the beginning of the course when you start it. One way I thought of was making a DTM of something unique around the area so if it finds that DTM, it will know it is in that area. I feel that using DTMs won't be very useful/accurate in this situation. Anyone have any ideas?

Footy

2012-10-24 15:48:56

ODTM's are useful for that. Alternatively, you could try SPS, or search for items on the MS that you can only see from a certain spot.

Kasi

2012-10-24 15:53:03

DTM's are very reliable. you might not be using them properly, thats all. what agility course?

Total

2012-10-24 16:02:00

Gnome Stronghold. I know DTMs are reliable, but I always have to update them. My script actually uses DTMs to do the course. I feel that DTMs may not be reliable though because there are parts of the course where you are able to see the other obstacles, and that would mean it would recognize the wrong part of the course. I'm not sure if ODTM would work because the script goes up onto a 2nd and 3rd plane, so there are no trees or anything. I could try custom SPS maps I guess.

P1ng

2012-10-24 16:09:58

Definitely go with DTMs, they are great for location checking in a small area like an agility course :)

Ashaman88

2012-10-24 17:52:16

Check out me ape atoll script, the whereami function is where it's at! I didn't even need to make my own map. I would try the built in one first - unless you really don't mind it. Also keep in mind when you are up floors the map will be black

riwu

2012-10-24 20:07:54

It's possible that you may not even need any additional detection if you structure your script correctly.

Like looping through every obstacle's obj finding until one of them finds it (which would indicate that you are at that spot).

If it may result in the script going for a further obstacle instead of the one nearest, then you can gather all the points retrieved by the object finding, and sorting them from the nearest (center).

Ashaman's suggestion could also improve the efficiency by classifying the obj finding procedures to continue/skip based on PercentBlackMM.

Total

2012-10-24 22:33:33

The problem with just basing it off of the obstacle DTMs is that I switch angles a lot on the script to maximize exp/hr so I couldn't have it detect for example the run wall obstacle if it was facing north. I'll take a look at Ashaman's script and see what's up.

Ashaman88

2012-10-24 22:37:31

Pretty much it just establishes a box for each area and if the sps point is in said box, then it does the obstacle for that area. It might be more difficult for yours since a good chunk of it you will be upstairs

Kasi

2012-10-25 04:54:17

From: Total
The problem with just basing it off of the obstacle DTMs is that I switch angles a lot on the script to maximize exp/hr so I couldn't have it detect for example the run wall obstacle if it was facing north. I'll take a look at Ashaman's script and see what's up.

Use ddtms, mine work fine for area recognition, erm ill post a function later today to explain, got college

litoris

2012-10-25 04:59:54

From: Kasi
Use ddtms, mine work fine for area recognition, erm ill post a function later today to explain, got college


I'd suggest this too. I use a simple static DTM for area recognition in my miner, and even that works. Check out Fakawi's DDTM tut, and Markus' SRL Miner to see how they are used.