SphereCommunity
Craftable Lockables - Printable Version

+- SphereCommunity (https://forum.spherecommunity.net)
+-- Forum: Sphere 0.56d (/Forum-Sphere-0-56d)
+--- Forum: Script Submissions (/Forum-Script-Submissions)
+--- Thread: Craftable Lockables (/Thread-Craftable-Lockables)



Craftable Lockables - Mordaunt - 10-06-2012 10:12 AM

The original version of this was the 2nd script I ever made years ago.
This version is 90% smaller (I took out the items themselves) and just as effective

I never liked the scripts back then gave players a deed for a container that locked when they crafted them. So I did this instead.
Super small, Super simple.

Just add TEVENTS=t_keyed to whatever items you want to be players to be able to craft with a key, and add i_key_copper to the RESOURCES line for a bit more realism.

Code:
[TYPEDEF t_keyed]
ON=@DCLICK
IF (<eval <More2>> < 1)
    serv.newitem=i_key_copper
    new.more1=<uid>
    new.cont=<uid>
    more1=<uid>
    MORE2 += 1
ENDIF



RE: Craftable Lockables - Anarch Cassius - 10-06-2012 05:42 PM

Now here's a challenge for you:
Alter the crafting system I showed you to have an extra section, like materials, for lock type. Have it list unlocked, and all the key types.

When a key type is chosen and a player is examing/crafting a container, tack the key on to the resources and add your even to the container. Use an override tag to alter key type. If unlocked is selected, just do the normal routine.

Also one related note... your system sets MORE2 for tracking, which is clever in a way but means that all your containers are going to be very easy to lockpick having 0.1 difficulty. I'd set MORE2 based on keytype and remove the event when it finishes, or keep your check since MORE2 will be >1. Removing it seems slightly more effiecient.


RE: Craftable Lockables - htid4life - 10-06-2012 08:32 PM

or better yet make more2 random higher the persons skill in lockpicking and skill required to craft the item the harder it is to lock pick?