Create a free account to remove all ad content.

Author Topic:  Script Tutorial #1  (Read 566 times)

0 Members and 1 Guest are viewing this topic.

Titan

  • Sr. Member
  • *
  • Posts: 492
    • View Profile
Script Tutorial #1
« on: April 11, 2015, 08:00:32 PM »

Craig

  • Developer
  • Extreme Member
  • *
  • Posts: 6655
  • Dig Deep
    • View Profile
    • Twitter
  • Steam: tota1miner
Re: Script Tutorial #1
« Reply #1 on: April 11, 2015, 09:07:09 PM »
You know the HasInventory check is redundant for the sledge hammer clear?

CookieKiller345

  • Member
  • *
  • Posts: 130
  • Can I have a cookie?
    • View Profile
  • Xbox: CookieKiller345
Re: Script Tutorial #1
« Reply #2 on: April 11, 2015, 09:09:29 PM »
For the clear a specific item script, you can make it where it takes all of them items instead of taking one. In your example, if they had more than one sledgehammer, one sledgehammer would be taken away and they would still have another.
Here's a script I would use:

If
 HasInventory [player] [sledgehammer] [true]
Then
 Inventory [player] [clear] [sledgehammer]
 Notify [No sledgehammers allowed!] [local]

Great videos though. Keem 'em going  :)

Gary

  • Tester
  • Supreme Member
  • *
  • Posts: 2942
  • Steam: Conmaan ... ... Discord: Conmaan #9586
    • View Profile
Re: Script Tutorial #1
« Reply #3 on: April 12, 2015, 01:03:44 AM »
Small Suggestion: You may want to write up a script for what you're going to say and do ahead of time, before you record. You just seemed a bit lost at the end there.

Fantastic video, though, man! Other than the video quality it was great ;)


               

Link to my youtube channel:
https://www.youtube.com/channel/UCo4rmelSOUB9YMM0Is-zWyQ