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 ➜ MUSHclient ➜ Development ➜ Scripting engine refactoring?

Scripting engine refactoring?

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


Pages: 1  2  3  4 

Posted by Nick Gammon   Australia  (23,165 posts)  Bio   Forum Administrator
Date Reply #45 on Sun 12 Sep 2010 09:47 PM (UTC)
Message
One last point though, I have had people on this forum before who have been highly enthusiastic, made great suggestions, and in many ways contributed to the client.

Then after three to five years they get a job, move overseas, get married, have children ... something. Maybe they just lose interest. Then we never hear from them again.

If the code is changed in major ways, so that I no longer can understand it, and also the person who makes such changes goes on to greater things (maybe they become a 3D programmer for the newest MMO game!) then no-one knows how to support the client. Such a scenario might arise in the next five years, for example.

So in this situation there is a difference between people understanding the existing code (then either they or I can support it in five years) or changing it so that only they can support it.

- Nick Gammon

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

Posted by Twisol   USA  (2,257 posts)  Bio
Date Reply #46 on Sun 12 Sep 2010 09:48 PM (UTC)

Amended on Sun 12 Sep 2010 09:53 PM (UTC) by Twisol

Message
Nick Gammon said:
Interestingly, that slowed you down a couple of days, and there is regrettably no way of knowing how many other such cases will arise, with open-ended time-frames to solve.

Actually, I bought two new games from Steam, and I've been playing them when I need to mull things over. A bigger roadblock caused a correspondingly bigger delay. (And they're fun, too!)

Nick Gammon said:
The ideal case would be that you promptly, efficiently and without bugs refactor the code so it is much simpler, but continues to work with existing triggers, plugins etc.

That is truly my goal. So long as I keep the public API unchanged, all I need to do is keep myself from introducing odd bugs. Last night I fixed an issue caused by my lack of total understanding of auto_ptr: I was initializing it explicitly with NULL, which apparently is bad. Creating one via the default constructor does the same thing, and doesn't cause a crash. :S

I think the lesson here is to be extremely careful with building blocks I've never used before.

'Soludra' on Achaea

Blog: http://jonathan.com/
GitHub: http://github.com/Twisol
Top

Posted by Twisol   USA  (2,257 posts)  Bio
Date Reply #47 on Sun 12 Sep 2010 09:51 PM (UTC)

Amended on Sun 12 Sep 2010 10:03 PM (UTC) by Twisol

Message
Nick Gammon said:
So in this situation there is a difference between people understanding the existing code (then either they or I can support it in five years) or changing it so that only they can support it.

The latter case is more of a fork, because I know you won't pull in changes you can't support. ;) Hence, the onus is on me to produce code you can support, else my work will go to waste.

I might also add that I think the codebase is currently leaning slightly towards the "only you can support it" side of things. :)

[EDIT]: Of course, I need to know what changes you can support, and I can only know that if you're willing to give feedback on a changeset when it's ready for review.

'Soludra' on Achaea

Blog: http://jonathan.com/
GitHub: http://github.com/Twisol
Top

Posted by Twisol   USA  (2,257 posts)  Bio
Date Reply #48 on Thu 16 Sep 2010 01:04 AM (UTC)
Message
Okay, I've gone through this iteration a ways, and I'm hitting a few bumps that aren't issues with just CScriptEngine alone. CallPlugin, for example: I'm not honestly sure how the arguments would be passed in. I could define some kind of union type - MUSHScriptVar? - and have a list of those passed in, and that would do it, but that would also cut off the lua_xmove() technique CallScript currently uses between two Lua stacks.

Anyways, I think I'm going to take a breather right now, and look at other parts of the code. I'm not used to working so long on a single task, heh. At least I learned a lot about how the scripting internals work!

'Soludra' on Achaea

Blog: http://jonathan.com/
GitHub: http://github.com/Twisol
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.


158,416 views.

This is page 4, subject is 4 pages long:  [Previous page]  1  2  3  4 

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.