Welcome to the Achaea Forums! Please be sure to read the Forum Rules.

ShopKeeper

2»

Comments

  • KoganKogan Posts: 356Member ✭✭✭✭ - Eminent
    edited November 2017
    Antonius said:
    function loadInventory()
    	if string.char(getMudletHomeDir():byte()) == "/" then 
    		_sep = "/"
    	else 
    		_sep = "\\"
    	end -- if
    
    	shop_inventory = getMudletHomeDir() .. _sep .. "shop_inventory.lua"
    
    	if (io.exists(shop_inventory)) then
    		table.load(shop_inventory, inventoryList)
    	end -- if
    end -- func
    registerAnonymousEventHandler("sysLoadEvent", "loadInventory")
    
    Is there a reason people still do the / or \\ shenanigans for windows/linux? It isn't really necessary as far as I know. I'd like to chalk it up to most people not knowing it isn't, but if there is a reason to still do it I'd love to learn why!
  • PrythePrythe Posts: 440Member ✭✭✭✭ - Eminent
    Rangor said:
    Merewyn said:
    can someone break this down for the completely code-illiterate me? Am I meant to just c/p all this into a single script, then create aliases that call on these functions? 
    Yep!
    Can you provide an example of just one of the aliases calling one of the functions? The breakdown of this is amazing and I want to try and play/create something.

    - To love another person is to see the face of G/d
    - Let me get my hat and my knife
    - It's your apple, take a bite
    - Don't dream it ... be it


  • RangorRangor Posts: 2,918Member @@ - Legendary Achaean
    Prythe said:
    Rangor said:
    Merewyn said:
    can someone break this down for the completely code-illiterate me? Am I meant to just c/p all this into a single script, then create aliases that call on these functions? 
    Yep!
    Can you provide an example of just one of the aliases calling one of the functions? The breakdown of this is amazing and I want to try and play/create something.
    https://drive.google.com/open?id=1ZmOtUFCwRGusWwYUQtKsKaPufQbZ6kve

    See if you can download that, should include the scripts and aliases I use for managing my shop. Someone else supplied me with the shopdropandroll script once upon a time for auto pricing. 
    image
    Prythe
  • DaironDairon Posts: 282Member ✭✭✭ - Distinguished
    You guys are awesome! 
  • PrythePrythe Posts: 440Member ✭✭✭✭ - Eminent
    Rangor said:
    Prythe said:
    Rangor said:
    Merewyn said:
    can someone break this down for the completely code-illiterate me? Am I meant to just c/p all this into a single script, then create aliases that call on these functions? 
    Yep!
    Can you provide an example of just one of the aliases calling one of the functions? The breakdown of this is amazing and I want to try and play/create something.
    https://drive.google.com/open?id=1ZmOtUFCwRGusWwYUQtKsKaPufQbZ6kve

    See if you can download that, should include the scripts and aliases I use for managing my shop. Someone else supplied me with the shopdropandroll script once upon a time for auto pricing. 
    Thank you so much.

    I think I might have a larger issue. 

    I had a script which was working then suddenly the command returned nothing. 

    Same thing here - I entered the alias you set up, and nothing:

    System doesn't even tell me that it does not understand - just does nothing.

    Is there a setting which tells Mudlet - Hey, we're doing Lua stuff here! which I might have accidently turned off?

    Thank you again!
     

    - To love another person is to see the face of G/d
    - Let me get my hat and my knife
    - It's your apple, take a bite
    - Don't dream it ... be it


  • RangorRangor Posts: 2,918Member @@ - Legendary Achaean
    Have you enabled gmcp? Also of you click the errors button in your aliases/triggers/scripts it usually tells you what went wrong, even if it's hard to understand what it's saying.
    image
2»
Sign In to Comment.