vb.org Archive

vb.org Archive (https://vborg.vbsupport.ru/index.php)
-   vBulletin 3.8 Add-ons (https://vborg.vbsupport.ru/forumdisplay.php?f=235)
-   -   Major Additions - Forum Tournaments & Ladders (https://vborg.vbsupport.ru/showthread.php?t=189375)

Jaxel 02-09-2009 03:08 AM

tmnt_shell:
Code:

$stylevar[htmldoctype]
<html xmlns="http://www.w3.org/1999/xhtml" dir="$stylevar[textdirection]" lang="$stylevar[languagecode]">
<head>
$headinclude
<title>$vboptions[bbtitle] - $pagetitle</title>
<if condition="$_REQUEST['do'] == 'view' OR $_REQUEST['do'] == 'edit' OR $_REQUEST['do'] == 'viewteam' OR $_REQUEST['do'] == 'viewannouncement'">
<script language="javascript" type="text/javascript">
function deletetmnt(id, title)
{
        if (confirm("Are you sure you want to delete '" + title + "'")) {
                window.location.href = '?do=kill&id=' + id;
        }
}
function deleteteam(id)
{
        if (confirm("Are you sure you want to delete this team?")) {
                window.location.href = '?do=killteam&id=' + id;
        }
}
function deleteann(id)
{
        if (confirm("Are you sure you want to delete this announcement?")) {
                window.location.href = '?do=killann&id=' + id;
        }
}
function jointeam(id)
{
        if (confirm("Are you sure you want to join this team?")) {
                window.location.href = '?do=reqjointeam&id=' + id;
        }
}
function rejectrecruit(id)
{
        if (confirm("Are you sure you want to reject this recruit?")) {
                window.location.href = '?do=rejectrecruit&id=' + id;
        }
}
function confirmrecruit(id)
{
        if (confirm("Are you sure you want to confirm this recruit?")) {
                window.location.href = '?do=confirmrecruit&id=' + id;
        }
}
function deleteplayer(id, tid, userid)
{
        if (confirm("Are you sure you remove this player from this tournament?")) {
                window.location.href = '?do=killplayer&id=' + id + '&tid=' + tid + '&userid=' + userid;
        }
}
function deleteteamplayer(id)
{
        if (confirm("Are you sure you want to remove this player from your team?")) {
                window.location.href = '?do=killteamplayer&id=' + id;
        }
}
function makeleader(id)
{
        if (confirm("Are you sure you want to make this team member a leader?")) {
                window.location.href = '?do=makeleader&id=' + id;
        }
}
function makecoleader(id)
{
        if (confirm("Are you sure you want to make this team player a co-leader?")) {
                window.location.href = '?do=makecoleader&id=' + id;
        }
}
function deletecomment(id, tid, userid)
{
        if (confirm("Are you sure you want to delete this comment?")) {
                window.location.href = '?do=killcomment&id=' + id + '&tid=' + tid +'&userid=' + userid;
        }
}
function finishtmnt(id, title, topscore)
{
        if (confirm("Are you sure you want to finish '" + title + "'")) {
                window.location.href = '?do=finish&id=' + id + '&topscore=' + topscore;
        }
}
function progress(id, userid, username, round, slot)
{
        if (confirm("Are you sure you want to progress '" + username + "' to next round?")) {
                window.location.href = '?do=progress&id=' + id + '&userid=' + userid + '&round=' + round + '&slot=' + slot;
        }
}
function regress(id, userid, username, round)
{
        if (confirm("Are you sure you want to regress '" + username + "' to previous round?")) {
                window.location.href = '?do=progress&id=' + id + '&userid=' + userid + '&round=' + round + '&slot=0';
        }
}
function progressfinish(id, userid, username, round, slot)
{
        if (confirm("Are you sure you want to progress '" + username + "' to next round?")) {
                window.location.href = '?do=progressfinish&id=' + id + '&userid=' + userid + '&round=' + round + '&slot=' + slot;
        }
}
function showhide(value, divid)
{
        if (value=="1") {
                document.getElementById(divid).style.display=""
        }
        if (value=="0")
        {
                document.getElementById(divid).style.display="none"
        }
}
</script>
</if>
$memberinfo_css
</head>
<body>
$header
$navbar
<div class="vbmenu_popup" id="tmntnew_menu" style="display:none">
<table cellpadding="4" cellspacing="1" border="0">
                <tr>
            <td class="thead">$vbphrase[new]...</td>
                </tr>
        <if condition="$cancreateteam"><tr>
            <td class="vbmenu_option"><a href="competitions.php?do=addteam">$vbphrase[tmnt_newteam_short]</a></td>
                </tr></if>
                <if condition="$canedittmnt"><tr>
            <td class="vbmenu_option"><a href="competitions.php?do=addannouncement">$vbphrase[tmnt_newannouncement]</a></td>
        </tr></if>
                <if condition="$cancreateladder"><tr>
                        <td class="vbmenu_option"><a href="competitions.php?do=addladder">$vbphrase[tmnt_newladder]</a></td>
                </tr></if>
                <if condition="$cancreatetmnt"><tr>
                        <td class="vbmenu_option"><a href="competitions.php?do=addtmnt">$vbphrase[tmnt_newtmnt]</a></td>
                </tr></if>
</table>
</div>
<div class="vbmenu_popup" id="tmntnmt_menu" style="display:none">
<table cellpadding="4" cellspacing="1" border="0">
                <tr>
            <td class="thead">$vbphrase[tmnts]</td>
                </tr>
        <tr>
            <td class="vbmenu_option"><a href="competitions.php?do=tournaments">$vbphrase[tmnt_tmntlist]</a></td>
                </tr>
                <tr>
            <td class="vbmenu_option"><a href="competitions.php?do=tournaments&amp;filter=1">$vbphrase[tmnt_showwaiting]</a></td>
                </tr>
                <tr>
            <td class="vbmenu_option"><a href="competitions.php?do=tournaments&amp;filter=2">$vbphrase[tmnt_showinprogress]</a></td>
                </tr>
                <tr>
            <td class="vbmenu_option"><a href="competitions.php?do=tournaments&amp;filter=3">$vbphrase[tmnt_showfinished]</a></td>
                </tr>
                <tr>
            <td class="vbmenu_option"><a href="competitions.php?do=hof">$vbphrase[tmnt_hof_short]</a></td>
                </tr>
                <if condition="$cancreatetmnt"><tr>
                        <td class="vbmenu_option"><a href="competitions.php?do=addtmnt">$vbphrase[tmnt_newtmnt]</a></td>
                </tr></if>
</table>
</div>
<div class="vbmenu_popup" id="tmntlmt_menu" style="display:none">
<table cellpadding="4" cellspacing="1" border="0">
                <tr>
            <td class="thead">$vbphrase[ladders]</td>
                </tr>
                <tr>
            <td class="vbmenu_option"><a href="competitions.php?do=ladders">$vbphrase[ladder_list]</a></td>
        </tr>
                <tr>
            <td class="vbmenu_option"><a href="competitions.php?do=ladderchallenges">$vbphrase[ladder] $vbphrase[ladder_chlls]</a></td>
        </tr>
                <if condition="$cancreateladder"><tr>
                        <td class="vbmenu_option"><a href="competitions.php?do=addladder">$vbphrase[tmnt_newladder]</a></td>
                </tr></if>
</table>
</div>

<if condition="$vboptions[tmnt_navtop]==1">
<table class="tborder" width="100%" align="center" border="0" cellpadding="$stylevar[cellpadding]" cellspacing="$stylevar[cellspacing]">
        <tbody><tr align="center">
                <td class="vbmenu_control"><a href="competitions.php?">$modname</a></td>
                <td class="vbmenu_control"><a href="competitions.php?do=announcements">$vbphrase[announcements]</a></td>
                <td class="vbmenu_control"><a href="competitions.php?do=rules">$vbphrase[tmnt_rules]</a></td>
                <td class="vbmenu_control" id="tmntnmt">$vbphrase[tmnts] <script type="text/javascript">vbmenu_register("tmntnmt");</script></td>
        <if condition="$canviewladder">
                <td class="vbmenu_control" id="tmntlmt">$vbphrase[ladders] <script type="text/javascript">vbmenu_register("tmntlmt");</script></td>
        </if>
                <td class="vbmenu_control"><a href="competitions.php?do=teams">$vbphrase[tmnt_teamlist]</a></td>
        <if condition="$cancreateteam OR $cancreatetmnt OR $canedittmnt OR $cancreateladder">
                <td id="tmntnew" class="vbmenu_control">$vbphrase[new] <script type="text/javascript">vbmenu_register("tmntnew");</script></td>
        </if>
        </tr>
        </tbody>
</table>
<br />
</if>

<table width="100%" border="0" cellspacing="0" cellpadding="0">
<tr> <if condition="$vboptions[tmnt_navleft]==1">
<td valign="top" width="150" align="left">
<table class="tborder" width="140" border="0" cellpadding="$stylevar[cellpadding]" cellspacing="$stylevar[cellspacing]">
                <tr>
          <td class="tcat">$modname</td>
        </tr>
                <tr>
          <td class="thead">$vbphrase[tmnt_general]</td>
        </tr>
                <tr>
            <td class="alt2 smallfont" nowrap="nowrap"><a href="competitions.php?do=announcements">$vbphrase[announcements]</a></td>
          </tr>
                  <tr>
            <td class="alt2 smallfont" nowrap="nowrap"><a href="competitions.php?do=rules">$vbphrase[tmnt_rules]</a></td>
          </tr>
                  <tr>
            <td class="alt2 smallfont" nowrap="nowrap"><a href="competitions.php?do=teams">$vbphrase[tmnt_teamlist]</a></td>
          </tr>
                  <tr>
          <td class="thead">$vbphrase[tmnts]</td>
        </tr>
                  <tr>
            <td class="alt2 smallfont">
<table width="100%" border="0" cellspacing="0" cellpadding="0" class="smallfont">
  <thead>
  <tr>
    <td height="20" colspan="2" class="smallfont" style="padding-bottom: 4px;">
        <a href="#top" onclick="return toggle_collapse('tmnt_displayoptions')"><img id="collapseimg_tmnt_displayoptions" src="$stylevar[imgdir_button]/collapse_alt_collapsed.gif" class="inlineimg" alt="" border="0" /></a>
        <a href="competitions.php?do=tournaments">$vbphrase[tmnt_tmntlist]</a></td>
  </tr>
  </thead>
  <tbody id="collapseobj_tmnt_displayoptions" style="display: none;">
  <tr>
    <td width="22" align="left" valign="top" style="background: url($stylevar[imgdir_misc]/tree_i.gif) repeat-y left top"><img style="width: 20px; height: 20px;" src="$stylevar[imgdir_misc]/tree_t.gif" alt="" class="inlineimg" border="0" /></td>
    <td align="left" valign="top" class="smallfont" style="padding-bottom: 4px;"><a href="competitions.php?do=tournaments&amp;filter=1">$vbphrase[tmnt_showwaiting]</a></td>
  </tr>
  <tr>
    <td width="22" align="left" valign="top" style="background: url($stylevar[imgdir_misc]/tree_i.gif) repeat-y left top"><img style="width: 20px; height: 20px;" src="$stylevar[imgdir_misc]/tree_t.gif" alt="" class="inlineimg" border="0" /></td>
    <td align="left" valign="top" class="smallfont" style="padding-bottom: 2px;"><a href="competitions.php?do=tournaments&amp;filter=2">$vbphrase[tmnt_showinprogress]</a></td>
  </tr>
  <tr>
    <td width="22" height="20" align="left" valign="top"><img style="width: 20px; height: 20px;" src="$stylevar[imgdir_misc]/tree_ltr.gif" alt="" class="inlineimg" border="0" /></td>
    <td align="left" valign="top" class="smallfont"><a href="competitions.php?do=tournaments&amp;filter=3">$vbphrase[tmnt_showfinished]</a></td>
  </tr>
  </tbody>
</table>
</td>
          </tr>
                  <tr>
            <td class="alt2 smallfont" nowrap="nowrap"><a href="competitions.php?do=hof">$vbphrase[tmnt_hof_short]</a></td>
          </tr>
                  <if condition="$canviewladder">
                  <tr>
          <td class="thead">$vbphrase[ladders]</td>
        </tr>
                  <tr>
            <td class="alt2 smallfont" nowrap="nowrap"><a href="competitions.php?do=ladders">$vbphrase[ladder_list]</a></td>
          </tr>
                  <tr>
            <td class="alt2 smallfont" nowrap="nowrap"><a href="competitions.php?do=ladderchallenges">$vbphrase[ladder] $vbphrase[ladder_chlls]</a></td>
          </tr>
                  </if>
                  <if condition="$cancreateteam OR $cancreatetmnt OR $canedittmnt OR $cancreateladder">
                  <tr>
            <td class="tcat" nowrap="nowrap">$vbphrase[tmnt_modmenu]</td>
          </tr>
                  <if condition="$cancreateteam">
                  <tr>
            <td class="alt2 smallfont" nowrap="nowrap"><a href="competitions.php?do=addteam">$vbphrase[tmnt_newteam_short]</a></td>
          </tr>
                  </if>
                  <if condition="$canedittmnt">
                  <tr>
            <td class="alt2 smallfont" nowrap="nowrap"><a href="competitions.php?do=addannouncement">$vbphrase[tmnt_newannouncement]</a></td>
          </tr>
                  </if>
                  <if condition="$cancreateladder">
                  <tr>
            <td class="alt2 smallfont" nowrap="nowrap"><a href="competitions.php?do=addladder">$vbphrase[tmnt_newladder]</a></td>
          </tr>
                  </if>
                  <if condition="$cancreatetmnt">
                  <tr>
            <td class="alt2 smallfont" nowrap="nowrap"><a href="competitions.php?do=addtmnt">$vbphrase[tmnt_newtmnt]</a></td>
          </tr>
                  </if>
                  </if>
</table>
</td></if>
<td valign="top" align="left">$tlhtml</td>
</tr>
</table>
<br />

<div class="smallfont" align="center"> <a href="https://vborg.vbsupport.ru/misc.php?do=producthelp&amp;pid=tournament2008">Tournament &amp; Ladder Script</a> $tmnt_version Copyright by <a href="https://vborg.vbsupport.ru/member.php?u=223075"> BananaLive </a> </div>

$footer
</body>
</html>


Jaxel 02-09-2009 08:45 AM

Something new...

Brackets look weird in Internet Explorer... they look fine in Firefox.

OneShot 02-09-2009 10:39 AM

I'm getting an error when I open up a closed tournament ...
Quote:

Warning: getimagesize(http://url/misc/unknown.gif) [function.getimagesize]: failed to open stream: no suitable wrapper could be found in [path]/competitions.php on line 3657

Stifmeister2 02-09-2009 01:59 PM

Bananalive, I refer to this post, would it be easy to do??


Basically what I mean is that when you create a tournament, you can choose if the tourmanent is public or private. They are the same, with the exception that private tournaments do not add stats to Hall of Fame. We need this very bad on our forums... :rolleyes: :o

bananalive 02-09-2009 01:59 PM

Quote:

Originally Posted by Jaxel (Post 1738067)
Well thats what its supposed to do... thats exactly what I was saying...

With 17 players, the system should AUTOMATICALLY add 15 bye players. However, you need to stratify these byes; so that byes don't end up playing against byes.

Also... new bug... http://www.8wayrun.com/competitions.php?do=view&id=14 (comments section)

Its evident that the comment section of TNMT is taking the design of the comments section from the Pictures & Album design. However, the pictures & album section pulls avatars from the /avatars/thumbs/ folder; not the /avatars/ folder. In the /avatars/thumbs/ folder, avatars are automatically restricted to 60 pixels; since you are not drawing from this folder; the avatars are not being restricted in size. So if you look at the comment section, you will see some of the avatars overlapping.

Also... in beta3... create new tournament... 4 is listed twice in number of players.

For comments bug...
Line 2283 should be:
PHP Code:

        if ($vbulletin->options[simpleversion] >= 370


bananalive 02-09-2009 02:04 PM

Quote:

Originally Posted by Jaxel (Post 1738317)
Why do all your templates have the timecodes set to 1969? I make a lot of changes to the templates because you make some odd choices with the layout. So I have been working to fix these changes. However, since you always set your timecodes to 1969; I never know when YOU make an update to the template, thus prompting me to update my changes. So when you update your templates, I wont ever know, and I'll always be using the old tempaltes. I jsut made a post asking if you were ever going to update the top-nav bar; because it was outdated... turns out, you DID update the top-nav bar, but it was dated 40 years old, so vB never notified me. This is a MAJOR oversight that you should take care of.

I don't code inside vbulletin so the time code will be 0 which is 1969/1970 (depending on timezones)

bananalive 02-09-2009 02:05 PM

Quote:

Originally Posted by OneShot (Post 1738579)
I'm getting an error when I open up a closed tournament ...

url_fopen() is disabled in your php.ini

bananalive 02-09-2009 02:08 PM

Quote:

Originally Posted by Jaxel (Post 1738256)
On a further note you dont need that many options for numbers of players... you only really need the following:

2
4
8
16
32
64
128
256

A single/double elim tournament should never be run off of a non-multiple of 2; especially if you aren't stratifying byes.

Also, I know I can create a tournament with 256 players with Beta3, but does it actually work? I noticed that in the database, it only has till ROUND7 on the players table, which would be enough for 64 players. For 256 players, you would need up to ROUND9. So if I made a tournament with 256 players, would it work? Or would it be broken?

It's not been tested. I'll add in those columns.

Jaxel 02-09-2009 02:09 PM

I dont program in vbulletin either... but I make sure to update my timestamps...

You can get the current timestamp from here: http://www.timestampgenerator.com/

Just click the NOW button in the Reverse Timestamp Generator section.

These timestamps are EXTREMELY IMPORTANT.

bananalive 02-09-2009 02:10 PM

Quote:

Originally Posted by Stifmeister2 (Post 1738686)
Bananalive, I refer to this post, would it be easy to do??


Basically what I mean is that when you create a tournament, you can choose if the tourmanent is public or private. They are the same, with the exception that private tournaments do not add stats to Hall of Fame. We need this very bad on our forums... :rolleyes: :o

It'll require quite a few edits. As the hall of fame statistics are integrated with several actions.


All times are GMT. The time now is 04:38 AM.

Powered by vBulletin® Version 3.8.12 by vBS
Copyright ©2000 - 2025, vBulletin Solutions Inc.

X vBulletin 3.8.12 by vBS Debug Information
  • Page Generation 0.02325 seconds
  • Memory Usage 1,852KB
  • Queries Executed 10 (?)
More Information
Template Usage:
  • (1)ad_footer_end
  • (1)ad_footer_start
  • (1)ad_header_end
  • (1)ad_header_logo
  • (1)ad_navbar_below
  • (1)bbcode_code_printable
  • (1)bbcode_php_printable
  • (6)bbcode_quote_printable
  • (1)footer
  • (1)gobutton
  • (1)header
  • (1)headinclude
  • (6)option
  • (1)pagenav
  • (1)pagenav_curpage
  • (4)pagenav_pagelink
  • (5)pagenav_pagelinkrel
  • (1)post_thanks_navbar_search
  • (1)printthread
  • (10)printthreadbit
  • (1)spacer_close
  • (1)spacer_open 

Phrase Groups Available:
  • global
  • postbit
  • showthread
Included Files:
  • ./printthread.php
  • ./global.php
  • ./includes/init.php
  • ./includes/class_core.php
  • ./includes/config.php
  • ./includes/functions.php
  • ./includes/class_hook.php
  • ./includes/modsystem_functions.php
  • ./includes/class_bbcode_alt.php
  • ./includes/class_bbcode.php
  • ./includes/functions_bigthree.php 

Hooks Called:
  • init_startup
  • init_startup_session_setup_start
  • init_startup_session_setup_complete
  • cache_permissions
  • fetch_threadinfo_query
  • fetch_threadinfo
  • fetch_foruminfo
  • style_fetch
  • cache_templates
  • global_start
  • parse_templates
  • global_setup_complete
  • printthread_start
  • pagenav_page
  • pagenav_complete
  • bbcode_fetch_tags
  • bbcode_create
  • bbcode_parse_start
  • bbcode_parse_complete_precache
  • bbcode_parse_complete
  • printthread_post
  • printthread_complete