Register forum user name Search FAQ

Gammon Forum

Notice: Any messages purporting to come from this site telling you that your password has expired, or that you need to verify your details, confirm your email, resolve issues, making threats, or asking for money, are spam. We do not email users with any such messages. If you have lost your password you can obtain a new one by using the password reset link.

Due to spam on this forum, all posts now need moderator approval.

 Entire forum ➜ SMAUG ➜ SMAUG coding ➜ Merchants of Smaug

Merchants of Smaug

It is now over 60 days since the last post. This thread is closed.     Refresh page


Posted by Garaelb   (54 posts)  Bio
Date Sun 20 Jul 2003 09:43 PM (UTC)
Message
Hi gang - its me your friendly neighborhood SMAUG Building dummy, here with another question.

While trying to build a shop in my game I want the shop to only sell itmes of level 2 - basically for new players. How do i set the item level limit on items sold in a shop? No item should be above level 5. So I want a range between level 2 and level 5 items.

Example a
Lv 2 wooden sword (weapon)
Lv 2 Skull cap (armor)
Lv 2 Sweet Water (potion of cure light)

Any ideas?


Garaelb
Top

Posted by Garaelb   (54 posts)  Bio
Date Reply #1 on Tue 22 Jul 2003 04:49 PM (UTC)
Message
Hi gang - I'm still having problems trying to fix the levels of items for sale in a shop.

Area ranges are set -
SOFT - 0-5
HARD 0-65

The shop is actually a whole area of it's own. Kind of like an adventurer's department store. The 'clerks' are mobs of various levels generally above 20th level. But the itmes for sale I want to be 5th level or lower. What can I do? How can I do it? Do you need more information about the area?
Top

Posted by Garaelb   (54 posts)  Bio
Date Reply #2 on Sun 27 Jul 2003 10:15 PM (UTC)
Message
Just bumping this up again looking for an answer.
Top

Posted by Nick Gammon   Australia  (23,158 posts)  Bio   Forum Administrator
Date Reply #3 on Mon 28 Jul 2003 06:09 AM (UTC)

Amended on Mon 28 Jul 2003 06:10 AM (UTC) by Nick Gammon

Message
Setting the soft level to 5 (or lower) seems to limit the items on sale to a maximum of 5 - for example:


Armory
This shop's owner is a dedicated creator of armor and shields.  
Having lost her son to shabby equipment, she took up the job of 
putting protective suits of mail together.  
To the west is the blacksmith's, while the armourer's is to the east.  
An opening in the tent leads back out north onto Market Street.  
Exits: north east west.
The armourer is here fitting a mail helm.
Nick the Recruit is deep in slumber here.
A stray dog noses along the street.

<3000hp 5000m 3100mv> 
list
[Lv Price] Item
[ 5  1742] A crested breastplate.
[ 5   174] An iron bracer.
[ 5  1045] An iron guard.
[ 5  1393] An iron helm.
[ 5  1045] An iron shield.
[ 5   174] An iron visor.
[ 5   348] Black boots.
[ 5   696] Chain sleeves.
[ 5   696] Iron gauntlets.
[ 5   522] Mail leggings.


I don't seem to be able to get the level to go below 5 - however I think it is linked to the area level, with a minimum - seems to be since they are all level 5.

For instance, with the area level set to 65 - the normal - then I see this ...


[Lv Price] Item
[17  1742] A crested breastplate.
[16   174] An iron visor.
[12  1045] An iron guard.
[ 8  1045] An iron shield.
[ 7   174] An iron bracer.
[ 7   696] Chain sleeves.
[ 6  1393] An iron helm.
[ 6   348] Black boots.
[ 6   696] Iron gauntlets.
[ 5   522] Mail leggings.


I suspect there will be a line like this that is relevant ...


 level       = UMIN(5, level);


In fact I found such a line in magic.c however I don't think it is relevant to this particular case.

- Nick Gammon

www.gammon.com.au, www.mushclient.com
Top

Posted by Garaelb   (54 posts)  Bio
Date Reply #4 on Mon 28 Jul 2003 04:51 PM (UTC)
Message
Thanks Nick.

I was starting to guess that it was one of those hard coded features of the game. My players are entering the world nekid and without weapons. Level 5 is a long way to go to get a decent weapon to use. Well I guess I'l just have to make something to do that. I was hoping it could be a store as I hate to just GIVE away anything in the game. Maybe I can make a MOB or something to do that instead.

Thanks again Nick,

And you're much better than just a recruit. ;)

~G~
Top

The dates and times for posts above are shown in Universal Co-ordinated Time (UTC).

To show them in your local time you can join the forum, and then set the 'time correction' field in your profile to the number of hours difference between your location and UTC time.


15,087 views.

It is now over 60 days since the last post. This thread is closed.     Refresh page

Go to topic:           Search the forum


[Go to top] top

Information and images on this site are licensed under the Creative Commons Attribution 3.0 Australia License unless stated otherwise.