SRB2 Message Board  

Go Back   SRB2 Message Board > Sonic Robo Blast 2 > SRB2 Discussion

Reply
 
Thread Tools Search this Thread
Old 03-25-2010   #1
Fawfulfan
The Tortured Planet guy
 
Fawfulfan's Avatar
Default Linedef Types 21 and 30

I'm really curious as to what all of these linedefs do:

Linedef Type 21: PolyObject - Explicitly Include Line
Linedef Type 30: PolyObject - Waving Flag

Obviously, it's something to do with PolyObjects...but what?
__________________
Just another indie game developer...check out my website, Chapman Games!
Fawfulfan is offline   Reply With Quote
Old 03-25-2010   #2
Chaos Zero 64
 
Chaos Zero 64's Avatar
Default

Linedef Type 30 is CEZ's flag that waves with the wind. Not sure about the other one, though.
__________________
Quote:
Originally Posted by Bigboi View Post
Personally, if SEGA makes a nice sum of cash, they're doing their job well. They don't need to appeal to hordes of manchildren that are pissed that some kid games aren't fun to play.
Your and You're. Learn the difference.
Chaos Zero 64 is offline   Reply With Quote
Old 03-25-2010   #3
Fawfulfan
The Tortured Planet guy
 
Fawfulfan's Avatar
Default

Hmmm...how is the Waving Flag effect created? It might be useful for my mod.
__________________
Just another indie game developer...check out my website, Chapman Games!
Fawfulfan is offline   Reply With Quote
Old 03-25-2010   #4
MascaraSnake
aka SpiritCrusher
Moderator
 
MascaraSnake's Avatar
Default

I started looking at it and wrote what I know about it on the wiki, but I haven't found out much yet, especially not how it actually makes CEZ's flags wave. Just look at map11 in SRB2DB, it doesn't seem all too complicated.
MascaraSnake is offline   Reply With Quote
Old 03-30-2010   #5
Fawfulfan
The Tortured Planet guy
 
Fawfulfan's Avatar
Default

I'm still puzzled at what the "Explicitly Include Line" effect does. Maybe someone could look it up in the source code. (My knowledge of coding is pretty basic, so that someone can't be me).
__________________
Just another indie game developer...check out my website, Chapman Games!
Fawfulfan is offline   Reply With Quote
Old 03-30-2010   #6
MascaraSnake
aka SpiritCrusher
Moderator
 
MascaraSnake's Avatar
Default

You don't need to know any coding language to grasp the basics of linedef specials in the source code. In most cases, it's rather easy to decipher. My main problem is that I don't quite know where to look for this. It's probably defined in "p_polyobj.c", but where?

EDIT: Uhh, guess I found it:

Quote:
//
// Polyobj_findExplicit
//
// Searches for segs to put into a polyobject in an explicitly provided order.
//
static void Polyobj_findExplicit(polyobj_t *po)
{
// temporary dynamic seg array
segitem_t *segitems = NULL;
size_t numSegItems = 0;
size_t numSegItemsAlloc = 0;

size_t i;

// first loop: save off all segs with polyobject's id number
for (i = 0; i < numsegs; ++i)
{
int polyID, parentID;

if (segs[i].linedef->special != POLYOBJ_EXPLICIT_LINE)
continue;

Polyobj_GetInfo(segs[i].linedef->tag, &polyID, &parentID, NULL);

if (polyID == po->id && parentID > 0)
{
if (numSegItems >= numSegItemsAlloc)
{
numSegItemsAlloc = numSegItemsAlloc ? numSegItemsAlloc*2 : 4;
segitems = realloc(segitems, numSegItemsAlloc*sizeof(segitem_t));
}
segitems[numSegItems].seg = &segs[i];
segitems[numSegItems].num = parentID;
++numSegItems;
}
}

// make sure array isn't empty
if (numSegItems == 0)
{
po->isBad = true;
CONS_Printf("polyobject %d is empty\n", po->id);
return;
}

// sort the array if necessary
if (numSegItems >= 2)
qsort(segitems, numSegItems, sizeof(segitem_t), Polyobj_segCompare);

// second loop: put the sorted segs into the polyobject
for (i = 0; i < numSegItems; ++i)
Polyobj_addSeg(po, segitems[i].seg);

// free the temporary array
free(segitems);
}
I haven't yet taken a look at it, but if someone can decipher this, it would be appreciated.

Last edited by MascaraSnake; 03-30-2010 at 04:23 PM.
MascaraSnake is offline   Reply With Quote
Old 03-30-2010   #7
SSNTails
What part of 'RETIRED' don't you understand?
 
SSNTails's Avatar
Default

Easy. See ZDoom/Hexen's documentation on the Explicit Polyobj line.
__________________
Roly Poly Putt & TraceRace - Now out for Android, iPhone, iPad, and iPod Touch - http://www.spaddlewit.com
Follow me on twitter: http://www.twitter.com/SSNTails
SSNTails is offline   Reply With Quote
Reply

Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
Fixed Linedef type 6 (Disable Linedef Effect) and No Sonic/No Tails/No Knuckles flags Ricardo Bug Reports (2.0.X) 0 09-08-2010 09:17 PM
Crumbling FOF types are broken Fawfulfan Bug Reports (2.0.X) 3 07-26-2010 09:46 PM
Invalid Linedef types 413, 423 and 424 not working Ricardo Bug Reports (2.0.X) 1 06-01-2010 11:37 AM
Linedef Types 900 through 909? Fawfulfan SRB2 Discussion 28 05-29-2010 02:18 PM
Inconsistencies in SRB2DB config linedef numbers and linedef categories Fawfulfan SRB2 Discussion 3 05-04-2010 08:16 PM


All times are GMT. The time now is 09:47 PM.


Powered by vBulletin® Version 3.8.7
Copyright ©2000 - 2018, vBulletin Solutions, Inc.