vb.org Archive

vb.org Archive (https://vborg.vbsupport.ru/index.php)
-   vBulletin 3.0 Beta Releases (https://vborg.vbsupport.ru/forumdisplay.php?f=34)
-   -   Rap Battle System -=RBS=- (https://vborg.vbsupport.ru/showthread.php?t=68161)

Durtay 08-11-2004 01:52 AM

Quote:

Originally Posted by Logik
Damnit...It doesnt add to the database for me. any help??

I'd help and all, but you still owe me $25

Logik 08-11-2004 02:07 AM

LMFAO...wow, u follow me.. Sad isnt it?

Logik 08-11-2004 03:56 AM

Bug: when u update one record in the user.php in admin cp, it updates all the records...and also it doesnt add the faveline to the database....

Liquid1ce 08-11-2004 04:04 AM

lol its just a modded poll no ? -

maybe there should be a option where the new user signs up to be a battler if he is then he gets the stats if not nothing

Liquid1ce 08-11-2004 05:41 AM

this is a addon why in major hacks forum lol

MindTrix 08-11-2004 10:12 AM

Wow some people are quick to hate arent they ;)

Every hack released is an add on because it edits/uses something in vb so what is your point? If you look at most rap battle hacks out there they also use the default poll for the battles, so why moan when you arent paying for this? If you want something that dont then go pay couple of hundred dollars for someone else to make you one.

MindTrix 08-11-2004 10:16 AM

Quote:

Originally Posted by Logik
Bug: when u update one record in the user.php in admin cp, it updates all the records...and also it doesnt add the faveline to the database....

The favourite lines DEFINETLY works i have it on my forum and some others so re-check the php edit and make sure the database query ran ok.

As for the user situation yes your correct, sorry about that.

In admincp/user.php find


PHP Code:

//RBS
 
if ( $bs_wins AND $bs_loses ) {
  
$DB_site->query("UPDATE " TABLE_PREFIX "user SET bs_wins = '".$bs_wins."', bs_loses = '".$bs_loses."'");
 }
//RBS 


and replace with

PHP Code:

//RBS
if ( $bs_wins AND $bs_loses ) {
$DB_site->query("UPDATE " TABLE_PREFIX "user SET bs_wins = '".$bs_wins."', bs_loses = '".$bs_loses."' WHERE userid = '".$userid."'");

}
//RBS 


That should sort it, sorry about that.

Logik 08-11-2004 07:24 PM

What PHP edit is it that i need to check for the fav line?

MindTrix 08-11-2004 07:27 PM

would be this piece

PHP Code:

 

*****************
Open NEWREPLY.PHP
*****************

Find
-----------------------------------------------
 
$newpost['stickunstick'] = $_POST['stickunstick'];
 
$newpost['openclose'] = $_POST['openclose'];
-----------------------------------------------
After add
-----------------------------------------------
//RBS
 
$newpost['favouriteline'] = $_POST['favouriteline'];
 if ( 
$newpost['favouriteline'] )
 {
  
$DB_site->query("INSERT INTO " TABLE_PREFIX "battlesys_favlines VALUES ('', '".$newpost['favouriteline']."', '".$bbuserinfo['username']."', '".$foruminfo['forumid']."')"); 
  
$newpost['message'] .= "[quote][i][b]Favourite Line:
  [/b][/i]"
.$newpost['favouriteline']."[/quote]";
 }
//RBS 


Logik 08-11-2004 07:29 PM

ok i will check that ina minute. When will the update come out? Like the top 10. I tried addin it, but i wasnt successful lol.

Logik 08-11-2004 07:37 PM

ok all problems solved.. Thanks :)

MindTrix 08-11-2004 07:37 PM

Why wasnt it succesfull?? Well erm its 9:30pm here andi gotta be up for work at ooooo 12am cause i work night shifts, errm i was coding a new hack earlier, so i might either carry that on tomorrow or work on some add ons for this. What would you want on the top 10 page? All i can think of is Top ten battles, which would go by reply rate or something, erm top ten viewed, top 10 emcees, Most recent made battle.... what else?

MindTrix 08-11-2004 07:38 PM

What went wrong? Did you not put the code in the right place or something?

Logik 08-11-2004 07:41 PM

No, i accidently replaced it with something else, i donno lol. I was tired. But uhm, them top 10 stats sound dope man... Thats all i can think of. That'd be nice if u could code that up, or give me the appropriate queries...Because i tried and i didnt do it lol.. all i get as an output is "array"

MindTrix 08-11-2004 07:42 PM

I'll look into it 2morro i guess. I hate html ;) Right now im off 2 bed lol. Glad you fixed the problem, And glad the problem was not a bug :) Let me know when you forums are up ;) I been checking for about 2 or 3 days now :p

Logik 08-11-2004 07:44 PM

iight :)... Will do.

Battle_Ring 08-12-2004 01:52 AM

IS There A Way To Change The Word Poll: To battles For The Battles Only And Not All Polls???
And Your Missing KO's....if that would be possible to add, Top 10 sounds nice...

MindTrix 08-12-2004 07:37 AM

Im not missing KO's, i just didnt add it ;) Should be a way to change it with an IF statement i would have guessed, ill try and look later.

DougCooper 08-12-2004 02:09 PM

Great work Trix ! two comments :

1: I agree it would be better to choose enter a battle instead of having a default 0-Wins beside your name if you arn't a battler.

2: Need ability to add audio, so the board mods can start a battle by uploading an instrumental, and then any battles can enter, upload there vocal version on the MP3, and therefore automatically be added to the poll and battle.

But anyway, good on you for getting the ball rolling ! UK all the way !

Battle_Ring 08-12-2004 03:04 PM

Also, is there a way to add this to more than one forum????

And can i change the word Poll: to Battle: when its a battle?

RMS-Chef 08-12-2004 05:09 PM

First, thanks for you work. I always appreciate anyone putting their valuable time into hacks.

I am interested in this, but for Image/PhotoShop Battles rather than rap/text.
There are a few things that are holding me back from an install though. Things I think would make this better:

1. Ability for group only to start battles, and hence the first person in the "first vs. second" also be editable and not always who is creating the battle. I was thinking something like having "referees" (basically mod group with battle admin powers) to set up battles and finalize. I realize that forum permissions could handle this with "can post new threads" but I don't think a 3rd person can set up a battle between 2 others.

2. Having a set amount of votes to win, I just don't think that is the best way to handle it and I believe this is the biggest shortcoming. It needs to have the ability to accept and tally votes until a mod/admin/ref closes the poll/battle, then the winner be determined.

3. Some way (maybe a pop-up memberlist) to make sure you are putting someone's correct username or maybe the option to use ID's instead? On a gaming ladder that I own, our webmaster has it so users can login with either name or ID so I am sure it could be done.

What happens if you set up a battle and use a non-existent username? When I tried, it let me with no errors.

Thanks again for the hack and I will follow diligently to see development.

MindTrix 08-12-2004 05:19 PM

Thank you for letting me know about battling someone with no username etc, will get onto that.

Umm as for the set amount of votes to win. As this is aimed at rap board, 99% of the time this is how battles are set out, a set amount of votes are determined and then the battle commences. The winner beeing the person to get the votes etc.



Erm that first thing you suggested sounded big and confusing to me :) Nice idea though.

The memberlist thing, yeah i see what you mean. Will have to find something i guess.

Thank you for the comments/suggestions

Logik 08-12-2004 05:19 PM

I have added the "Newest 3 Battles" to the forum home. Thanks to some coding i found around here. (no codes was stolen, i just got the "while" idea from another hack!)...Its up to Mindtrix if i can release the addon..

MindTrix 08-12-2004 05:23 PM

Quote:

Originally Posted by MindTrix
Hopefully some people will release some addons maybe :)

Would appreciate it if you did mate ;)

LostStyles 08-12-2004 05:45 PM

do they have this for vb2?

MindTrix 08-12-2004 06:16 PM

Some people have rap battle hacks for vB2 for sale, but none were ever released for free like this one

Liquid1ce 08-12-2004 06:42 PM

Is there a way to change so it says Battle: not poll for each battle

Durtay 08-12-2004 06:58 PM

Addon's I suggest (which we're already workin on at my forum):

1) KO Voting... this is pretty simple you just query all votes on one battle, and sort them by vote date... assign each a floating value... then the set amount for a KO (usually 3) would be: if vote 2 == vote 1 and vote 3 == vote 1 (if KO = 4 then it'd be if vote 2 == vote 1 and vote 3 == vote 1 and vote 4 == vote 1... etc)... and then put it into the user's database as a win and KO and lock the poll

another addon... polls always have cheaters (there's ways around IP Addresses to vote more than once), so to keep some cheaters out:

2) Cannot vote on polls (in battle forum) if less than 'x' amount of days registered or has less than 'x' amount of posts... again another easy hack

those are just two of the small hacks we're creating at STR Forums... just some idea's that others might want.

EDIT: also MindTrix what I suggest you do to change the coding is make it that the user creating the battle has to put in their opponent's forum ID number, that way there will be no confussion or mistakes when assigning win/loss values.

Logik 08-12-2004 11:06 PM

Look for:
Code:

// get permissions to view forumhome
if (!($permissions['forumpermissions'] & CANVIEW))
{
        print_no_permission();
}

And Below it add:
Code:

// 3 Newest Battles
$logik = $DB_site->query("SELECT replycount,title,threadid,lastpost,postusername,lastposter,views FROM thread WHERE forumid='X' ORDER BY lastpost DESC LIMIT 3");
while ($logiktop = mysql_fetch_array($logik)):
        ++$logiktopnbsp;
      $logikthread .= "<a href=showthread.php?s=$session[sessionhash]&threadid=$logiktop[threadid]>$logiktop[title]</a>&nbsp;<a href=showthread.php?s=$session[sessionhash]&goto=newpost&threadid=$logiktop[threadid]&goto=lastpost><font size=1><b>[View Unread]</b></font></a><br>";
           

endwhile;

change X to the forum number
And then in your ForumHome template look for:
Code:

$navbar
Now after that, add this:
Code:

<br>
<if condition="$bbuserinfo['userid']">
<table class="tborder" cellpadding="$stylevar[cellpadding]" cellspacing="$stylevar[cellspacing]" border="0" width="100%" align="center">
<tr>
<td class="thead" width="100%" valign="top">
<normalfont><b>Newest 3 Battles</b></normalfont></td>
</tr>
<tr><td>
$logikthread</td>
</tr>
</table>
</if>
<br>

Any problems, let me know.

Liquid1ce 08-13-2004 01:22 AM

@logik
what files to edit? newthread?

Logik 08-13-2004 01:22 AM

index.php, sorry..

RMS-Chef 08-13-2004 01:26 AM

Quote:

Erm that first thing you suggested sounded big and confusing to me Nice idea though.
Maybe I was complicating things. :)
Basicly, just make it so both Avs.B are open fields so that the person making the post does not have to participate in the battle.

I can already assign a battle forum and just allow my mods/admins to create new posts. But I would like to maintain control and have mods set up the battles between two other users.

So basicly, an quick work around would be.... Is there any way when creating a new battle to have a third user set up the battle between two other users?

Battle_Ring 08-13-2004 02:02 AM

Logik, Can We Get A Screenshot?

Battle_Ring 08-13-2004 02:04 AM

also, one problem i see, i have the store hack, when u post in the forum where the hack is, points do not go up

and you can vote for yourself....

and is there anyway possible to add this to more than one forum?

C.Birch 08-13-2004 08:43 AM

its killing everyday poll's for me

when voteing on a everyday poll you get the error screen, but your vote goes on the poll but it closes the poll.

error:

Database error in vBulletin 3.0.3:

Invalid SQL: UPDATE user SET bs_wins = bs_wins + 1 WHERE username = 'Who's David?'
mysql error: You have an error in your SQL syntax. Check the manual that corresponds to your MySQL server version for the right syntax to use near 's David?'' at line 1

mysql error number: 1064

Date: Friday 13th of August 2004 10:23:25 AM
Script: http://community.ultimate-music.net/poll.php
Referer: http://community.ultimate-music.net/...06257&posted=1
Username: CarlBirch
IP Address: 217.43.193.87

i have removed the edit from poll.php for now.

Liquid1ce 08-13-2004 09:02 AM

lol im waiting on the guy who says he got one for $100

MindTrix 08-13-2004 10:39 AM

Well, ive thought about it, and ill post bug fixes etc but ive decided not to bother with everything else. This was something everyone wanted, so a newbie tried it out and everyone moans ;) So as far as im concerned now if you dont like it, then go and spend your $100 or $200 or whatever to have one made for you.

Cant expect greatness for free so as i said, ill post bug fixes etc but thats it.

Battle_Ring 08-13-2004 02:22 PM

Oh Im appreciative....im just trying to let u know the problems, so u can fix them if you would like...

LostStyles 08-13-2004 03:09 PM

ye it is very nice of u, i would go to vb3 just to have it but vb3 offers real bad skins and it has a bad layout, do u think maybe u can make this vb2?

Logik 08-13-2004 07:15 PM

No screen shot needed, it just shows newest 3 battles.


All times are GMT. The time now is 10:08 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.01500 seconds
  • Memory Usage 1,839KB
  • 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
  • (4)bbcode_code_printable
  • (3)bbcode_php_printable
  • (4)bbcode_quote_printable
  • (1)footer
  • (1)gobutton
  • (1)header
  • (1)headinclude
  • (6)option
  • (1)pagenav
  • (1)pagenav_curpage
  • (3)pagenav_pagelink
  • (1)post_thanks_navbar_search
  • (1)printthread
  • (40)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