Advanced Examine Self

Heya all, thanks for all the brilliant help lately! Things are coming along great.

Now, another one of my many questions. I want to chance Look at self, or examine self, to something a bit more custom.

I already rooted out the little String for player.pov_look and attempted to type something into it.

You're a (player.sex) in their later teens, or maybe early twenties. Your eyes are a sparkling and bright (player.eyecolour) while your hair is (player.haircolour). They go well with your (player.skincolour).

And of course, it just types out exactly like that. My things are not getting summoned. I'm assuming it's a simple fix somewhere, but I did try using <> instead of brackets. Where could I be going wrong?


Figured it out! Change it to a script, print message

You're a {player.sex} in their later teens, or maybe early twenties. Your eyes are a sparkling and bright {player.eyecolour} while your hair is {player.haircolour}. They go well with your {player.skincolour}


1. The 'look' Attribute is used when/for any non-room Object that's NOT currently controlled by you. This is found under/in the 'setup' Tab of Objects
2. The 'pov_look' Attribute is used when/for any non-room Object that IS currently controlled by you. This is found under/in the 'Player' Tab of Objects. You got to first toggle on this Tab's displayment, then you got to make you toggle on your Object to be the 'can be a player object' option.
3. The pattern (input format/syntax) for the 'look' Command is: look at #object_parameter#, for example, you'd type in during playing the game (pretending/assuming you're in a room with a dragon): look at dragon
4. The 'description' Attribute is used when/for any Room Object.

the 'look/description' Attributes can be either: a Script Attribute or a String Attribute. There's not really too much difference between them. If you change/set it to being a Script Attribute, then you got the full 'normal' scripting capabilities/funtionality at your disposal. If you change/set it to being a String Attribute, then you got to use the 'text processor commands' to do any of the scripting that you might want to do for it.

during game play you can do these quick inputs (they're built-in to be connected to the above stuff) too:

x NAME_OF_OBJECT // displays/runs the 'look/description' Attribute for your typed-in inputted object
look // displays/runs the 'description' Attribute for the Room Object you're within
look at NAME_OF_OBJECT // displays/runs the 'look/description' Attribute for your typed-in inputted object

---------

your issue in your OP wasn't the Attribute Type (String vs Script), but that you just did the wrong syntax for the text processor commands:

wrong syntax example: (player.sex)

instead of the correct syntax (example): {player.sex}

-------

also note for the GUI/Editor's 'print a message' Script, about the differences between its script options:

1. [MESSAGE]

this ONLY ALLOWS: TEXT

examples:

print [MESSAGE] Hi, my name is HK, said HK to the npc next to him.
// output: Hi, my name is HK, said HK to the npc next to him.
// NO error

print [MESSAGE] "Hi, my name is HK," said HK to the npc next to him. 
// output: "Hi, my name is HK," aid HK to the npc next to him.
// NO error

// player.alias = "HK"
print [MESSAGE] Hi, my name is {player.alias}, said {player.alias} to the npc next to him. 
// ERROR! (I think anyways... maybe using the text process command doesn't cause an error, meh)

// player.alias = "HK"
print [MESSAGE] "Hi, my name is " + player.alias + ", said " + player.alias + " to the npc next to him."
// ERROR!

2. [EXPRESSION]

you can do: just TEXT, just VARIABLE(S), and/or TEXT + VARIABLES

examples:

// player.alias = "HK"
print [EXPRESSION] "Hi, my name is {player.alias}, said {player.alias} to the npc next to him."
// output: Hi, my name is HK, said HK to the NPC next to him.
// NO error

// player.alias = "HK"
print [EXPRESSION] "Hi, my name is " + player.alias + ", said " + player.alias + " to the npc next to him."
// output: Hi, my name is HK, said HK to the npc next to him.
// NO error

// player.alias = "HK"
print [EXPRESSION] "\"Hi, my name is " + player.alias + ",\" said " + player.alias + " to the npc next to him."
// output: "Hi, my name is HK," said HK to the npc next to him.
// NO error

// player.alias = "HK"
print [EXPRESSION] "\"Hi, my name is {player.alias},\" said {player.alias} to the npc next to him."
// output: "Hi, my name is HK," said HK to the NPC next to him.
// NO error

// player.alias = "HK"
print [EXPRESSION] "hi"
// output: hi
// NO error

// player.alias = "HK"
print [EXPRESSION] hi
// ERROR!

print [EXPRESSION] "\"hi\""
// output: "hi"
// NO error

// player.alias = "HK"
print [EXPRESSION] player.alias
// output: HK
// NO error

// player.alias = "HK"
print [EXPRESSION] "{player.alias}"
// output: HK
// NO error

// player.alias = "HK"
print [EXPRESSION] {player.alias}
// output: HK
// ERROR! (I think ... but maybe not)

if you code scripting in anything directly in code, it follows the rules of the [EXPRESSION]'s rules, all textual parts MUST BE within double quotes, to make it be textual (String)


ask if you need any help with anything or need anything explained


This topic is now closed. Topics are closed after 60 days of inactivity.

Support

Forums