• When posting, please be aware that artistic nudity is still nudity and not allowed under RpNation rules. Please edit your pictures accordingly!

    Remember to credit artists when using work not your own.

Tutorial RpNation - BBCode+ Guide

Status
Not open for further replies.
No, this is not possible and I have no plans to allow it right now. Did you have a use case in mind?
Well, for a battle system, it would be handy to create an easier way for both GM and players to keep track of stats, and maybe even create outcomes automatically.
-The script runs, pulls out value in player's last post that has their attack, compares to enemy-boop done.
-hidden values that GM can sneak into character sheet generator can be revealed and compared to other values by characters.

Or a little miscellaneous.
- Player just has to put in a number in his/her post to assign certain place picture of another players character in a box int he box to show the characters have some sort of relationship.

I mean once we can pull values from other posts; we could pretty much make video games based on the forums code. It could spiral into some really unknown results.
 
Well, for a battle system, it would be handy to create an easier way for both GM and players to keep track of stats, and maybe even create outcomes automatically.
-The script runs, pulls out value in player's last post that has their attack, compares to enemy-boop done.
-hidden values that GM can sneak into character sheet generator can be revealed and compared to other values by characters.

Or a little miscellaneous.
- Player just has to put in a number in his/her post to assign certain place picture of another players character in a box int he box to show the characters have some sort of relationship.

I mean once we can pull values from other posts; we could pretty much make video games based on the forums code. It could spiral into some really unknown results.
I believe this would be rather difficult to implement using a BBCode solution. For one thing, the data could not be exposed through scripts, since those are only run on a page, so it would be impossible to get script data from a previous page. This would therefore require a special [metadata] tag of sorts that is parsed server-side for information, which could be done but would require quite a bit of work. I will keep it in mind, but unless there's big demand for this functionality, it won't be high on my priority list.

Would you mind adding it to my suggestions thread so I can keep track of it?
 
Question on implemention of that Character Sheet Generator:
I've tried to use the same format for more intericate character sheets, the best use for this sorta idea, but it outputs what a post would look like instead of code the roleplayers can use. When using the the CODE tags from regular BBCode, the values for name, age, and description are left blank. Any idea how to make a viable characters sheet generator for decorative sheets?
 
Question on implemention of that Character Sheet Generator:
I've tried to use the same format for more intericate character sheets, the best use for this sorta idea, but it outputs what a post would look like instead of code the roleplayers can use. When using the the CODE tags from regular BBCode, the values for name, age, and description are left blank. Any idea how to make a viable characters sheet generator for decorative sheets?
use [plain][/plain] to output in plain text.
 
A major update has been released for BBCode+!

This update comes with several new features, and the guide has been updated to reflect this:
  • BBScript 2: Tired of the limitations of BBScript? Try BBScript 2, which brings all new functions and features, including the ability to call functions with a timer, define arrays and manipulate strings. See the Scripts section for more information.
  • Animations: You can now define your own custom CSS animations. See the Animations section for more information.
  • Responsive classes: Classes can now be slightly responsive, adjusting their width based on the browser window width. See the Tags reference for more information.
  • Stylable user tags: The [user] tag can now have BBCode inside it, as was possible in XenForo 1.
Please let me know if you have any questions. I may livestream an explanation of this update soon.
 
I have streamed some information about BBCode+'s latest update, as well as some general tips:
 
Ehhhh.... I understand how to use bbcodes (like the one provided in the bbcode guide in site) but I really don't understand any of this :(
Here's a small list of my questions...
1) What does BBCODE+ add more to ordinary bbcode?
2) Does the BBCODE guide provided enough to understand what bbcodes are?
3) ...

Well, three would be how do I use this but I guess I'll figure it out once I have everything else answered xD

Thanks in advance for your time to respond and your contribution :)
 
Ehhhh.... I understand how to use bbcodes (like the one provided in the bbcode guide in site) but I really don't understand any of this :(
Here's a small list of my questions...
1) What does BBCODE+ add more to ordinary bbcode?
2) Does the BBCODE guide provided enough to understand what bbcodes are?
3) ...

Well, three would be how do I use this but I guess I'll figure it out once I have everything else answered xD

Thanks in advance for your time to respond and your contribution :)
These codes are a bit more abstract, so it's normal that they would be a bit harder to grok.
1) BBCode+ makes several things possible. The simplest addition is the ability to define classes for divs, which can help reduce code duplication, but also allows you to react to state changes (e.g. if the user hovers over a div). It also lets you define scripts, which can add programming logic to your posts, so that you can react to user events, initiate count-downs, make interactive menus, etc.. The OP in this thread is an example of scripts in action to code the navigation menu, for example. However, aside from div, BBCode+ does not add anything to existing tags, as its intent is not to provide pre-made elements, but to let the developer make their own.
2) Do you mean the BBCode+ guide? It provides everything you need to know to get started, yes, though it assumes some prior CSS knowledge.
3) I suggest looking at the examples linked in the OP to see some simple use-cases. Or you can have a look at this thread, which explains the process behind the code's creation in the second post: Resource -   ¬ FEVERDREAMS ⸥ alt sugar That code makes heavy use of BBCode+.
 
Is it possible to have a input overlapping an image besides making that image a background?
Yes, you could use positioning to move it over an image (e.g. a relative container around the image and the input, the latter of which then gets absolutely positioned).

Alternatively, you can also try just floating it over the image.

Inputs behave just like divs when it comes to styling them.
 
I feel so dumb, probably because my mind's set for HTML and not BBCode ;w;
aaaaahhhh, is it possible to make a div inside a div??? just a smaller div inside a big div so that the background of the bigger div doesn't get in the way of the text
kind of like the boxes you made for the codes :T

I'm sorry, it's probably not the smartest of questions TuT
 
I feel so dumb, probably because my mind's set for HTML and not BBCode ;w;
aaaaahhhh, is it possible to make a div inside a div??? just a smaller div inside a big div so that the background of the bigger div doesn't get in the way of the text
kind of like the boxes you made for the codes :T

I'm sorry, it's probably not the smartest of questions TuT
Yes, just like in HTML you can nest any number of divs within each other. This is not a BBCode+ specific question either - it applies to almost every other BBCode (there are exceptions).
 
Yes, just like in HTML you can nest any number of divs within each other. This is not a BBCode+ specific question either - it applies to almost every other BBCode (there are exceptions).

I see, thank you. I suppose I need to learn a bit more to be able to fully master BBCode+ ^.^
 
One question, is there any function/button/anything on this site that allows me to see others' bbcode in their posts? Thank you.
 
The BBScript docs are, personally, not exact enough regarding the syntax of the functions. I have no idea how to add an else to my if at the moment, and without examples I would not know I needed () around almost everything. I believe such a thing should be in the docs themselves (an example for each functions using every option available). Plus, I figure if can only have one function executed if the condition passes, or is there a way to add multiple? I don't think I've rechecked in BBScript2 for that, going to do that now, but, nevertheless, the docs clarity comment still applies. Right now they greatly remind me of my university's official ARMv7 cheat-sheet x)

Edit#1
Also, the TARGET thing - except for the usual way of just addressing the caller by not writing anything, is there another way to input that into the functions since the object itself is mentioned in the documentation? Like, do something to the caller/trigger but do something else at the same time to the others, if there is a group of things.

Edit#2
Found the group thing in v2, have no idea how to use it - my full two attempts have failed. Help?
 
Last edited:
The BBScript docs are, personally, not exact enough regarding the syntax of the functions. I have no idea how to add an else to my if at the moment, and without examples I would not know I needed () around almost everything. I believe such a thing should be in the docs themselves (an example for each functions using every option available). Plus, I figure if can only have one function executed if the condition passes, or is there a way to add multiple? I don't think I've rechecked in BBScript2 for that, going to do that now, but, nevertheless, the docs clarity comment still applies. Right now they greatly remind me of my university's official ARMv7 cheat-sheet x)

Edit#1
Also, the TARGET thing - except for the usual way of just addressing the caller by not writing anything, is there another way to input that into the functions since the object itself is mentioned in the documentation? Like, do something to the caller/trigger but do something else at the same time to the others, if there is a group of things.

Edit#2
Found the group thing in v2, have no idea how to use it - my full two attempts have failed. Help?
if you look in the example keypad, there's an example of an if then else statement:
Code:
[script class=numkey on=click]
if (le ${curChar} 5) (inc curChar) (stop)
This follows the described syntax of a BBscript ver1 if statment. If (value of curChar is <= 5) then (increase curChar by 1) else (stop the script).

For the target, you'd use the class name of the div you want to use. Just put it in a string. The Character Sheet Generator has a good example, using the getVal function.
Code:
set name (getVal csgname)
set age (getVal csgage)
set description (getVal csgdescription)

The group should look like this:
Code:
(if (random test argument here) (group
	(function 1)
	(function 2)
	(...)
	(function n)))
 
The group should look like this:
Code:
(if (random test argument here) (group
    (function 1)
    (function 2)
    (...)
    (function n)))


Oou, thanks, so I managed to figure it out anyway (at least partially), but something else isn't working, then.
Also, what if there was an else statement here - would it go inside or outside the parentheses around the if?

Though, either way, even with the simplest function within the script tag when I have the parameter/argument "version=2" after "class" and "on" in it shows some script error ("Expecting function call, found h") (yes, it ends there, I don't know why it's cut off). What am I doing wrong? (details in spoiler)


Not sure though if this is the right place or if I should post a HELP thread, but...
Example of error:
Rich (BB code):
[script class=tab on=click version=2]
    hide tabsContent
    = currentTab getText
    (if (== currentTab Personality) (group(
                                                                        (show personalityTab)
                                                                        (addClass tabSelect)
                                                            ))) (removeClass tabSelect perdiv)

    (if (== currentTab Fighting) (group(
                                                                        (show fightingTab)
                                                                        (addClass tabSelect)
                                                            ))) (removeClass tabSelect figdiv)

    (if (== currentTab Other) (group(
                                                                        (show otherTab)
                                                                        (addClass tabSelect)
                                                            ))) (removeClass tabSelect odiv)
[/script]

Code that breaks it (also, I am not sure if in BBScript 2 value assignment and comparisons work like this?)
(plus, the else is outside the if parentheses but the break happens either way so I cannot tell which is correct)
Code:
[script class=tab on=click version=2]
    hide tabsContent
    = currentTab getText
    (if (== currentTab Personality) (group( (show personalityTab) (addClass tabSelect) ))) (removeClass tabSelect perdiv)

    (if (== currentTab Fighting) (group( (show fightingTab) (addClass tabSelect) ))) (removeClass tabSelect figdiv)

    (if (== currentTab Other) (group( (show otherTab) (addClass tabSelect) ))) (removeClass tabSelect odiv)
[/script]
 

Oou, thanks, so I managed to figure it out anyway (at least partially), but something else isn't working, then.
Also, what if there was an else statement here - would it go inside or outside the parentheses around the if?

Though, either way, even with the simplest function within the script tag when I have the parameter/argument "version=2" after "class" and "on" in it shows some script error ("Expecting function call, found h") (yes, it ends there, I don't know why it's cut off). What am I doing wrong? (details in spoiler)


Not sure though if this is the right place or if I should post a HELP thread, but...
Example of error:
Rich (BB code):
[script class=tab on=click version=2]
    hide tabsContent
    = currentTab getText
    (if (== currentTab Personality) (group(
                                                                        (show personalityTab)
                                                                        (addClass tabSelect)
                                                            ))) (removeClass tabSelect perdiv)

    (if (== currentTab Fighting) (group(
                                                                        (show fightingTab)
                                                                        (addClass tabSelect)
                                                            ))) (removeClass tabSelect figdiv)

    (if (== currentTab Other) (group(
                                                                        (show otherTab)
                                                                        (addClass tabSelect)
                                                            ))) (removeClass tabSelect odiv)
[/script]

Code that breaks it (also, I am not sure if in BBScript 2 value assignment and comparisons work like this?)
(plus, the else is outside the if parentheses but the break happens either way so I cannot tell which is correct)
Code:
[script class=tab on=click version=2]
    hide tabsContent
    = currentTab getText
    (if (== currentTab Personality) (group( (show personalityTab) (addClass tabSelect) ))) (removeClass tabSelect perdiv)

    (if (== currentTab Fighting) (group( (show fightingTab) (addClass tabSelect) ))) (removeClass tabSelect figdiv)

    (if (== currentTab Other) (group( (show otherTab) (addClass tabSelect) ))) (removeClass tabSelect odiv)
[/script]
In version 2, everything needs parentheses. The else would go before the last parentheses.
 
Status
Not open for further replies.

Users who are viewing this thread

Back
Top