Jump to content

Problema - Sistem


RazvanCZ
 Share

Recommended Posts

  • Username: RazvanCZ

  • Problemă Ã®ntâlnită: Am incercat sa adaug un sistem pubg, mai am o problema care imi da batai de cap.

Detalii despre problemă:


error 012: invalid function call, not a valid address
warning 215: expression has no effect
error 001: expected token: ";", but found ")"
error 029: invalid expression, assumed zero
fatal error 107: too many error messages on one line

Ce ai încercat să faci înainte să postezi?: Am cautat pe google, dar nimic bun.

Cod sursă (recomandat pastebin.com): https://pastebin.com/wEnCHDtC

Alte detalii: thx

Link to comment
Share on other sites

  • Replies 21
  • Created
  • Last Reply

Top Posters In This Topic

format(strings, sizeof strings, "%s win the game with %d kills in %s%d:%s%d.", PlayerName(winner), PlayerKills[winner], (MatchTimer - MatchTimer / 60 < 10) ? ("0") : (""), MatchTimer / 60, (MatchTimer - MatchTimer / 60 * 60 < 10) ? ("0") : (""), MatchTimer - MatchTimer / 60 * 60);

Nu merge.

(7982) : error 012: invalid function call, not a valid address

(7982) : warning 215: expression has no effect

(7982) : error 001: expected token: ";", but found ")"

(7982) : error 029: invalid expression, assumed zero

(7982) : fatal error 107: too many error messages on one line

Link to comment
Share on other sites

  • Administrator

Hmm..

 

 

De ce naiba nu te folosesti de un stock pe a calcula timpul mult mai usor, fara sa te complici atat de mult

 

Stock:

stock calculeazaTimp(secunde) 
{
	new time = secunde;
	time = time%3600;
	new minute = time/60;
	time = time%60;
	new secunde2 = time;
	new string[10];
	format(string, sizeof(string), "%02d:%02d",minute,secunde2);
	return string;
}

Codul tau + stock-ul de mai sus:

format(strings, sizeof strings, "%s won the game with %d kills in %s.", PlayerName(winner), PlayerKills[winner], calculeazaTimp(MatchTimer));

Mult mai easy si fara batai de cap cu atatea operatii ternare, etc.

 

:crazy:

Link to comment
Share on other sites

Nu merge, tot am erori la acea linie.

(7994) : error 012: invalid function call, not a valid address
(7994) : warning 215: expression has no effect
(7994) : error 001: expected token: ";", but found ")"
(7994) : error 029: invalid expression, assumed zero
(7994) : fatal error 107: too many error messages on one line
Edited by RazvanCZ
Link to comment
Share on other sites

Guest
This topic is now closed to further replies.
 Share

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...