Lua help

This is for troubleshooting of problems with the FAF client and Forged Alliance game.

Moderator: PhilipJFry

Lua help

Postby bk0 » 16 Jul 2012, 23:42

Hi there, sorry for the programmer question.

So I had a look at the FAF Game Lobby, in order to find out why it freezes. Turns out I'm stuck here:

Code: Select all
LobbyComm = Class(moho.lobby_methods) {

    # General events you should override
    #etc
}


I'd like to have a look at moho.lobby_methods, but can't find the class. Is there an easy way to find said class, without going through all the code?
I've never worked with LUA before, so any help is welcomed.

Greetings and Thanks
bk
bk0
 
Posts: 7
Joined: 08 Apr 2012, 14:28
Has liked: 0 time
Been liked: 0 time

Re: Lua help

Postby rootbeer23 » 17 Jul 2012, 00:03

bk0 wrote:Hi there, sorry for the programmer question.

So I had a look at the FAF Game Lobby, in order to find out why it freezes. Turns out I'm stuck here:

Code: Select all
LobbyComm = Class(moho.lobby_methods) {

    # General events you should override
    #etc
}


I'd like to have a look at moho.lobby_methods, but can't find the class. Is there an easy way to find said class, without going through all the code?
I've never worked with LUA before, so any help is welcomed.

Greetings and Thanks
bk


That class in implemented in C++ and is part of the moho engine. whenever a call to one of the methods is made,
the arguments are translated to C++ types (numbers are translated to int for example).
So everything there is basically off limits. The only way to work on the moho engine would be on the machine code
level (-> forget it).
rootbeer23
Supreme Commander
 
Posts: 1001
Joined: 18 May 2012, 15:38
Has liked: 0 time
Been liked: 31 times
FAF User Name: root2342

Re: Lua help

Postby Ze_PilOt » 17 Jul 2012, 00:27

It's not the FAF Game Lobby. It's FA engine. Even on GPGNET, people with badly configured router/firewall were making the lobby freezing, leading to some crashes if a lot of people were trying to log in during that time. It's not new, and not related to FAF or Power Lobby.

I don't know why it happens more on FAF, probably because I'm not using a relay for connecting players.
Nossa wrote:I've never played GPG or even heard of FA until FAF started blowing up.
User avatar
Ze_PilOt
Supreme Commander
 
Posts: 8985
Joined: 24 Aug 2011, 18:41
Location: fafland
Has liked: 18 times
Been liked: 376 times
FAF User Name: Ze_PilOt

Re: Lua help

Postby rootbeer23 » 17 Jul 2012, 00:31

Ze_PilOt wrote:It's not the FAF Game Lobby. It's FA engine. Even on GPGNET, people with badly configured router/firewall were making the lobby freezing, leading to some crashes if a lot of people were trying to log in during that time. It's not new, and not related to FAF or Power Lobby.

I don't know why it happens more on FAF, probably because I'm not using a relay for connecting players.


It did seem to get worse a month ago, so there is still hope that it can be worked around.
Do you mind explaining how the peers are connected with or without a relay.
rootbeer23
Supreme Commander
 
Posts: 1001
Joined: 18 May 2012, 15:38
Has liked: 0 time
Been liked: 31 times
FAF User Name: root2342

Re: Lua help

Postby bk0 » 17 Jul 2012, 00:43

Hm, or rewrite the connection part... we have to re-implement those native methods, using LUA (or C++ etc.)

Given how important they are, it might be worth a shot. I'll see what I can dig up, there should be standard code for this kind of stuff posted on the web...
bk0
 
Posts: 7
Joined: 08 Apr 2012, 14:28
Has liked: 0 time
Been liked: 0 time

Re: Lua help

Postby rootbeer23 » 17 Jul 2012, 01:38

bk0 wrote:Hm, or rewrite the connection part... we have to re-implement those native methods, using LUA (or C++ etc.)

Given how important they are, it might be worth a shot. I'll see what I can dig up, there should be standard code for this kind of stuff posted on the web...


i would not bother. it would be an order of magnitude less work to find the bug in the engine (the "forget it" part) than
to recode parts of it.
rootbeer23
Supreme Commander
 
Posts: 1001
Joined: 18 May 2012, 15:38
Has liked: 0 time
Been liked: 31 times
FAF User Name: root2342

Re: Lua help

Postby bk0 » 17 Jul 2012, 03:38

If we had the source code, probably. But disassembling C++ is not really something that I am going to do. Done it once, lost part of my sanity. Plus we don't know the bug is in the lobby_methods class, then we decompile a second, third class etc...

Probably simpler to set up a listener service, and query that one. But it would require someone who understands C++, LUA and the inner workings of SupCom in order to to it in a reasonable time. I'm fully booked as it is.

Well, sorry I can't be of more assistance.
bk0
 
Posts: 7
Joined: 08 Apr 2012, 14:28
Has liked: 0 time
Been liked: 0 time

Re: Lua help

Postby Ze_PilOt » 17 Jul 2012, 08:15

If you search the web, you will see that the bug is very present on demigod. If GPG didn't solved it in the next iteration of their engine, I highly doubt we will.

It get worst or better depending of the quality of the connection of the people joining. I have a friend with a difficult router. The lobby was freezing when he join, making others timing out. It usually didn't took long enough to crash the lobby, but it did sometimes.

Also, you probably NEVER want to alt-tab.
Nossa wrote:I've never played GPG or even heard of FA until FAF started blowing up.
User avatar
Ze_PilOt
Supreme Commander
 
Posts: 8985
Joined: 24 Aug 2011, 18:41
Location: fafland
Has liked: 18 times
Been liked: 376 times
FAF User Name: Ze_PilOt


Return to Tech Support

Who is online

Users browsing this forum: No registered users and 1 guest