[Xaseco] Nouse Betting V1.8.1

Discuss everything about Xymph's Aseco flavoured server control scripts for TM Forever / classic TMN and for TM² Canyon.

Moderators: Xymph, TM-Patrol

nouseforname
swift roadking
swift roadking
Posts: 840
Joined: 20 Apr 2008 08:58
Owned TM-games: TMUF,TMNF, TMN
Manialink(s): therookies
Location: Germany
Contact:

Re: [Xaseco] Nouse Betting V1.8

Post by nouseforname » 15 Jul 2012 18:19

You re right, my changes are wrong. and give totally no function.

But now i tried to check how its possible to change the height of betting stack with a donation. And i must say, even if i donate directly after betting, the stack is not changed. So i dont know how its possibel for now, i changed backto original state, which is running well since more then one year.

Sry for that, if there is somebody who is willling to test it, pls let me know if you can find some glitch.
Owner of the Rookie servers and some more. :)
Rookies HP
My Project
Rookies Manialinkcolor>

ChaoticAtmosphere
highway camper
highway camper
Posts: 3
Joined: 13 Nov 2009 02:23
Owned TM-games: TMN

Re: [Xaseco] Nouse Betting V1.8.1

Post by ChaoticAtmosphere » 16 Feb 2013 19:04

I know this topic has been inactive for a little while, but I'll posrt here anyway instead of starting a new thread.

I have donations and betting working on my server. However, since I've got the betting to work, when someone makes a donation, the confirmation and thank you messages in chat no longer work. People are telling me that they have to check their balances to make sure the transaction went through.

Also, I get these messages in chat saying. the command "admin" or "GG" is not a recognized command. I'm assuming that is also from the betting plugin.

Is there a way I can get this fixed?

Maniac_Lauterer
wheelbarrow operator
wheelbarrow operator
Posts: 21
Joined: 29 Oct 2013 09:13
Owned TM-games: TM2

Re: [Xaseco] Nouse Betting V1.8.1

Post by Maniac_Lauterer » 30 Oct 2013 20:49

Hi, can this script be used on Trackmania 2 with planets without changing anything from the instruction. Or do i have to change the mincoppers to minplanets? I do not get the the script work. It is there, it answers, so i can zurn it on or off with the admin chat command and it also answers that it will start next round but then nothing happens, no bet-panel appears. Come someone help me???

User avatar
undef.de
Pit Crew
Pit Crew
Posts: 1318
Joined: 31 Aug 2009 18:38
Owned TM-games: TMF, TM2C/S/V, SM
Manialink(s): undef, tmkarma
Location: Germany
Contact:

Re: [Xaseco] Nouse Betting V1.8.1

Post by undef.de » 30 Oct 2013 22:43

Maniac_Lauterer wrote:can this script be used on Trackmania 2
Nope, but there is a port for TM2: viewtopic.php?f=127&t=29414
Developer of various plugins for XAseco/XAseco2 and MPAseco,
like Records-Eyepiece, TM-Karma, Alternate Scoretable...
Visit my Lab: www.undef.name

Get it now:
» TM2 Valley
» TM2 Canyon
» TM2 Stadium
» SM Storm

NoTimeToDrive
wheelbarrow operator
wheelbarrow operator
Posts: 21
Joined: 31 Mar 2013 15:13
Owned TM-games: TMU TMUF

Re: [Xaseco] Nouse Betting V1.8.1

Post by NoTimeToDrive » 06 Jan 2018 18:37

Hi folks.

Best wishes for 2018 everybody :thumbsup:

It's a long time ago that here was a messages.
But...I'll have a question.

I try to make my betting panel a bit smaller.
Now it is in nouse_betting_config:
20c 50c 100c 250c 500c
so just orginal as it was.

Now i try to remove the 500c.
to make it smaller.
But the size stay the same.
And in stead 500c now it's 0c
I remove whole 5 line.
But that doesn't work i see...grrr

I read a lot here..to find what i can do to fix this.
But as always..I fail ;(

Can somebody help me maybe?
If you need more info..say so.
Thanks for reading.

Grt Ed

User avatar
L3cKy
happy cruiser
happy cruiser
Posts: 147
Joined: 05 Sep 2007 13:55
Owned TM-games: TMUF
Location: Berlin
Contact:

Re: [Xaseco] Nouse Betting V1.8.1

Post by L3cKy » 04 Mar 2018 08:56

A good idea would be to check for any connected tmu players on the server before doing a bet so that no coppers will be lost for a bet with only tmnf (free accounts) connected players.

NoTimeToDrive
wheelbarrow operator
wheelbarrow operator
Posts: 21
Joined: 31 Mar 2013 15:13
Owned TM-games: TMU TMUF

Re: [Xaseco] Nouse Betting V1.8.1

Post by NoTimeToDrive » 11 Mar 2018 09:44

Hey L3cKy.

Thanks for your respons.
If I read between the lines from your reply.
You think it's not save to use the bet plugin?
I'm taking your advice and kicked the plugin ;-)
Sometimes it was used..but not that much,
so i don't think we miss a lot.

Thanks again!

Grt Ed

User avatar
L3cKy
happy cruiser
happy cruiser
Posts: 147
Joined: 05 Sep 2007 13:55
Owned TM-games: TMUF
Location: Berlin
Contact:

Re: [Xaseco] Nouse Betting V1.8.1

Post by L3cKy » 11 Mar 2018 15:07

No no ^^
I mean to check for any other TMU Players on the Server before doing a bet because if you bet like 100 you wont get 100 back if no one accept the bet.

Was think about like this ^^

Code: Select all

// proceed chat command bet and get bill id
	function bet_command($command) {
		$player = $command['author']; 	// get author
		$login = $player->login; 		// get login of author
		$nickname = $player->nickname;	// get nickname
		$coppers = $command['params']; 	// get parameter
		
		// Check for any other TMU players
		$checker = 0;
		foreach ($this->Aseco->server->players->player_list as $playercheck) {
			if ($playercheck->rights) {
				$checker++;
			}
		}

		if ($this->Aseco->server->getGame() == 'TMF') {
			// check for TMUF server
			if ($this->Aseco->server->rights) {
				// check for TMUF player
				if ($player->rights) {
					// check if betting is enabled
					if ($this->enabled && $this->state) {
						// check for valid amount
						if ($coppers != '' && is_numeric($coppers)) {
							// check for betting time limit
							if (($this->countsec <= $this->timelimit_bet-2) && ($this->bet_active == 0)) {
								// check for minimum donation
								if ($coppers >= $this->minbet and $coppers <= $this->maxbet) {
									// check for double command
									if ($login != $this->bet_starter and !in_array($login, $this->acceptors)) {
										// check if more than one tmu players are connected
										if ($checker > 1) {
										// start the transaction
											$message = '$f80You have to pay '.$coppers.' coppers to set the next bet!$g$z'; // text in bill popup "start bet"
											$this->Aseco->client->query('SendBill', $login, (int)$coppers, $this->Aseco->formatColors($message), '');
											$billid = $this->Aseco->client->getResponse();
											$this->bets[$billid] = array($login, $nickname, $coppers, true);
										} else {
											$message = formatText('{#server}{#error}No players connected who can accept your bet!!!!');
											$this->Aseco->client->addCall('ChatSendServerMessageToLogin', array($this->Aseco->formatColors($message), $login));
										}
									}
									else {
										$message = formatText('{#server}{#error}You don\'t need to double click or double execute the chat command!!!!');
										$this->Aseco->client->addCall('ChatSendServerMessageToLogin', array($this->Aseco->formatColors($message), $login));
									}
								} else {
									$message = formatText('{#server}{#error}You\'ll have to set {#highlite}minimum '.$this->minbet.' {#error}coppers and not more than {#highlite}'. $this->maxbet .' {#error}to proceed the bet!');
									$this->Aseco->client->addCall('ChatSendServerMessageToLogin', array($this->Aseco->formatColors($message), $login));
								}
							} else {
								$message = formatText('{#server}{#error}Time limit for bet expired or bet already placed, wait till next round!');
								$this->Aseco->client->addCall('ChatSendServerMessageToLogin', array($this->Aseco->formatColors($message), $login));
							}
						} else {
							$message = formatText('{#server}{#error}No amount of coppers defined. Please use {#interact}"/bet [coppers]"');
							$this->Aseco->client->addCall('ChatSendServerMessageToLogin', array($this->Aseco->formatColors($message), $login));
						}
					} else {
						$message = formatText('{#server}{#error}Betting is disabled!');
						$this->Aseco->client->addCall('ChatSendServerMessageToLogin', array($this->Aseco->formatColors($message), $login));
					}
				} else {
					$message = formatText($this->Aseco->getChatMessage('UNITED_ONLY'), 'account');
					$this->Aseco->client->addCall('ChatSendServerMessageToLogin', array($this->Aseco->formatColors($message), $login));
				}
			} else {
				$message = formatText($this->Aseco->getChatMessage('UNITED_ONLY'), 'server');
				$this->Aseco->client->addCall('ChatSendServerMessageToLogin', array($this->Aseco->formatColors($message), $login));
			}
		} else {
			$message = $this->Aseco->getChatMessage('FOREVER_ONLY');
			$this->Aseco->client->addCall('ChatSendServerMessageToLogin', array($this->Aseco->formatColors($message), $login));
		}
	} //chat commmand bet coppers end
Greetings

NoTimeToDrive
wheelbarrow operator
wheelbarrow operator
Posts: 21
Joined: 31 Mar 2013 15:13
Owned TM-games: TMU TMUF

Re: [Xaseco] Nouse Betting V1.8.1

Post by NoTimeToDrive » 11 Mar 2018 16:31

Aha cool L3cKy.

I thought you mean something else.
Sorry for that. :?

But that little script is intresting.
I'm gone try it for sure.
Fond the line 659 between 719 where it's needed :thumbsup:
Now I can use it with peace of mind :D

Thx a lot L3cKy :3

Grt Ed

================================================
EDIT 17-3-2018:
Hey L3cKy.

Today I put my bet on back again.
No problems so far with the little update you give.
Thanks a lot :1

Grt Ed

Post Reply