ASECO 2.2.2 and stuff
Moderators: Flo, f*ckfish, Assembler Maniac, TM-Patrol
-
- Pit Crew
- Posts: 1493
- Joined: 03 Jun 2006 13:24
- Owned TM-games: TMU
- Contact:
ASECO 2.2.2 and stuff
Ok everyone, I'm back.
I'm in the process of editing the dedimania files for format, completeness and removing extra (unused) vars.
This may take me a few days, but I'm also going to shrink the DM zip file so it only contains the needed files. W1lla, I'll send you a link to it so you can compare to your copy before I release 2.2.2).
In the process I'll be editing ASECO itself for some open items.
I'm not likely to be able to keep track of every single thing I change, but they should all be for the better.
Questions? Comments? Ideas? Changes you've made? ---- Post 'em here. I'll delete any posts that aren't related directly to a problem or suggestion or change.
Have at it.
I'm in the process of editing the dedimania files for format, completeness and removing extra (unused) vars.
This may take me a few days, but I'm also going to shrink the DM zip file so it only contains the needed files. W1lla, I'll send you a link to it so you can compare to your copy before I release 2.2.2).
In the process I'll be editing ASECO itself for some open items.
I'm not likely to be able to keep track of every single thing I change, but they should all be for the better.
Questions? Comments? Ideas? Changes you've made? ---- Post 'em here. I'll delete any posts that aren't related directly to a problem or suggestion or change.
Have at it.
Re: ASECO 2.2.2 and stuff
Welcome back, AM!!!
Hmm... got a list around here somewhere, hehe
Can wait till tomorrow, though... Go Orlando!
Edit: Here's a start... been sitting around on my desktop for awhile now...
On top of that... fixed player object, make the isAdmin function generic when no authitem given (instead of relying on SuperAdmin authitem), and pass/cancel buttons for admins on the vote popup. I'd give my code, but sure you can do it better, hehe...

Hmm... got a list around here somewhere, hehe

Can wait till tomorrow, though... Go Orlando!

Edit: Here's a start... been sitting around on my desktop for awhile now...
Code: Select all
// ===============================================================================================================
// Hack to change position of PB/Rec window to bottom right,
// and display player's rec number if any
// plugin.rasp.php
// Line 307-316 (replacement) -- Widens the content boxes
function makePbWinContent($data)
{
$content = "<line height='.031'>
<cell width='.05'><text halign='right' textcolor='eee'>PB:</text></cell>
<cell width='.2'><text textcolor='ddd'> " . $data . "</text></cell></line>
<line height='.031'>
<cell width='.05'><text halign='right' textcolor='eee'>Rec:</text></cell>
<cell width='.11'><text textcolor='ddd'> " . $this->formatScore($this->besttime) . "</text></cell></line>";
return $content;
} // setPbWinData
// Line 342 (replacement) -- Change 'UNRANKED' to '--', so it fit's in the content box
$ret['rank'] = '--';
// Line 369 (replacement) -- adds the rank to the window content
$content = $this->makePbWinContent($this->formatScore($ret['time']).' ['.$ret['rank'].']');
// Line 390-392 (replacement) - Change's the location, and removes box
$window = $this->createWindowToPlayerFramework('', -.815, -.515, $player, true);
$window->setContent($content);
$window->setBackground('6660');
// ===============================================================================================================
// Karma table cleanup for missing players/challenges
// plugin.rasp_karma.php Line 77 (insert)
// Cleanup Karma rows for missing players/challenges
$this->Aseco->console_text('[RASP Karma] Cleaning up unused data...');
$sql = 'DELETE FROM rs_karma where not exists (select Id from players p where p.Id=rs_karma.PlayerID)';
mysql_query($sql);
$sql = 'DELETE FROM rs_karma where not exists (select Id from challenges c where c.Id=rs_karma.ChallengeID)';
mysql_query($sql);
// ===============================================================================================================
- oliverde8
- solid chaser
- Posts: 1135
- Joined: 07 Oct 2006 07:03
- Owned TM-games: TMU
- Manialink(s): oliverde8
- Location: Turkey
- Contact:
Re: ASECO 2.2.2 and stuff
yeaaah 
TrackMania.BeginRace => Must send as event OnBeginRace
TrackMania. BeginChallenge => Must send OnNewChallange event
Since the new dedicated works with this and not the old, maybe a dedicated version control
A little option to hide Rasp Windows. not an in game option, fufi widgets show the same so I commented all the lines of that an option would be easier

^^Need to update executeCallbacks()hal|Sascha wrote:So now the callbacks if server is running with WarmUp is like the following:
A. WarmUp
A.1. BeginChallenge()
A.2. BeginRace()
A.3. EndRace()
B. Race
B.1. BeginRace()
B.2. EndRace()
B.3. EndChallenge()
TrackMania.BeginRace => Must send as event OnBeginRace
TrackMania. BeginChallenge => Must send OnNewChallange event
Since the new dedicated works with this and not the old, maybe a dedicated version control
A little option to hide Rasp Windows. not an in game option, fufi widgets show the same so I commented all the lines of that an option would be easier
- w1lla
- TM-Patrol
- Posts: 1466
- Joined: 23 May 2007 07:20
- Owned TM-games: TMU, TMN, TMF
- Manialink(s): intr
- Location: Venray
Re: ASECO 2.2.2 and stuff
The addition of adding tmu and nation in the database of aseco....
When players connect or reconnect on a daily basis.
remove or edit plugin.tmxlinker.php for all tmx websites....
For dedimania might be nice if plugin.rasp_cptimes is included or it depends on it.
Make a report rounds plugin.... could be a nice basis for players because now no reports of the rounds are being done.
Karma vote with one of the Function keys could be quite nice....
Thats about it what i have.
When players connect or reconnect on a daily basis.
remove or edit plugin.tmxlinker.php for all tmx websites....
For dedimania might be nice if plugin.rasp_cptimes is included or it depends on it.
Make a report rounds plugin.... could be a nice basis for players because now no reports of the rounds are being done.
Karma vote with one of the Function keys could be quite nice....
Thats about it what i have.
Code: Select all
tmnforever is nations and united makes it special. tmnforever has united. I need united!
- oliverde8
- solid chaser
- Posts: 1135
- Joined: 07 Oct 2006 07:03
- Owned TM-games: TMU
- Manialink(s): oliverde8
- Location: Turkey
- Contact:
Re: ASECO 2.2.2 and stuff
The TMX info plugin already does the work of tmxlinker if tmxlinker is desactivatedw1lla wrote: remove or edit plugin.tmxlinker.php for all tmx websites....
- w1lla
- TM-Patrol
- Posts: 1466
- Joined: 23 May 2007 07:20
- Owned TM-games: TMU, TMN, TMF
- Manialink(s): intr
- Location: Venray
Re: ASECO 2.2.2 and stuff
ah ok...
nice job on that oliverde then that plugin can be removed i suppose.
All in favor say... Yarrr.
nice job on that oliverde then that plugin can be removed i suppose.
All in favor say... Yarrr.
Code: Select all
tmnforever is nations and united makes it special. tmnforever has united. I need united!
Re: ASECO 2.2.2 and stuff
I couldn't get that plugin to work properly, btw... Needed to update the tmxfetcher, then change a few urls.oliverde8 wrote:The TMX info plugin already does the work of tmxlinker if tmxlinker is desactivatedw1lla wrote: remove or edit plugin.tmxlinker.php for all tmx websites....
- oliverde8
- solid chaser
- Posts: 1135
- Joined: 07 Oct 2006 07:03
- Owned TM-games: TMU
- Manialink(s): oliverde8
- Location: Turkey
- Contact:
Re: ASECO 2.2.2 and stuff
OO I thinked I had do that with version 1.33. now I see I hadn't update the zip file with the new filenocturne wrote:I couldn't get that plugin to work properly, btw... Needed to update the tmxfetcher, then change a few urls.oliverde8 wrote:The TMX info plugin already does the work of tmxlinker if tmxlinker is desactivatedw1lla wrote: remove or edit plugin.tmxlinker.php for all tmx websites....
I will make an update.
- oliverde8
- solid chaser
- Posts: 1135
- Joined: 07 Oct 2006 07:03
- Owned TM-games: TMU
- Manialink(s): oliverde8
- Location: Turkey
- Contact:
Re: ASECO 2.2.2 and stuff
Ending vote on end of newchallange not on end of the challange. people votes during the chat time and the vote continues on thenext track after .
-
- Pit Crew
- Posts: 1493
- Joined: 03 Jun 2006 13:24
- Owned TM-games: TMU
- Contact:
Re: ASECO 2.2.2 and stuff
Describe this better please, I can't quite understand when/what you mean.oliverde8 wrote:Ending vote on end of newchallenge not on end of the challenge. people votes during the chat time and the vote continues on the next track after .
Also from prev post:
Fix player object how?oliverde8 wrote:On top of that... fixed player object, make the isAdmin function generic when no authitem given (instead of relying on SuperAdmin authitem), and pass/cancel buttons for admins on the vote popup. I'd give my code, but sure you can do it better, hehe...
How can you make the isAdmin function generic? If there's no auth item, how do you figure out who has access to it?
Admin vote pass/cancel buttons added - good idea, thx.
Re: ASECO 2.2.2 and stuff
I meant the player class... half of it just isn't TMF-relevant. There's been discussions on this before, and various ppl have posted their fixes...Assembler Maniac wrote:Also from prev post:Fix player object how?nocturne wrote:On top of that... fixed player object, make the isAdmin function generic when no authitem given (instead of relying on SuperAdmin authitem), and pass/cancel buttons for admins on the vote popup. I'd give my code, but sure you can do it better, hehe...
How can you make the isAdmin function generic? If there's no auth item, how do you figure out who has access to it?
Generic isAdmin check, as in... if they are on any of the admin lists, return a positive. As it stands, the SuperAdmin authitem controls everything from not getting booted on idle to editting sensitive server settings. If all else fails, why not just copy Fufi's isAnyAdmin funtion into the core Aseco..?
Was going to mention that too... I switched the player class to save the player's 'game' column as either TMU or TMF according to 'OnlineRights', but had to change dozens of queries along the lines of 'select * from players p where p.login='.$xxx.' and p.game='.quotedString($this->Aseco->server->getGame())... I could see the desire to have the option to use the same tables for older servers, but the ranks table would still be conflicting and the times would be skewed by tmf phsyics.w1lla wrote:The addition of adding tmu and nation in the database of aseco....
Last edited by nocturne on 15 Jun 2009 07:40, edited 1 time in total.
- oliverde8
- solid chaser
- Posts: 1135
- Joined: 07 Oct 2006 07:03
- Owned TM-games: TMU
- Manialink(s): oliverde8
- Location: Turkey
- Contact:
Re: ASECO 2.2.2 and stuff
The votes ends at end challange. Once it ended some people votes again to try to restart the track during the chat time, but after the vote continues on the next track and the wrong track is queed in the JB. it would be nice that the vote is cancelled on TrackMania.BeginRaceAssembler Maniac wrote:Describe this better please, I can't quite understand when/what you mean.oliverde8 wrote:Ending vote on end of newchallenge not on end of the challenge. people votes during the chat time and the vote continues on the next track after .
Code: Select all
case 'TrackMania.BeginRace' :
$before = memory_get_usage();
$this->beginRace($call[1]);
$after = memory_get_usage();
// view debug information ...
$this->console_debug("BeginRace ate " . ($after - $before) . " bytes");
if ($this->_vote_in_progress)
$this->callVoteDone(false); // if it's still in progress, then it hasn't passed, to kill it
break;
case 'TrackMania.EndRace' :
$before = memory_get_usage();
$this->endRace($call[1]);
$after = memory_get_usage();
if ($this->_vote_in_progress)
//$this->callVoteDone(false); // if it's still in progress, then it hasn't passed, to kill it
$this->callVoteUpdate();
// view debug information ...
$this->console_debug("EndRace ate " . ($after - $before) . " bytes");
break;
Re: ASECO 2.2.2 and stuff
Fufi didn't write that, it's a core XAseco function by yours truly, and as simple as this:nocturne wrote:If all else fails, why not just copy Fufi's isAnyAdmin funtion into the core Aseco..?
Code: Select all
function isAnyAdmin($player) {
return ($this->isMasterAdmin($player) || $this->isAdmin($player) || $this->isOperator($player));
} // isAnyAdmin
Developer of XASECO for TMF/TMN ESWC & XASECO2 for TM²: see XAseco.org
Find your way around the Mania community from the TMN ESWC hub, TMF hub, TM² hub, and SM hub
Find your way around the Mania community from the TMN ESWC hub, TMF hub, TM² hub, and SM hub
-
- Pit Crew
- Posts: 1493
- Joined: 03 Jun 2006 13:24
- Owned TM-games: TMU
- Contact:
Re: ASECO 2.2.2 and stuff
Ok, the callVoteDone will be on the NewChallenge event.oliverde8 wrote:The votes ends at end challange. Once it ended some people votes again to try to restart the track during the chat time, but after the vote continues on the next track and the wrong track is queed in the JB. it would be nice that the vote is cancelled on TrackMania.BeginRace
Code: Select all
case 'TrackMania.BeginRace' : $before = memory_get_usage(); $this->beginRace($call[1]); $after = memory_get_usage(); // view debug information ... $this->console_debug("BeginRace ate " . ($after - $before) . " bytes"); if ($this->_vote_in_progress) $this->callVoteDone(false); // if it's still in progress, then it hasn't passed, to kill it break; case 'TrackMania.EndRace' : $before = memory_get_usage(); $this->endRace($call[1]); $after = memory_get_usage(); if ($this->_vote_in_progress) //$this->callVoteDone(false); // if it's still in progress, then it hasn't passed, to kill it $this->callVoteUpdate(); // view debug information ... $this->console_debug("EndRace ate " . ($after - $before) . " bytes"); break;
I'm going to code up a server version test too. At this point, there's too many changes to try and keep it compatible with old server versions anyway.
What parts of the player class aren't TMF relevant? (keep in mind I haven't been following the forum discussions unless it was a basic question to be answered)nocturne wrote:I meant the player class... half of it just isn't TMF-relevant. There's been discussions on this before, and various ppl have posted their fixes...
Generic isAdmin check, as in... if they are on any of the admin lists, return a positive. As it stands, the SuperAdmin authitem controls everything from not getting booted on idle to editting sensitive server settings. If all else fails, why not just copy Fufi's isAnyAdmin funtion into the core Aseco..?
As for the isAdmin function, I'm not sure you realize what you're asking. Say someone writes a new cmd/function that allows deletion of a player & their records, but doesn't have an assigned admin level. With your request in place, even the lowest admin level possible would have the ability to execute the command.
The whole point of the admin level assignment is to prevent people from doing things they're not supposed to be doing. What you're asking for is to assume "any admin" when the system is specifically designed for "assume the worst, allow only superadmin".
And for everyone: I'm going to be posting an announcement with some guidelines for authoring plugins for ASECO 2.x. I've seen some not so great coding in the plugins I've been working on, and it bugs me a little that it could be better.
Re: ASECO 2.2.2 and stuff
Obviously the isAnyAdmin function wouldn't replace the existing system, and has fairly limited use as in most cases you will want to test for sufficient authorization, like you say.Assembler Maniac wrote:As for the isAdmin function, I'm not sure you realize what you're asking. Say someone writes a new cmd/function that allows deletion of a player & their records, but doesn't have an assigned admin level. With your request in place, even the lowest admin level possible would have the ability to execute the command.
The whole point of the admin level assignment is to prevent people from doing things they're not supposed to be doing. What you're asking for is to assume "any admin" when the system is specifically designed for "assume the worst, allow only superadmin".
But here's a simple example from XAseco where it is useful: /players outputs a list of nicknames and logins, and normal logins are shown in blue while admin ones are green. The function simply saves you doing isAdmin || isAdmin || etc. tests for however many admin levels there may be.
Developer of XASECO for TMF/TMN ESWC & XASECO2 for TM²: see XAseco.org
Find your way around the Mania community from the TMN ESWC hub, TMF hub, TM² hub, and SM hub
Find your way around the Mania community from the TMN ESWC hub, TMF hub, TM² hub, and SM hub