The Arcive of Official vBulletin Modifications Site.It is not a VB3 engine, just a parsed copy! |
|
Dice Roller Hack [BBCode] Details »» | ||||||||||||||||||||||||||
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:
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:
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
|
Comments |
#72
|
|||
|
|||
Although I see no practical use for me, this is a very nice hack technical-wise.
|
#73
|
|||
|
|||
Quote:
[dice=1]6[/dice] [dice=2]6[/dice] [dice=3]6[/dice] [dice=4]6[/dice] [dice=5]6[/dice] That's what Emmy2 is looking for. My group uses anywhere from 1-9 dice and anywhere from 2-100 faces, I was TRYING to just make a new bbcode button in the admincp bbcode manager, i could get the button image to work, but when you'd click it and vB asks you to input the number for the {option} the result would look like: [DICE="4"][/DICE] you still had to put the 'face' variable/option/param in physically between the two sets of brackets, but the quotes vB automatically put around the #ofdice of course kept it from working, was having trouble with the 'html' part in the 'add bbcode' panel also.. *sigh*... I just have to face it somethings I *can* do and some I just don't have the knowledge for.. I'm just belligerant and keep at it though... till I'm cross-eyed... LOL I didn't realize IE put grey borders around gifs, i've never noticed it before.... hmmmm If anyone wants me to turn the 1-100 Blue Dice in pentagonal shape (that I did as Rukbat) into png's let me know and I'll do a batch conversion and re-zip & re-upload here. |
#74
|
|||
|
|||
cclaerhout,
One more question... is the 'roll' still stored in the d/b? |
#75
|
|||
|
|||
There now seems to be several of you working on variations for this, and that's great! So, not to sidetrack everyone but I have a few more ideas....
Suppose I wanted to install this hack more than once, what would I need to change in the original xml file? In other words I want one hack called "dice" and another hack called "cards" that does the same thing but uses separate database tables and images. So for example, I can have one game that throws dice and another game that draws playing cards. Or another game that rolls letters of the alphabet. In other words, suppose I want 3 separate games. Dice, Cards, Alpha, if you want to name them. What parts of the original script could I change so that I can install this game a second and third time (in a different place, not overwriting the first game)? Then, to play, users would type (or I'd create buttons for): [dice=5]6[/dice] to roll a 6 sided dice five times [cards=5]52[/card] to draw 5 cards from a 52-card deck [alpha=9]26[/alpha] to roll 9 letters out of the 26 letter alphabet I'm dreaming big here folks! :P Another idea....suppose for the card game users are drawing 5 cards and I don't want them to draw the same card twice (this could also apply to dice). Is there a way to limit it so the same card/dice isn't drawn/rolled more than once in a roll of multiple die or cards? Yeah, this is all pretty much off-base for the current project, but I thought I'd just throw these ideas out there. |
#76
|
||||
|
||||
Quote:
The dice are still in database. |
#77
|
||||
|
||||
Well a standard deck has 52 cards so you bbcode would probaly look more like [cards]5[/cards]. With private text you could be on your way to having poker in threads. as far as limiting it, ya, it could be limited, it'd be as simple as stoirng the values in a array and testing to make shure none equal eachother.
However back on dice, Another idea is a prompt box which you can enter the number to roll after having selected the sides from a drop down.I'll look into that avenue. I am going to making a steep departure from the old system of rolling dice as it doesn't work for me, so this drop down idea won't work for me, in any case, all that well. Seeing as I help run one of the largest gaming sites for PbP it isnt easy to keep everything simple. A sample new style roll would be: [dice=Dice Title]1d20 1d20 1d6[/dice] Which would provide a much cleaner more cingular less bulky output. I also don't want images, so I will probaly provide to XML's, one with them and one without. If you visit my forum and check out some of the dice rolls you can see the output I will probaly be aiming for as I want to try and keep my dice standard. The cards thing shouldn't be to hard and i'll look into it if I have time. |
#79
|
||||
|
||||
Michelle is sorry but she doesn't have time to work on this. If an advanced coder can have a look, it would be nice.
|
#80
|
|||
|
|||
Could the "onclick" command be used in conjuction with an image button to insert the roll into the textarea?
I've been looking at the smilie code and that's what it does. Click a smilie and it inserts something like :smilie: into the text box. Instead of :smilie: I need it to insert the code for a dice roll. So something like this to create a button (this is just me expressing my idea, it is NOT real code): Code:
<img src="http://www.mysite.com/dicebutton.gif" onclick="return value('[dice=5]6[/dice]')"> |
#81
|
|||
|
|||
Quote:
I will post the code late tonight when I get home from work...I have been working on this all day. :banana: |
|
|
X vBulletin 3.8.12 by vBS Debug Information | |
---|---|
|
|
More Information | |
Template Usage:
Phrase Groups Available:
|
Included Files:
Hooks Called:
|