Gamestudio Links
Zorro Links
Newest Posts
Help with plotting multiple ZigZag
by degenerate_762. 04/30/24 23:23
M1 Oversampling
by 11honza11. 04/30/24 08:16
Trading Journey
by howardR. 04/28/24 09:55
Zorro Trader GPT
by TipmyPip. 04/27/24 13:50
Data from CSV not parsed correctly
by jcl. 04/26/24 11:18
Why Zorro supports up to 72 cores?
by jcl. 04/26/24 11:09
AUM Magazine
Latest Screens
The Bible Game
A psychological thriller game
SHADOW (2014)
DEAD TASTE
Who's Online Now
2 registered members (ozgur, Quad), 880 guests, and 1 spider.
Key: Admin, Global Mod, Mod
Newest Members
firatv, wandaluciaia, Mega_Rod, EternallyCurious, howardR
19050 Registered Users
Previous Thread
Next Thread
Print Thread
Rate Thread
Page 2 of 2 1 2
Re: online scoreboard help [Re: Realspawn] #440813
05/02/14 18:57
05/02/14 18:57
Joined: Apr 2005
Posts: 1,988
Canadian, Eh
DLively Offline OP
Serious User
DLively  Offline OP
Serious User

Joined: Apr 2005
Posts: 1,988
Canadian, Eh
Okay I've looked into this more - I've noted that it is not the splitter. the splitter works fine.

It seems to be the webscore_send:
I know this because If I open the .txt file stored in my server after its been created the score is 50 and the time is 50.

50 = stage 50.

Code:
var webscore_send(STRING* name,STRING* scores_file,STRING* score,STRING* time)
{
if(!load_web_dll()) return -1;
STRING* send=str_create(WEBSCORE_SCRIPT);
str_cat(send,"?action=add&key=");
str_cat(send,webscore_clean(WEBSCORE_KEY));
str_cat(send,"&name=");
str_cat(send,webscore_clean(name));
str_cat(send,"&scores_file=");
str_cat(send,webscore_clean(scores_file));
str_cat(send,"&score=");
str_cat(send,webscore_clean(score));
str_cat(send,"&time=");
//str_cat(send,time); // This is the original line
str_cat(send,webscore_clean(time));//I tried to replace it with this
var r=DownloadToFile(_chr(send),_chr("score_temp"));
if(!r) return -2;
STRING* res=file_get_contents("score_temp");
if(str_cmp(res,"")) r=-2;
else if(str_cmp(res,"0") || str_cmp(res,"2")) r=0;
else if(str_cmp(res,"1")) r=-3;
else r=-4;
file_delete("score_temp");
return r;
}



Perhaps someone else can see the error here?


A8 Pro 8.45.4
YouTube: Create Games For Free
Free Resources: www.CGForFree.com
Re: online scoreboard help [Re: DLively] #440814
05/02/14 19:15
05/02/14 19:15
Joined: Apr 2005
Posts: 1,988
Canadian, Eh
DLively Offline OP
Serious User
DLively  Offline OP
Serious User

Joined: Apr 2005
Posts: 1,988
Canadian, Eh
I figured it out laugh

When sending strings, str_for_num should be done prior to the struct wink


A8 Pro 8.45.4
YouTube: Create Games For Free
Free Resources: www.CGForFree.com
Page 2 of 2 1 2

Moderated by  HeelX, Spirit 

Gamestudio download | chip programmers | Zorro platform | shop | Data Protection Policy

oP group Germany GmbH | Birkenstr. 25-27 | 63549 Ronneburg / Germany | info (at) opgroup.de

Powered by UBB.threads™ PHP Forum Software 7.7.1