Go Back   vb.org Archive > vBulletin Modifications > Archive > vB.org Archives > vBulletin 3.5 > vBulletin 3.5 Add-ons

Reply
 
Thread Tools
Dice Roller Hack [BBCode] Details »»
Dice Roller Hack [BBCode]
Version: 1.00, by Eikinskjaldi Eikinskjaldi is offline
Developer Last Online: Jul 2023 Show Printable Version Email this Page

Version: 3.5.4 Rating:
Released: 04-24-2006 Last Update: 05-29-2006 Installs: 51
DB Changes Uses Plugins Template Edits
Additional Files  
No support by the author.

Dice Roller Hack [BBCode]
RPG Dice is currently a updated version
Another updated version

Note: Updated package includes only the correct XML.

This hack is a port of: Dice Roll for vB3 and permissions was given to port by the following statement.

Quote:
Info for hackers:
You may modify, improve, upgrade, redistribute this hack, include it
in another hack or yours or translate it provided you do it free of
charge and you distribute it in www.vbulletin.org at least, there is no
need to pm me asking for permission.
This hack rolls a Graphic based dice roll in your post and features multiple dice rolls per post. The images are fully editable by those who know how and I must agree that I very much think they need an overhaul, so go for it.

The basic bbcode format is:
[dice=X]Y[/dice]

X - The number of dice to roll, This cannot be larger then 5 currently, this may change later with demand.
Y - The number of sides on the dice.

so [dice=1]6[/dice] Roll's 1, 6 sided dice.

The only limit that I have noticed so far is that dice will not apear correctly when rolled from the create thread editor. I am unsure as to why this is still and am working on this issue. However aside from this it is working as need be. This hack is mainly useful to Game websites that require dice rollers for gambling or roleplaying games. It can add an element of fun to a forum and is adapatable to most dice require situations.

If enough demand is displayed I will work on removing the 5 roll limit or making it larger. The current maximum sides one can roll is 30.

If you enjoy this hack or have it installed, then please click the install button so that you can remain informed when updates occur.

As the original author said, You do not need to ask permission to update or do anything to this hack and can redistribute it if you feel you have made a great contribution to it.

If someone does make new dice images and wishes to have them as part of the package then either post here or PM me and I will get them in there with full rights going to the sender for the images.

Updates:
  • 04/29/06
    • Added new dice images which where provided by Rukbat.

This hack was requested from: https://vborg.vbsupport.ru/showthread.php?t=97775

-Eikinskjaldi-

Original Screenshots:
https://vborg.vbsupport.ru/attachmen...3&d=1078098688
https://vborg.vbsupport.ru/attachmen...4&d=1078098702

Show Your Support

  • This modification may not be copied, reproduced or published elsewhere without author's permission.

Comments
  #62  
Old 05-26-2006, 04:23 PM
Eq4bits Eq4bits is offline
 
Join Date: May 2006
Posts: 468
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Quote:
Originally Posted by BeaLzeBuB
it doesn't show the dices.I imported it and it doesn't show the dices there is only [dice=1]6[/dice]
Check your 'thread' and 'post' tables in your database to be sure the 'dice' field was added to both tables.

Be sure you uploaded images of dice to the vBulletin forum images directory into a file named 'dice'. The dice file with the product are the old images and are pretty ugly and only go up to 30. If you want to use more than 30 faces you'll need to make dice for those numbers or download the Blue Dice.zip file that is attached to one of my previous posts (prettier dice and numbered 1-100)
Reply With Quote
  #63  
Old 05-26-2006, 04:32 PM
Eq4bits Eq4bits is offline
 
Join Date: May 2006
Posts: 468
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Quote:
Originally Posted by cclaerhout
I think the sql problem shoud be fixed with this new product file.

I'm still thinking the idea suggested above would be great. If each time you want to play dice you have to type the code, members are going to be upset. I'm going to look if i can do it. Anyway we can ask Michelle, the hacker of e-steki Smilie Maker 1.7 to help us
cclaerhout
Do you know if that also corrected the problem of having a dice roll in a post that is the first post of a new thread?
Reply With Quote
  #64  
Old 05-26-2006, 04:59 PM
Emmy2 Emmy2 is offline
 
Join Date: Jan 2004
Posts: 83
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Yes Eq4bits, a button or collaspible menu for rolling dice that automatically inputs the correct bbcode for each roll when a user clicks on it. If collapsible isn't possible, just a single button would work. I could create more than one button to include variations of the roll.

I have also asked for coding help for this in the general forums, since this idea wouldn't necessarily be exclusive to rolling dice.

here is the thread I've asked...

https://vborg.vbsupport.ru/showthread.php?t=116727
Reply With Quote
  #65  
Old 05-26-2006, 05:48 PM
Eq4bits Eq4bits is offline
 
Join Date: May 2006
Posts: 468
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Okay, what preset would you like? I'm working on it now
Reply With Quote
  #66  
Old 05-26-2006, 06:24 PM
Emmy2 Emmy2 is offline
 
Join Date: Jan 2004
Posts: 83
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

cool! for a preset, how about...

[dice=5]6[/dice] if it's just one button

If it's a menu....

[dice=1]6[/dice]
[dice=2]6[/dice]
[dice=3]6[/dice]
[dice=4]6[/dice]
[dice=5]6[/dice]

As long as there is some code to start off I think I can change it to whatever I want later, but for a start those presets would do.

Thanks, it'll be great if this works!
Reply With Quote
  #67  
Old 05-27-2006, 01:30 AM
Eq4bits Eq4bits is offline
 
Join Date: May 2006
Posts: 468
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

So far I'm not having any luck, like I said I'm no whiz at this but usually given time and a LOT of mistakes I'll eventually figure something out.

It *definiately* doesn't work by just adding a new bbcode via the admincp... I can get the button there, no problem, but it won't execute and show the dice...

OH I just thought of something, if you've installed this and the dice pics aren't showing you MAY need to change the permission/ on your image file to 777 and on the dice file to 777
Reply With Quote
  #68  
Old 05-27-2006, 01:35 AM
Eq4bits Eq4bits is offline
 
Join Date: May 2006
Posts: 468
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

I'm still going to continue playing with this to try to get it to work via a button on the editor or a dropdown on the editor, but until then emmy if you don't need to 'store' the results in the d/b and just want your users to roll dice and don't need it to show in a post take a look at this alternative thread https://vborg.vbsupport.ru/showthrea...highlight=dice
Reply With Quote
  #69  
Old 05-27-2006, 05:45 AM
Eikinskjaldi's Avatar
Eikinskjaldi Eikinskjaldi is offline
 
Join Date: Feb 2006
Location: Hell, never looked better
Posts: 572
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Well paint me up and call me a liar, Due to some demand from my users and a few holes in my alternate dice roller I use I think I will be coming back and working on this hack some more. I don't know yet if I will release the same one here as on my forum since this one being an extension needs to avoid code edits, but I thank those who have supported people and ried to help them, I will be adding your names to the first post and I'll check the package again on the SQL error.

If your dice are not parsing then it is most likely a plugin issue and you should ensure all plugins are turned on. Making a drop down for the post bit doesn't seem to difficult, Much like using the color code in a modified format, I may look into this when iIrevisit this hack, I may have a new version up in the next few days, depending on my scedual.

[[Yes, I am pushing back other work for this as its been something iv been avoiding taking care of at my own site and now its time to tackle it before I get beaten up by disgruntled DM's.]]

-Eikinskjaldi-
Reply With Quote
  #70  
Old 05-27-2006, 09:31 AM
cclaerhout's Avatar
cclaerhout cclaerhout is offline
 
Join Date: Aug 2004
Location: Paris (France)
Posts: 448
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Here is a new xml product file :
-SQL error is fixed
-Display dice in first post of a new thread is OK (i guess my code can be improved a lot )

Now we all can try to make the version of the hack i've described above
Here
Reply With Quote
  #71  
Old 05-27-2006, 11:20 AM
cclaerhout's Avatar
cclaerhout cclaerhout is offline
 
Join Date: Aug 2004
Location: Paris (France)
Posts: 448
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Well, here is a preview of "RPG DiceRoller". I still have to work on the user interface.

You want to play a D4 ?
[dice=1]4[/dice]

You want to play a D6 ?
[dice=1]6[/dice]

You want to play a D8 ?
[dice=1]8[/dice]

You want to play a D10 ?
[dice=1]10[/dice]

You want to play a D12 ?
[dice=1]12[/dice]

You want to play a D20 ?
[dice=1]20[/dice]

Other dices won't work because pictures don't exist

N.B : Pictures are in png format. To avoid grey line arround them in Internet Explorer 6, you need a png transparency hack (available here). Otherwise i could do a gif release.
Reply With Quote
Reply

Thread Tools

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


All times are GMT. The time now is 11:49 AM.


Powered by vBulletin® Version 3.8.12 by vBS
Copyright ©2000 - 2024, vBulletin Solutions Inc.
X vBulletin 3.8.12 by vBS Debug Information
  • Page Generation 0.04999 seconds
  • Memory Usage 2,307KB
  • Queries Executed 27 (?)
More Information
Template Usage:
  • (1)SHOWTHREAD
  • (1)ad_footer_end
  • (1)ad_footer_start
  • (1)ad_header_end
  • (1)ad_header_logo
  • (1)ad_navbar_below
  • (1)ad_showthread_beforeqr
  • (3)bbcode_quote
  • (1)footer
  • (1)forumjump
  • (1)forumrules
  • (1)gobutton
  • (1)header
  • (1)headinclude
  • (1)modsystem_post
  • (1)navbar
  • (6)navbar_link
  • (120)option
  • (1)pagenav
  • (1)pagenav_curpage
  • (4)pagenav_pagelink
  • (1)pagenav_pagelinkrel
  • (11)post_thanks_box
  • (11)post_thanks_button
  • (1)post_thanks_javascript
  • (1)post_thanks_navbar_search
  • (11)post_thanks_postbit_info
  • (10)postbit
  • (11)postbit_onlinestatus
  • (11)postbit_wrapper
  • (1)spacer_close
  • (1)spacer_open
  • (1)tagbit_wrapper 

Phrase Groups Available:
  • global
  • inlinemod
  • postbit
  • posting
  • reputationlevel
  • showthread
Included Files:
  • ./showthread.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/functions_bigthree.php
  • ./includes/class_postbit.php
  • ./includes/class_bbcode.php
  • ./includes/functions_reputation.php
  • ./includes/functions_post_thanks.php 

Hooks Called:
  • init_startup
  • init_startup_session_setup_start
  • init_startup_session_setup_complete
  • cache_permissions
  • fetch_postinfo_query
  • fetch_postinfo
  • fetch_threadinfo_query
  • fetch_threadinfo
  • fetch_foruminfo
  • style_fetch
  • cache_templates
  • global_start
  • parse_templates
  • global_setup_complete
  • showthread_start
  • showthread_getinfo
  • forumjump
  • showthread_post_start
  • showthread_query_postids
  • showthread_query
  • bbcode_fetch_tags
  • bbcode_create
  • showthread_postbit_create
  • postbit_factory
  • postbit_display_start
  • post_thanks_function_post_thanks_off_start
  • post_thanks_function_post_thanks_off_end
  • post_thanks_function_fetch_thanks_start
  • post_thanks_function_fetch_thanks_end
  • post_thanks_function_thanked_already_start
  • post_thanks_function_thanked_already_end
  • fetch_musername
  • postbit_imicons
  • bbcode_parse_start
  • bbcode_parse_complete_precache
  • bbcode_parse_complete
  • postbit_display_complete
  • post_thanks_function_can_thank_this_post_start
  • pagenav_page
  • pagenav_complete
  • tag_fetchbit_complete
  • forumrules
  • navbits
  • navbits_complete
  • showthread_complete