vb.org Archive

vb.org Archive (https://vborg.vbsupport.ru/index.php)
-   vBulletin 2.x Full Releases (https://vborg.vbsupport.ru/forumdisplay.php?f=4)
-   -   Pickpocket in Lesane Store (https://vborg.vbsupport.ru/showthread.php?t=38383)

Roxie 05-20-2002 12:55 PM

I don't understand what you mean by "which userid="GODFATHERID".

This is a great hack by the way if I could get it to work correctly.

GenSec 05-20-2002 01:11 PM

Quote:

Originally posted by Roxie
I don't understand what you mean by "which userid="GODFATHERID".

This is a great hack by the way if I could get it to work correctly.

After you registered user GODFATHER, you will know his userid and replace "GODFATHERID" in hack to this number (say 13435 as your userid on vbulletin.org).

Roxie 05-20-2002 01:14 PM

ahhhhh...okay. That makes sense now, let me try! :D

Roxie 05-20-2002 01:46 PM

when my users try to steal they get a blank page. :(
it just says vbulletin message, but nothing is there.

GenSec 05-20-2002 02:04 PM

Quote:

Originally posted by Roxie
when my users try to steal they get a blank page. :(
it just says vbulletin message, but nothing is there.

I guess It means you haven't one of the templates. Let me link please to look for your problem

Roxie 05-20-2002 02:10 PM

here is my board http://www2.cyberpixels.com/~dayum/odb/index.php?

Will you be able to see it without registering.
clicking insurance and godfather also gives blank page.
I have added all the templates using the template hack.

Roxie 05-20-2002 02:20 PM

GOT IT WORKING! Sorry I am such a dunce. yay! Thanks for your time! This hack rocks!

Roxie 05-20-2002 03:30 PM

argh! Now the only problem I have is that it won't let me steal. It always says I am too young. I have it set so that the thief has to have at least $5. I have that and it still won't let me steal. :(

GenSec 05-20-2002 03:44 PM

Quote:

Originally posted by Roxie
argh! Now the only problem I have is that it won't let me steal. It always says I am too young. I have it set so that the thief has to have at least $5. I have that and it still won't let me steal. :(
There is a limit:
Quote:

if ($bbuserinfo[posts]<100 ) { // don't allow new users to steal -- they need to have more than 100 posts!
It's from my board exptrience.
User need to have 100 posts before to steal.
Because some users can create special new account to steal!
You can change it.

Roxie 05-20-2002 04:02 PM

The only line that is similar to that is :

if ($bbuserinfo[posts]<100) { // don't allow new users to steal -- they need to have more than $100!

I changed to 5, still not working.

GenSec 05-20-2002 04:20 PM

Quote:

Originally posted by Roxie
The only line that is similar to that is :

Quote:

if ($bbuserinfo[posts]<5 {
// don't allow new users to steal -- they need to have more than $100!

I changed to 5, still not working.

Did you change it to
Quote:

if ($bbuserinfo[posts]<5) {
in both two places?

Roxie 05-20-2002 05:07 PM

This is what I have:

Quote:

// ###################### Start steal Lookup ###########
if ($action=="steal") {
if ($bbuserinfo[posts]<50) { // victim should have more than $50
eval("standarderror(\"".gettemplate('store_steal_c annot')."\");");
}
$contest = $DB_site->query_first("SELECT * FROM store WHERE action='steal'");
$storeid=$contest[id];
$title=$contest[title];
$cost=$contest[costs];
eval("dooutput(\"".gettemplate("store_steal_lookup ")."\");");
}
// ###################### Start steal How Much? #######################
if ($action=="stealmoney") {
if ($bbuserinfo[posts]<5) { // don't allow new users to steal -- they need to have more than $100!
eval("standarderror(\"".gettemplate('store_steal_c annot')."\");");
}
$getduser=$DB_site->query_first("SELECT userid,usertitle,username,storep,usergroupid FROM user WHERE username='".addslashes(htmlspecialchars($stealuser name))."'");
if ($getduser[storep]<50) { // victim should have more than $100
eval("standarderror(\"".gettemplate('store_steal_p oor')."\");");
}
if ($getduser[usergroupid]=="6") { // don't steal from admin
eval("standarderror(\"".gettemplate('store_givetit le_noadmin')."\");");
}
if (empty($getduser[username])) {
eval("standarderror(\"".gettemplate('store_donate_ dontexist')."\");");
}
else {
$storeadmin = $DB_site->query_first("SELECT * FROM storeadmin");
$storename=$storeadmin[storename];
$pointname=$storeadmin[pointname];
$contest = $DB_site->query_first("SELECT * FROM store WHERE action='steal'");

eval("dooutput(\"".gettemplate("store_steal_money" )."\");");
}
}


GenSec 05-20-2002 05:20 PM

Roxie
I'm on your board
Let's tune it right there

ULTIMATESSJ 05-20-2002 06:06 PM

i'm still getting this error

Database error in vBulletin 2.2.5:

Invalid SQL: UPDATE user SET storep=storep-100,KARMA=KARMA-20 WHERE userid='1'
mysql error: Unknown column 'KARMA' in 'field list'

mysql error number: 1054

Date: Monday 20th of May 2002 03:03:52 PM
Script: http://www.animexplosion.com/forums/forums/store.php
Referer: http://www.animexplosion.com/forums/store.php

I have the karma hack installed

GenSec 05-20-2002 06:12 PM

Quote:

Originally posted by ULTIMATESSJ
i'm still getting this error

Database error in vBulletin 2.2.5:

Invalid SQL: UPDATE user SET storep=storep-100,KARMA=KARMA-20 WHERE userid='1'
mysql error: Unknown column 'KARMA' in 'field list'

mysql error number: 1054

Date: Monday 20th of May 2002 03:03:52 PM
Script: http://www.animexplosion.com/forums/forums/store.php
Referer: http://www.animexplosion.com/forums/store.php

I have the karma hack installed

Do you have in user table the field "KARMA"?

ULTIMATESSJ 05-20-2002 08:13 PM

Quote:

Originally posted by GenSec

Do you have in user table the field "KARMA"?

if u mean in phpmyadmin, no i don't

GenSec 05-21-2002 05:18 AM

Then use nokarma version.
There are a lot of karma hacks. In my case table user includes field with name KARMA. If you have any other similar field (points, rating... etc.) try to change KARMA to this one.

ULTIMATESSJ 05-21-2002 02:26 PM

Quote:

Originally posted by GenSec
Then use nokarma version.
There are a lot of karma hacks. In my case table user includes field with name KARMA. If you have any other similar field (points, rating... etc.) try to change KARMA to this one.

can you explain what i gotta do then, sorry bout this but i am a compete newbie at this stuff

GenSec 05-21-2002 02:56 PM

Just delete
PHP Code:

,KARMA=KARMA-$priz 

everywhere from queries.

Or try to find in your karma hack what field was added to user table. Look instrustions to your hack.

Roxie 05-21-2002 10:11 PM

All of a sudden it stopped working for me. It let's me put in the name to steal from but then it says I am too young> :(

GenSec 05-22-2002 05:14 AM

Roxie. Email me your php text I try to look what's wrong

Roxie 05-23-2002 03:43 PM

GenSec, now it works for me, but not any of my members. This is really odd. lol

GenSec 05-24-2002 06:48 AM

What can I say? Roxie. I don't see any error in php I send you.
Check one more what is store.php on server.
Two lines:
if ($bbuserinfo[posts]<5)

Roxie 05-24-2002 10:43 AM

It seems that even though it says 5, it will only let users with 100 or more posts steal. I'll try to figure it out or I'll just leave it at 100. Thanks for looking at it for me.

wintz 05-24-2002 12:31 PM

When i try to steal i get the below error

Invalid SQL: INSERT INTO privatemessage (privatemessageid,userid,touserid,fromuserid,title ,message,dateline,showsignature,iconid,messageread ,folderid,receipt) VALUES (NULL,64,64,DMINID,'Crime','Toby!

Sorry, you were robed for the sum 50.


Quote:

It was very smart robbery! We didn\'t take them.
',1022246379,'Case-Sensitive Forums','',0,0,0)
mysql error: Unknown column 'DMINID' in 'field list'

mysql error number: 1054


any ideas how to fix this? thanks

Blue2000 05-26-2002 03:57 AM

you know what would make this addon better

when the godfather, insurance or adminid pms you it also adds in the pm who tryed to rob from them .. ;) this would start little wars and could be fun

Blue2000 05-26-2002 06:12 AM

also how would i add a new button near users nicks that appears under called "ROB ME": this way we all will live in a more dangerouse!!! real time robbering while u r reading a post... and without going to the shop :P

Blue2000 05-26-2002 06:14 AM

Quote:

Originally posted by wintz
When i try to steal i get the below error

Invalid SQL: INSERT INTO privatemessage (privatemessageid,userid,touserid,fromuserid,title ,message,dateline,showsignature,iconid,messageread ,folderid,receipt) VALUES (NULL,64,64,DMINID,'Crime','Toby!

Sorry, you were robed for the sum 50.


',1022246379,'Case-Sensitive Forums','',0,0,0)
mysql error: Unknown column 'DMINID' in 'field list'

mysql error number: 1054


any ideas how to fix this? thanks

you need to set DMINID to your admin id in the command.

the info to installed missed out the A on a few lines

wintz 05-26-2002 07:13 AM

Thanks for the reply but i`m not sure what you mean and where would i make the changes? thanks

Blue2000 05-26-2002 07:57 AM

ok find your admin userid

should be 2

hover over your profile file link in any of "your" posts and look at the buttom of ie

you should see somthing like

https://vborg.vbsupport.ru/member.ph...fo&userid=8741

make a note of that id

then in the instuctions.txt

find

// change ADMINID (should be in it twice)

in that line you will see DMINID just after NULL,$usid,$usid,

remove dminid and put in your admin id you made a note of before.

so you finished line should look like this

VALUES (NULL,$usid,$usid,2,'Crime','".addslashes($message)."',".time().",'$b btitle','',0,0,0)"); // change ADMINID

wintz 05-26-2002 08:12 AM

Thanks alot m8, looks like thats sorted it ;)

Blue2000 05-26-2002 08:12 PM

Quote:

Originally posted by Blue2000
also how would i add a new button near users nicks that appears under called "ROB ME": this way we all will live in a more dangerouse!!! real time robbering while u r reading a post... and without going to the shop :P
ok i have done this one myself..

for anyone who wants it


find in functions.php

PHP Code:

    if (($bbuserinfo[usergroupid]==6)) {
        
$donate="<br><a href=\"javascript:showwin('admin/storeadmin.php?action=givemoneyverify&giveusername=$post[username]', 'width=550,height=250')\">Donate to user</a>";
    } else {
        
$donate='';
    } 

add under

PHP Code:

$nick="<a href=\"javascript:showwin('store.php?action=stealmoney&stealusername=$post[username]', 'width=550,height=550')\">Try to steal $$</a>"

and then add

$nick

anywhere you want it in your postbit template

Blue2000 05-26-2002 08:13 PM

Quote:

Originally posted by Blue2000
you know what would make this addon better

when the godfather, insurance or adminid pms you it also adds in the pm who tryed to rob from them .. ;) this would start little wars and could be fun


i still need help with this please if anyone can.

GenSec 05-27-2002 07:30 AM

Quote:

Originally posted by Blue2000



i still need help with this please if anyone can.

Just change your message template to
PHP Code:

[B]$stealusername![/B] [B]Sorryyou were robed by $bbuserinfo[username] for the sum $robber. [/B] [quote]It was very smart robberyWe didn't take them. [/quote] 

$bbuserinfo[username] is name of the robber.

Blue2000 05-27-2002 02:10 PM

doh!

thanks alot GenSec for you reply it works :)

cant belaeve it was that easy :P

Blue2000 05-27-2002 02:16 PM

i just had another idea... dont think i can do it but anyway..

why not another addon police addon

you have to bribe the police which will cost about $500 and someone trys to rob from you.. and they fail you get the money they tryed to rob. rather than the money just getting droped from the board. :)

GenSec 05-29-2002 08:50 AM

Quote:

Originally posted by Blue2000
i just had another idea... dont think i can do it but anyway..

why not another addon police addon

you have to bribe the police which will cost about $500 and someone trys to rob from you.. and they fail you get the money they tryed to rob. rather than the money just getting droped from the board. :)

It's simple. You can tune police, mafia, insurance etc. rules
I didn't understand your case economics. Police get $500 from user. Ok. Who pay to user? What is a source of money? ;)

Blue2000 05-29-2002 06:16 PM

the way it is now when a member trys to rob from another member and fails the money gets taken off that member.

and thats that.

But if the member who you tryed to rob from as insurance "police" the money you tryed to rob goes to that user

somthing like

if ($victim[insurance]!=' police"

$DB_site->query("UPDATE user SET storep=storep+$robber WHERE userid=$usid");

but only when they robbery fails.

if you still not to sure what i mean i can try and make this hack and post the code.

Also i have another porblem. is there a way to stop somone from robbing from themselfs?

thanks for all your help

GenSec 05-30-2002 07:05 AM

Quote:

Originally posted by Blue2000
Also i have another porblem. is there a way to stop somone from robbing from themselfs?

thanks for all your help

Find line which stops robbing from admin and add there someone you want to protect
Code:

  if ($getduser[usergroupid]=="6" OR $getduser[userid]==$bbuserinfo[userid] OR $getduser[userid]=="GODFATHERid" OR $getduser[userid]=="INSURANCEid") {
:glasses:

Blue2000 05-31-2002 01:21 AM

cheers dude


All times are GMT. The time now is 12:13 PM.

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.01529 seconds
  • Memory Usage 1,844KB
  • 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
  • (4)bbcode_php_printable
  • (18)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