The following warnings occurred:
Warning [2] Use of undefined constant SAPI_NAME - assumed 'SAPI_NAME' (this will throw an Error in a future version of PHP) - Line: 3388 - File: inc/functions.php PHP 7.4.33-nmm7 (Linux)
File Line Function
/inc/functions.php 3388 errorHandler->error
/showthread.php 116 build_archive_link
Warning [2] Use of undefined constant IN_ARCHIVE - assumed 'IN_ARCHIVE' (this will throw an Error in a future version of PHP) - Line: 3331 - File: inc/functions.php PHP 7.4.33-nmm7 (Linux)
File Line Function
/inc/functions.php 3331 errorHandler->error
/inc/functions.php 3324 build_forum_breadcrumb
/showthread.php 195 build_forum_breadcrumb
Warning [2] Use of undefined constant IN_ARCHIVE - assumed 'IN_ARCHIVE' (this will throw an Error in a future version of PHP) - Line: 3331 - File: inc/functions.php PHP 7.4.33-nmm7 (Linux)
File Line Function
/inc/functions.php 3331 errorHandler->error
/showthread.php 195 build_forum_breadcrumb






Post Reply 
 
Thread Rating:
  • 1 Votes - 5 Average
  • 1
  • 2
  • 3
  • 4
  • 5
New Features Request
Author Message
Khaos
Master
**

Posts: 595
Likes Given: 166
Likes Received: 83 in 51 posts
Joined: Mar 2012
Reputation: 11



Post: #68
RE: New Features Request
Oh I understand that and it really depends. This comes back to an old argument of what else might be calling for those values. Though I don't plan on changing any hardcode to change this behavior in old code... it could happen (unlikely). Plus, when my pc is running (HDD is locked up from chkdsk and might be a bad windows file; ie I have to buy a new HDD to back mine up too and reformat) I am going to see how much code is being processed checking a MORE value and what it takes to store it. A tag is literally a byte per alphanumeric character you use. This can be really low in resource use.

Like I made a statement about vendors and like 500 of each item (even 50 is a lot). I can use one tag with 3 arguments in it. ItemID, Value, and Amount... and just that one line freed up 500 items. That is a lot of free memory and way less items. So even if you attached 50 tags to every player.. it still is not going to be as harsh on your server as 500 items in a vendor box for each item on a vendor.... on every vendor.

I would still use things like more and blank placeholders as such if you want. It might be easier just to remember a tag though when scripting without using a reference. I think that is more personal use. As I said, more could change in the hardcode one day... but most likely not. Again, preference.

If that does end up happening (using those empty slots for something else) I would give the community a weeks prior notice to get ready for it. I dont see it happening on my end though.

We can also look at small things as well with this. If you go the tag route; use small and conventional tag naming. tag0.reflectphysicaldamage=<value> uses more bytes that tag.reflectphysdam=<value> which also uses more bytes that tag0.rpd=<value>.

These are just small things to consider. I remember when I wasn't on the dev team; we were always told this was bad practice. If anyone remembers; Naz and I went round to round over things like this. Sometimes Naz was right; sometimes I could make a point or post one script and prove my point. Tags were never bad. They were bad back in the day with low rate PC hosts, buggy servers with memory leaks, and just limited usage of them. Now there is so many ways to take advantage of them; I suggest for people to reconsider their use. A tag is like making a definition or class in the hardcode. We do it with all programming. So why not use it to your advantage in softcoding? It could save you a lot of memory and create some really nice systems for yourself.
(This post was last modified: 09-13-2013 01:18 PM by Khaos.)
09-13-2013 01:11 PM
Find all posts by this user Like Post Quote this message in a reply
Post Reply 


Messages In This Thread
New Features Request - Extreme - 09-11-2012, 01:15 PM
RE: New Features Request - Shaklaban - 09-14-2012, 01:05 PM
RE: New Features Request - ShiryuX - 09-14-2012, 03:01 PM
RE: New Features Request - Extreme - 09-17-2012, 02:32 AM
RE: New Features Request - Gil Amarth - 09-14-2012, 09:36 PM
RE: New Features Request - darksun84 - 09-14-2012, 11:02 PM
RE: New Features Request - darksun84 - 10-29-2012, 01:35 AM
RE: New Features Request - darksun84 - 02-20-2013, 12:19 AM
RE: New Features Request - ShiryuX - 09-17-2012, 03:38 PM
RE: New Features Request - Rizz - 10-17-2012, 08:30 PM
RE: New Features Request - Anarch Cassius - 10-18-2012, 02:41 AM
RE: New Features Request - ShiryuX - 10-18-2012, 12:47 PM
RE: New Features Request - Shaklaban - 10-23-2012, 06:02 AM
RE: New Features Request - Lazarus - 10-25-2012, 05:22 PM
RE: New Features Request - Extreme - 10-26-2012, 12:18 AM
RE: New Features Request - Lazarus - 10-26-2012, 01:37 AM
RE: New Features Request - ShiryuX - 10-26-2012, 05:57 AM
RE: New Features Request - Lazarus - 10-26-2012, 08:50 AM
RE: New Features Request - Rizz - 10-26-2012, 11:22 PM
RE: New Features Request - Crusader - 01-19-2013, 05:33 AM
RE: New Features Request - Extreme - 10-27-2012, 12:28 AM
RE: New Features Request - Lazarus - 10-27-2012, 01:42 AM
RE: New Features Request - Extreme - 10-27-2012, 10:06 PM
RE: New Features Request - Rizz - 10-31-2012, 11:58 PM
RE: New Features Request - RanXerox - 11-01-2012, 01:59 AM
RE: New Features Request - Rizz - 11-01-2012, 02:29 AM
RE: New Features Request - ShiryuX - 11-01-2012, 02:40 AM
RE: New Features Request - Rizz - 11-01-2012, 09:23 PM
RE: New Features Request - Anarch Cassius - 11-02-2012, 12:26 PM
RE: New Features Request - Rizz - 11-03-2012, 04:29 AM
RE: New Features Request - Barnabus - 11-03-2012, 04:26 AM
RE: New Features Request - Rizz - 12-07-2012, 06:26 AM
RE: New Features Request - Rizz - 01-07-2013, 08:56 AM
RE: New Features Request - Ben - 01-19-2013, 09:09 AM
RE: New Features Request - Mordaunt - 01-19-2013, 09:25 AM
RE: New Features Request - Ben - 01-19-2013, 09:42 AM
RE: New Features Request - Rizz - 01-20-2013, 11:54 PM
RE: New Features Request - Ben - 01-21-2013, 09:45 AM
RE: New Features Request - Rizz - 01-21-2013, 10:54 AM
RE: New Features Request - Norlack - 02-01-2013, 11:09 PM
RE: New Features Request - Ultima One - 02-01-2013, 11:48 PM
RE: New Features Request - Mordaunt - 02-02-2013, 12:04 AM
RE: New Features Request - Norlack - 02-02-2013, 04:34 AM
RE: New Features Request - Shaklaban - 02-02-2013, 05:23 AM
RE: New Features Request - Crusader - 02-26-2013, 09:59 AM
RE: New Features Request - darksun84 - 03-13-2013, 04:12 AM
RE: New Features Request - Gil Amarth - 04-17-2013, 04:32 AM
RE: New Features Request - Coruja - 05-01-2013, 04:59 AM
RE: New Features Request - Rattlehead - 05-02-2013, 07:32 PM
RE: New Features Request - darksun84 - 05-02-2013, 08:58 PM
RE: New Features Request - Mordaunt - 05-02-2013, 10:21 PM
RE: New Features Request - Coruja - 05-05-2013, 06:19 PM
RE: New Features Request - Rattlehead - 05-02-2013, 11:46 PM
RE: New Features Request - Ben - 05-06-2013, 12:20 AM
RE: New Features Request - Coruja - 05-06-2013, 05:56 PM
RE: New Features Request - Ultima One - 05-10-2013, 10:22 AM
RE: New Features Request - Rizz - 05-19-2013, 08:59 PM
RE: New Features Request - Coruja - 05-23-2013, 02:58 AM
RE: New Features Request - RanXerox - 05-23-2013, 04:40 AM
RE: New Features Request - Coruja - 05-25-2013, 04:59 AM
RE: New Features Request - RanXerox - 05-25-2013, 08:21 AM
RE: New Features Request - Ben - 05-28-2013, 08:19 PM
RE: New Features Request - Coruja - 08-26-2013, 08:32 AM
RE: New Features Request - Rattlehead - 08-26-2013, 10:03 AM
RE: New Features Request - Coruja - 08-28-2013, 12:42 PM
RE: New Features Request - Khaos - 09-11-2013, 12:14 PM
RE: New Features Request - Rattlehead - 09-12-2013, 09:38 AM
RE: New Features Request - Khaos - 09-13-2013 01:11 PM
RE: New Features Request - XuN - 09-13-2013, 05:12 PM
RE: New Features Request - darksun84 - 09-13-2013, 05:45 PM
RE: New Features Request - XuN - 09-13-2013, 06:33 PM
RE: New Features Request - Rattlehead - 09-14-2013, 02:42 PM
RE: New Features Request - darksun84 - 09-19-2013, 12:48 AM
RE: New Features Request - amonvangrell - 09-19-2013, 07:06 AM
RE: New Features Request - Rizz - 10-17-2013, 08:41 AM
RE: New Features Request - RanXerox - 10-17-2013, 08:57 AM
RE: New Features Request - Rizz - 10-17-2013, 05:18 PM
RE: New Features Request - XuN - 10-17-2013, 06:07 PM
RE: New Features Request - Rizz - 10-17-2013, 07:25 PM

Forum Jump:


User(s) browsing this thread: 1 Guest(s)