Author Topic: Out of game Server list  (Read 1934 times)

A cool poem by me

Roses are blocks

we are not

yeh we are i just forgot

but this poem is as boring as a rock

A cool poem by me

Roses are blocks

we are not

yeh we are i just forgot

but this poem is as boring as a rock
Random posting is fun!

Only the most recently activated package on that function will be used

Wow. No. This is conclusive proof that you should not be messing around with packages - especially those that affect the core parts of RTB.

You gave your own server an honor!

You self-centered bitch.

"Red - BuB Reward - Server of Honor"

This is a handicapped feature.

"Red - BuB Reward - Server of Honor"

This is a handicapped feature.
come download bub and get endorsed by us

Also the website looks ugly.
Even I can make something much more appealing and I suck at almost all forms of web coding.

Also the website looks ugly.
Even I can make something much more appealing and I suck at almost all forms of web coding.
I'm in the works of redesigning the site.

Wow. No. This is conclusive proof that you should not be messing around with packages - especially those that affect the core parts of RTB.
I guess I just couldn't connect to RTB's api for no reason! I even asked you for help right after the release of V15, not knowing BuB was causing it. You told me the server never got my request. I merged the packages, came back to Badspot's server, and you called me a Liar when it successfully connected.

I guess I just couldn't connect to RTB's api for no reason! I even asked you for help right after the release of V15, not knowing BuB was causing it. You told me the server never got my request. I merged the packages, came back to Badspot's server, and you called me a Liar when it successfully connected.
You are doing something extremely wrong if you think RTB is causing problems with TCP objects.

You are doing something extremely wrong if you think RTB is causing problems with TCP objects.
Explain what is wrong.

Code: [Select]
package BuBSocket
{
function TCPObject::onConnected(%this)
{
if(%this.BuBsocket)
{
if(%this.Method $= "POST")
{
%data = %this.Method SPC %this.file @ " HTTP/1.1\nHost: " @ %this.host;
%data = %data @ "\r\nUser-Agent: Torque/1.0";
%data = %data @ "\r\nContent-Type: application/x-www-form-urlencoded";
%data = %data @ "\r\nContent-Length: " @ strlen(%this.data) @ "\r\n\r\n" @ %this.data @ "\r\n";
}
else
{
%data = %this.Method SPC %this.file @ %this.data @ " HTTP/1.1\nHost: " @ %this.host;
%data = %data @ "\n\n";
}

//echo("Data: " @ %data);
%this.send(%data);
}
if(isfunction(Parent,"onConnected"))
parent::onConnected();
}
function TCPObject::onLine(%this, %line)
{
if(%this.BuBsocket)
{
if(%line $= "END OF DATA")
{
%this.data = 0;
%this.disconnect();
%this.onDisconnect();
}
if(%this.data)
{
%this.response = %this.response @ %line @ "\n";
}
if(%line $= "START OF DATA")
{
%this.data = 1;
%this.response = "";
}
}
if(isfunction(Parent,"onLine"))
parent::onLine();
}
function TCPObject::onConnectFailed(%this)
{
if(%this.BuBsocket)
{
warn("BuB Socket Connection Failed");
}
if(isfunction(Parent,"onConnectFailed"))
parent::onConnectFailed();
}

function TCPObject::onDisconnect(%this)
{
if(%this.BuBsocket)
{
%this.active = 0;
%this.response = getsubstr(%this.response, 0, strlen(%this.response)-1);
echo(%this.response);
if(isfunction("BuB_C_Response_" @ %this.subclass))
eval("BuB_C_Response_" @ %this.subclass @ "();");
}
if(isfunction(Parent,"onDisconnect"))
parent::onDisconnect();
}
};
activatepackage(BuBSocket);

Explain what is wrong.

You can't use isFunction like that. It will return false.

You can't use isFunction like that. It will return false.
Funny, have you ever looked at the RTB Package? Here is one I found:

Code: [Select]
if(isFunction(Parent,"onDNSFailed"))
            Parent::onDNSFailed(%this);

Either RTB is wrong, or you are.
« Last Edit: November 17, 2010, 07:29:08 PM by Scout31 »

Funny, have you ever looked at the RTB Package? Here is one I found:
Either RTB is wrong, or you are.

Sorry, I hadn't seen your response.

Quote
==>new ScriptObject(ExampleObj);
==>function ExampleObj::two(%this) { echo(2); }
==>ExampleObj.two();
2
==>package one { function ExampleObj::two(%this) { echo(1); if(isFunction(Parent,"two")) Parent::two(%this); } };
==>activatepackage(one);
Activating package: one
==>ExampleObj.two();
1
==>package one { function ExampleObj::two(%this) { echo(1); Parent::two(%this); } };
==>ExampleObj.two();
1
2

So the code I got from RTB was a fail. Ephi, you may want to look at that again.

So the code I got from RTB was a fail. Ephi, you may want to look at that again.

That's why you shouldn't be blindly copying people's code then, I guess.

It doesn't matter for RTB because it gets executed before all other add-ons - so this is your problem to solve.
« Last Edit: November 18, 2010, 03:21:05 AM by Ephialtes »