Server Help Forum Index Server Help
Community forums for Subgame, ASSS, and bots
 
 FAQFAQ   SearchSearch   MemberlistMemberlist   UsergroupsUsergroups   StatisticsStatistics   RegisterRegister 
 ProfileProfile   Login to check your private messagesLogin to check your private messages   LoginLogin (SSL) 

Server Help | ASSS Wiki (0) | Shanky.com
Region solutions

 
Post new topic   Reply to topic Printable version
 View previous topic  [Extra] ?qip enhancement Post :: Post Simple region tools  View next topic  
Author Message
Bak
?ls -s
0 in


Age:24
Gender:Gender:Male
Joined: Jun 11 2004
Posts: 1826
Location: USA
Offline

PostPosted: Sat Jul 17, 2004 6:32 pm    Post subject: Reply to topic Reply with quote

here's my solution to region problems, I made the format accept regular numbers, as well as coords, it's reverse compatable with the old version

Format:
asss region file version 2
;use TILES not pixels

name: MyRegion
;load a rectangle with x=50, y=65, w=90, h=90 TILES
50, 100, 90, 90
; load a coordinate with x=512 y=512
512, 512
isbase

name: YourRegion
50,50
90,50
63,123,4,5

i don't think grel wants it to be official because he thinks using a sparse array for regions would work better... I say that just prevents overlapping regions




region 2.zip - 9.41 KB
File downloaded or viewed 45 time(s)
Back to top
View users profile Send private message Add User to Ignore List AIM Address
Dr Brain
Flip-flopping like a wind surfer


Age:38
Gender:Gender:Male
Joined: Dec 01 2002
Posts: 3502
Location: Hyperspace
Offline

PostPosted: Sat Jul 17, 2004 9:51 pm    Post subject: Reply to topic Reply with quote

The region file I will be converting has some 45 degree walls in it, so there is no way I can really do the file by hand, no matter the format.

Getting off topic here. Perhaps split this off into a new post?
_________________
Hyperspace Owner

Smong> so long as 99% deaths feel lame it will always be hyperspace to me
Back to top
View users profile Send private message Add User to Ignore List AIM Address Yahoo Messenger MSN Messenger
Bak
?ls -s
0 in


Age:24
Gender:Gender:Male
Joined: Jun 11 2004
Posts: 1826
Location: USA
Offline

PostPosted: Sat Jul 17, 2004 11:16 pm    Post subject: Reply to topic Reply with quote

Perhaps a polygon type object would be better... and you could define a series of points like

54,13:15,28:600,512:54,10

and it would make a polygon like that and then check for containment appropriately (draw a ray from your point in any direction, odd number of line intersections = inside polygon, even number of line intersections = outside polygon)
Back to top
View users profile Send private message Add User to Ignore List AIM Address
Mr Ekted
Movie Geek


Gender:Gender:Male
Joined: Feb 09 2004
Posts: 1379
Offline

PostPosted: Sun Jul 18, 2004 2:24 am    Post subject: Reply to topic Reply with quote

The best way is to have an LVL editor where you can indicate regions visually and save them to a file that ASSS can load. Trying to have users define polygonal or curved regions would cause all kinds of problems with "aliasing".
_________________
4,691 irradiated haggis!
Back to top
View users profile Send private message Add User to Ignore List
Dr Brain
Flip-flopping like a wind surfer


Age:38
Gender:Gender:Male
Joined: Dec 01 2002
Posts: 3502
Location: Hyperspace
Offline

PostPosted: Sun Jul 18, 2004 9:06 am    Post subject: Reply to topic Reply with quote

Best way aside, I need to make a region file. We can talk about what's nice all day long, but the fact of the matter is that I'll have to make a BMP converter.

Polygons also add ambiguity. Don't know for sure if the tiles right on the edge are inside or out. Rectangles you always know.
Back to top
View users profile Send private message Add User to Ignore List AIM Address Yahoo Messenger MSN Messenger
Bak
?ls -s
0 in


Age:24
Gender:Gender:Male
Joined: Jun 11 2004
Posts: 1826
Location: USA
Offline

PostPosted: Sun Jul 18, 2004 4:01 pm    Post subject: Reply to topic Reply with quote

you just said you wanted 45 degree angles. Wouldn't that add the same ambiguity?
Back to top
View users profile Send private message Add User to Ignore List AIM Address
-Smong-
Guest


Offline

PostPosted: Sun Jul 18, 2004 5:34 pm    Post subject: Reply to topic Reply with quote

Maybe you could make up a region from horizontal lines, and use some RLE method for the y axis:
; rectangle (5,10) (20,15)
;<how many times to repeat/increment y-coord>:<start y>,<start x>,<end x>
5:10,5,20
Back to top
Dr Brain
Flip-flopping like a wind surfer


Age:38
Gender:Gender:Male
Joined: Dec 01 2002
Posts: 3502
Location: Hyperspace
Offline

PostPosted: Sun Jul 18, 2004 6:43 pm    Post subject: Reply to topic Reply with quote

Bak wrote:
you just said you wanted 45 degree angles. Wouldn't that add the same ambiguity?


No, I said that because of the map's 45 degree angles, I can't make the file by hand. Far too tedious and prone to error.

If I were to only make the file once, I would use Excel to do it, but because there are always changes and additions needed, I will make the conveter sometime this or next week.
Back to top
View users profile Send private message Add User to Ignore List AIM Address Yahoo Messenger MSN Messenger
Display posts from previous:   
Post new topic   Reply to topic    Server Help Forum Index -> ASSS Custom Projects All times are GMT - 5 Hours
Page 1 of 1

 
Jump to:  
You can post new topics in this forum
You can reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum
You can attach files in this forum
You can download files in this forum
View online users | View Statistics | View Ignored List


Software by php BB © php BB Group
Server Load: 671 page(s) served in previous 5 minutes.

phpBB Created this page in 0.474051 seconds : 35 queries executed (90.4%): GZIP compression disabled