SA-MP Forums

Go Back   SA-MP Forums > SA-MP Scripting and Plugins > Scripting Help

Reply
 
Thread Tools Display Modes
Old 12/07/2018, 12:38 PM   #1
GospodinX
Big Clucker
 
Join Date: Nov 2017
Posts: 51
Reputation: 0
Default Betting on real matches in samp(for fun)

Hi guys

I want to make betting in samp for fun(With IG money etc).I want to give players possibility to bet on real matches.My question,is there any way to get real odds?(in my database) (From any bet site etc) I don't want to add it manual every time,it's big job.

I also need result automatic on end of match etc..Is it possible to do in samp or ? Maybe someone have ideas...

Thanks

(sorry for english)
GospodinX is offline   Reply With Quote
Old 12/07/2018, 02:00 PM   #2
JasonRiggs
Gangsta
 
Join Date: Jul 2016
Location: My bedroom.
Posts: 700
Reputation: 34
Default Re: Betting on real matches in samp(for fun)

The only way to retrieve information from a website to pawn is a_http, with the function "HTTP" I'm not sure if it can help you retrieving such info or not..
__________________

forum.nc-rp.cf
Discord: Riggs #5210
JasonRiggs is offline   Reply With Quote
Old 12/07/2018, 02:10 PM   #3
[HLF]Southclaw
High-roller
 
[HLF]Southclaw's Avatar
 
Join Date: Apr 2009
Location: England
Posts: 4,921
Reputation: 1460
Default Re: Betting on real matches in samp(for fun)

Quote:
Originally Posted by JasonRiggs View Post
The only way to retrieve information from a website to pawno is a_http, with the function "HTTP" I'm not sure if it can help you retrieving such info or not..
pawn-requests can do that with HTTPS support (pretty standard now) with additional functions for accessing the JSON data that most APIs use.

There are plenty of APIs out there, especially for sports and esports.

also Pawno is a text editor, Pawn is the language :)
__________________
Tools:

Plugins:

Links:

[HLF]Southclaw is online now   Reply With Quote
Old 12/07/2018, 02:14 PM   #4
JasonRiggs
Gangsta
 
Join Date: Jul 2016
Location: My bedroom.
Posts: 700
Reputation: 34
Default Re: Betting on real matches in samp(for fun)

Quote:
Originally Posted by [HLF]Southclaw View Post
pawn-requests can do that with HTTPS support (pretty standard now) with additional functions for accessing the JSON data that most APIs use.

There are plenty of APIs out there, especially for sports and esports.

also Pawno is a text editor, Pawn is the language
Pretty good, But can this get us a value of the result of two teams for example from ****** results..

And yes, miss-added the "o" I know the part of which is the language and which is the editor.
__________________

forum.nc-rp.cf
Discord: Riggs #5210
JasonRiggs is offline   Reply With Quote
Old 12/07/2018, 03:50 PM   #5
[HLF]Southclaw
High-roller
 
[HLF]Southclaw's Avatar
 
Join Date: Apr 2009
Location: England
Posts: 4,921
Reputation: 1460
Default Re: Betting on real matches in samp(for fun)

The built in HTTP function doesn't support SSL, headers, large bodies and a number of other basic HTTP standard features. Also I would advise against using G search and attempting to scrape the returned HTML if that's what you were asking. The simplest way would be to just request an API such as http://worldcup.sfg.io (see the JSON content at http://worldcup.sfg.io/matches)
__________________
Tools:

Plugins:

Links:

[HLF]Southclaw is online now   Reply With Quote
Reply

Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
Betting on real football matches? danielpalade Scripting Help 3 17/04/2017 09:43 AM
Do not allow matches at the same time. GranaT3 Scripting Help 3 01/11/2016 07:15 PM
Loop through a file, see if string matches then get ID. Jack_Leslie Scripting Help 1 16/09/2011 04:32 AM


All times are GMT. The time now is 06:43 PM.


Powered by vBulletin® Version 3.8.6
Copyright ©2000 - 2018, Jelsoft Enterprises Ltd.