• There is NO official Otland's Discord server and NO official Otland's server list. The Otland's Staff does not manage any Discord server or server list. Moderators or administrator of any Discord server or server lists have NO connection to the Otland's Staff. Do not get scammed!

So I'm in the process of designer an RPG server

Attributes could be added to the market easily but they won't be visible in the market due to client limitations. There are three solutions for that:
- remove all attributes when item is added to the market(current)
- prevent adding modified items to the market
- add new column to database and script it in sources(attributes still won't be visible so it will be blind buying)

@Flatlander
It was said here first:
https://github.com/otland/forgottenserver/issues/42
 
See iomarket.cpp
Id, amount, price, player, anonymous(t/f), creation date
Nothing else can be sent
 
Can't you "look" at an item in the market? Or at least see the stats of an item? Or do you just have to know off the top of your head what each item is. (I haven't used the marketplace in forever)
Idk how to use look in market. It never worked to me even on global.
If you let me know which function from protocolgame.cpp is called when player use look in market I will see what can be done with that.
 
Last edited:
I can be wrong, but nobody did item attributes yet ( custom ), it seems more hard because of the Market, it will need keep the custom attributes when sold for someone...
btw TFS 1.1 release will be a Server for Real and Custom server, but for now it need more time for grow.

https://github.com/EvilHero90/forgottenserver/commit/e09d04eaa283354a9ab6ff34ab7b027b794cd50f
https://github.com/EvilHero90/forgottenserver/commit/062b8b265a8d1e11127445a76f6fc23a8fdb3be0

Two above are done perfectly with 1.0 for item attributes,

https://github.com/Zbizu/forgottenserver/commit/1c7b55b34d04572de37ceb4d307bfe7c9f915e82
https://github.com/Zbizu/forgottenserver/commit/511dc0abe258a0ebd1a551619f72a7cc83d50fed

These two above work for 1.1 (work in progress)

For more custom work that is being done with 1.0 and 1.1 just take a look at these...

https://github.com/EvilHero90/forgottenserver/commit/191023a11d723d495f57ae61adbcb3015f67dd87 --- player:setRate:(), player:getRate:()

https://github.com/EvilHero90/forgottenserver/commit/ad6907e7abbaefba6f7bf01a4453883ae810a6a0 -- player:setRate:(), player:getRate:()

https://github.com/EvilHero90/forgottenserver/commit/7774c30fb9e4fb91ac1fd6f9c52e1372d3f6c02e --- onHear, onAttack, onTarget, onChangeOutfit

https://github.com/EvilHero90/forgottenserver/commit/2cdc31b92df9e54e385a64a4619520e4f6504fef -- skill requirements for spells....

https://github.com/EvilHero90/forgottenserver/commit/7300ab6b514052f3bcdca222705d329eeb2caa88 --- isAbleToWalk() canWalk()

https://github.com/EvilHero90/forgottenserver/commit/58c2d8a00079e790f54ac5e1cb0491c2851ac89e -- custom loot drops for monsters.xml

https://github.com/EvilHero90/forgottenserver/commit/87da5372cf98e3a52e02b5d1437f8d1c6253556c -- working stamina for config.lua

Those are of course from Evil Hero, and his fork is from an older commit of 1.0, however, alot of those are very easy to add in.

Also if you guys were keeping up with 1.1 you would have found many MANY advantages that 1.1 has already over just a version of 1.0 that is only three or more months old, SOOO much has been fixed, updated, optimized and otherwise improved or implemented....

Just saying...

@Flatlander yes you may be correct in saying that as far as functionality goes, 1.0 and 1.1 are lacking in that department in comparison to some other versions like lets say 0.4. However, there are currently 192 forks from 1.0+ and I believe that soon it will be that many like evil hero and others are going to have their own distribution to release based off of the more stable 1.0+ and will include many of the functions that people miss, or that 1.0+ lacks...
 
To be honest average player won't give a single fuck about lack of functionality in 1.x versions. It can do everything what it should. Good scripters can do workarounds for almost every 0.4 script. onCombat was added today. Now only item attributes are missing and some of them were posted already.
 
You make me sad. Because I know you are mostly right.
I will agree that the average OT Player does not care about custom content. But to me that is no excuse for not having it.

If you have to make something anyway, why not make it so you can manage it from LUA rather than requiring source edits?

And it isn't just item attributes, I can do many things with 0.4 that you cannot do in 1.0.

And if you check my comment's Customizing TFS thread, I can do many things in my TFS you cannot do in 0.4.

I just hate going SO far backwards in time, into the stone age of functionality.

One thing, he didn't say that the average player wouldn't care about custom content, he said functionality. Try to remember that the average ot-player doesn't really know much about any of it, lua, xml, c++. They only know what they see in the game. With the basics from 1.1 it is still very possible for TONS of custom content. I have an example of that right this minute with the server I have been developing for quite a while on my own. You can even see some of the things I have released right in my signature. Granted that is not advanced like the vision you see for theImaginedServer, and theImaginedClient. Doesn't have custom creature AI and all kinds of amazing things I have seen you working on and implementing in your server. However lets be completely honest, the way it works is this;

1.Typical Users of OT forums: Most server downloaders don't know much about even how to set one up, let alone the programming languages used. They usually start like this and this still holds the bulk of the amount of users on OT forums. //// These users wouldn't know what to do with the extra functionality.

2. Intermediate Users of OT forums: Those are the ones who have advanced passed the point of just being able to copy and paste some released codes. They can usually read and alter code to fit their needs. At this point they can start building different servers, however not really all that advanced, or unique (definitely not imaginedserver status). But many users on this level continue to strive to become better. Some even design some systems, functions, or otherwise scripts in lua that may benefit the whole community. //// These users would love all the functionality they can get, but a lot also would not like to lose stability and support.

3. Advanced users: these users have either started off at this level from previous experience, or they moved here from: Intermediate Users of OT forums: They can now read and write in lua fluently. Some hang around the forums just reading the support sections and trying to find fixes for the rest of the users having problems. They can atleast read and understand C++ on a higher level than most users on the forums, and with that the may try to make their own source codes and move their abilities towards that direction. //// These users can already implement more functionality to the source from altering code from others, or creating their own.
 
I haven't really read everybody's comment, but I'm seeing that custom item attributes in 1.0 is "impossible" at this point.
While it's not exactly like 0.4, you can still develop your own custom attribute system in Lua.

I'm assuming that most items you're going to apply custom attributes to are not writables.
I've made myself a system that allows me to create my own attributes and apply them when necessary.
This can be done using the ITEM_ATTRIBUTE_TEXT attribute to store a string, that will be regex'd.

For example, let's say I have an attribute called 'ownership', which would be the name of the owner of the item, let's say a weapon.
You would set the item's ITEM_ATTRIBUTE_TEXT attribute value to something like "|ownership:Evan|".
Of course, you'd need to develop your own regex system that would allow you to append further attributes, read the values, and set values.
No one can read the ITEM_ATTRIBUTE_TEXT string (which I mentioned already, only if the item is not a writable).

This works perfectly fine, it's also a great alternative until it's officially pushed as a feature in 1.1.
Sometimes you have to be creative, sometimes you have to think, and sometimes there are no shortcuts.
 
I think the point is if someone need a Custom Server like Pokemon, he will need a TFS 0.3 or 0.4 because TFS 1.0 don't have custom attributes yet and it is a key function for all pokemon servers, alright you can do that with C++ knowledge, but C++ don't is too easy for all users which already know Lua well start learn and in 2-3 month do that ( some of them don't have time for it too ).
Lua is very easy and custom servers can be extensible and customizable because of key functions like item attributes and other things.
Yes, i know TFS 1.0 is better, but for some users TFS 0.3 and 0.4 is the best for now, what they need is that and nothing more.
 
I haven't really read everybody's comment, but I'm seeing that custom item attributes in 1.0 is "impossible" at this point.
While it's not exactly like 0.4, you can still develop your own custom attribute system in Lua.

I'm assuming that most items you're going to apply custom attributes to are not writables.
I've made myself a system that allows me to create my own attributes and apply them when necessary.
This can be done using the ITEM_ATTRIBUTE_TEXT attribute to store a string, that will be regex'd.

For example, let's say I have an attribute called 'ownership', which would be the name of the owner of the item, let's say a weapon.
You would set the item's ITEM_ATTRIBUTE_TEXT attribute value to something like "|ownership:Evan|".
Of course, you'd need to develop your own regex system that would allow you to append further attributes, read the values, and set values.
No one can read the ITEM_ATTRIBUTE_TEXT string (which I mentioned already, only if the item is not a writable).

This works perfectly fine, it's also a great alternative until it's officially pushed as a feature in 1.1.
Sometimes you have to be creative, sometimes you have to think, and sometimes there are no shortcuts.

Great minds think alike! I was also utilizing the text attribute for a weapons leveling system. However, I didn't complete it, I would rather just work on other things and wait for tfs team to finish the development. It really needs the ability to set custom attributes as it was before. However unique id's also serve their purpose :D
 
@Flatlander Mark is aware that custom attributes is wanted (like you described), so is Dalkon.
But in addition to custom attributes, these other ones like attack, armor, defense, etc. were still needed. I'd be patient.

I should mention that this recent commit is still under construction and is not recommended to be used.
Mark mentioned on GitHub that these 10 new attributes "aren't serialized/unserialized yet though, I'll follow up with another commit to add that shortly."
 
That is fine and all, and that helps... some people.
I think it is done wrong from the start.

We shouldn't make a list of attributes:
Armor, Defense, Attack, Hitchance, Shootrange, etc.
Then say "only these exist"

We should make the ability to set ANY Attribute (any string as the key within a character limit)
Armor, SexyPoints, MissChance, ArmorPeircing, Defense, Attack, Experience, PokemonLevel, VirginityDamage, WhateverTheHellYouWant, etc
And you'd still be able to use armor, defense, attack, etc the same way it is already used, but why set a limitation in the first place?

I agree, but they still have to make sure that the ones they made can be used with the items already stored values. Making a new one like "virginityDamage", that attribute isn't already built into the item, so this is a great start.
 
Back
Top