Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- #include <a_samp>
- public OnGameModeInit() {
- CallLocalFunction("OnRconCommand", "s", "godzina");
- return true;
- }
- main() {
- new A[32][3][3];
- gettime(A[0][0][0], A[0][1][0], A[0][2][0]);
- printf("%d\n%d\n%d\n%d", sizeof(A), sizeof(A[]), sizeof(A[][]), sizeof(A[][][]));
- printf("Godzina: %02d:%02d:%02d", A[0][0][0], A[0][1][0], A[0][2][0]);
- printf("TEST");
- return false;
- }
- public OnRconCommand(cmd[]) {
- if(!strcmp(cmd, "godzina", true)) {
- new StringTimeDate[64][6];
- getdate(StringTimeDate[0][2], StringTimeDate[0][1], StringTimeDate[0][0]);
- gettime(StringTimeDate[0][3], StringTimeDate[0][4], StringTimeDate[0][5]);
- format(StringTimeDate[0], sizeof(StringTimeDate), "Dzisiaj jest: %02d/%02d/%d, godzina: %02d:%02d:%02d", StringTimeDate[0][0], StringTimeDate[0][1], StringTimeDate[0][2], StringTimeDate[0][3], StringTimeDate[0][4], StringTimeDate[0][5]);
- SendClientMessage(0, -1, StringTimeDate[0]);
- print(StringTimeDate[0]);
- return true;
- }
- return false;
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement