Author Topic: Placeholders  (Read 1431 times)

Antikore

  • Developing Mortal Theater at day, developing depression at night.
  • Level 22: Trex
  • *
  • Posts: 2020
  • Enjoying Platform Builder from the very start
    • View Profile
    • PBuilder Resources
Placeholders
« on: September 24, 2018, 12:21:49 PM »
Command prompt is jsut the most powerful and advanced tool in Platform Builder, but still lacks of something important: Placeholders (I think they are named like that.)

Placeholders are just a way to modify values or detect stuff in commands with other values.
I want to heal my player at the end of the level 1 point per coin, just use a placeholder

health + [money]
coins = 0

[money] is a placeholder that will be replaced with the number of coins you have. If you have 5 coins the command will do this:

health + 5
money = 0

Another example:
health = [max health]

This will set the health to the max health of the player
Another example:

+You don't have enough currency, you only have [money] coins
If you have 5 coins, the message will say:
"You don't have enough currency, you only have 5 coins"

This will give Platform Builder tons of possibilities and will make easier many stuff.
Sorry because my English is not very good because I'm Spanish ;) :P

CGM

  • Christian, 3D artist, former Platform Builder gamdev
  • Master Builder
  • *
  • Posts: 3836
    • View Profile
Re: Placeholders
« Reply #1 on: September 24, 2018, 12:27:03 PM »
Yes!!! Love it!!!

Antikore

  • Developing Mortal Theater at day, developing depression at night.
  • Level 22: Trex
  • *
  • Posts: 2020
  • Enjoying Platform Builder from the very start
    • View Profile
    • PBuilder Resources
Re: Placeholders
« Reply #2 on: September 24, 2018, 12:28:27 PM »
This will improve very much command prompt and it's uses!
Sorry because my English is not very good because I'm Spanish ;) :P

CGM

  • Christian, 3D artist, former Platform Builder gamdev
  • Master Builder
  • *
  • Posts: 3836
    • View Profile
Re: Placeholders
« Reply #3 on: September 24, 2018, 12:37:05 PM »
Yes!