Jtgibson

Real Name: Jeremy T. Gibson

Joined: 239.187 NC

Happily Married to the Internet

Topics

 

 

Less yellow, more mellow

On a whim, I went ahead and adjusted the CSS of the site a little, mainly because the brown-ink that looks so good on my parchment background looks so terrible on the default blue forum background. I still need to tweak the contrast of the boxes that make up the Blogwatch and the Favourites, since those are way too dark for my tastes.

Posted by Jtgibson on Monday, May 26, 2008 07:16PM - 2 comments / Members say: yea +0, nay -0

Another DM feature that I didn't know about

It is possible to make simple initializations when you want variables to have values other than the default for the particular type you are creating.

Example:
mob/contents = newlist(
   /obj/scroll/readme {
      name = "Introduction"
      desc = "The fate of Bracolia depends on you ..."
   }
)


This is the most common use of "modified types", but it is not specific to the newlist instruction. Anywhere a type value may be used in DM, it may be followed by a list of initializations. The general syntax for a modified types is:

path {var1 = val1; var2 = val2}

The semicolon is necessary if you put several variable assignments on the same line. The braces are necessary, even though they are generally optional in DM (since the compiler looks at your indentation). The reason is that the path + initializations must be parsed as a single expression, which is a different context from the usual use of braces in DM when you are defining a true type. Also, indentation inside of an argument list is always ignored anyway.



I knew about the newlist proc, but had no idea it could be used to make modified instances, nor did I have any idea that the same syntax can be used elsewhere in DM!

Go forth and multiply!

Posted by Jtgibson on Sunday, April 27, 2008 12:38PM - 4 comments / Members say: yea +0, nay -0

An important reminder

Just 288 shopping days until Christmas!


[edit]Since this is long gone from the front page, I'll include the blurb right here too:

"The dangers of being bait-and-switched on the internet are very real; Jtgibson bars no holds in this tell-all exposé."

Posted by Jtgibson on Tuesday, March 11, 2008 12:43PM - 3 comments / Members say: yea +0, nay -0
(Edited on Thursday, June 05, 2008 10:55PM)

jt_options

From this:

option/Test_Checkbox
    desc = "Lorem ipsum dolor sit amet, consectetuer adipiscing elit. Vivamus \
                vulputate libero nec ante. Cras tristique suscipit ipsum. Class aptent \
                taciti sociosqu ad litora torquent per conubia nostra, per inceptos \
                hymenaeos. Morbi dignissim purus sed turpis. Suspendisse rhoncus eros id \
                erat venenatis dignissim."

option/Test_Radio
    desc = "Lorem ipsum dolor sit amet, consectetuer adipiscing elit. Nulla \
                lacus mauris, lobortis et, pellentesque a, lacinia vel, justo. Proin \
                feugiat. Maecenas odio lorem, condimentum nec, euismod vitae, cursus \
                in, nisl. Sed consectetuer vehicula nunc. Etiam eget dolor. Morbi a dui."

    input_type = OPTION_RADIO

    choices = list("Option 1", "Option 2", "Option 3")
    choice_descs = list(
        "Lorem ipsum dolor sit amet, consectetuer adipiscing elit",
        "Lorem ipsum dolor sit amet, consectetuer adipiscing elit",
        "Lorem ipsum dolor sit amet, consectetuer adipiscing elit")

option/Test_Slider
    desc = "Lorem ipsum dolor sit amet, consectetuer adipiscing elit. Sed sit \
                amet enim quis velit dictum rhoncus. Donec dictum risus nec turpis. \
                Donec tempus, urna a feugiat congue, risus dolor semper leo, iaculis \
                facilisis purus lorem in felis. Maecenas pellentesque."

    input_type = OPTION_SLIDER

    min_bound = "Low"
    middle_bound = "Mid"
    max_bound = "High"


To this:



More forthcoming!

Posted by Jtgibson on Friday, February 29, 2008 07:50PM - 4 comments / Members say: yea +0, nay -0

Language is a scalpel, not a bludgeon

The use of "coder" and "codes" and "iconer" and various other brain-dead language has to stop. Use real words, dagnabbit. =P

Posted by Jtgibson on Thursday, February 07, 2008 02:46PM - 8 comments / Members say: yea +0, nay -0