-
Notifications
You must be signed in to change notification settings - Fork 0
/
functions.h
72 lines (59 loc) · 1.57 KB
/
functions.h
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
//
// Created by menox on 08.04.2023.
//
// C++
#include <iostream>
#include <string>
#include <regex>
#include <chrono>
#include <filesystem>
// SFML
#include "SFML/Graphics/RenderWindow.hpp"
#ifndef PROJECT_NAME_FUNCTIONS_H
#define PROJECT_NAME_FUNCTIONS_H
/**
* @brief Method used for validating name
* @param name - name to be validated
*/
bool nameValidation(const std::string &name);
/**
* @brief Method used for validating dead tamagotchi file (.dtf)
* @param name - filename to be validated
*/
bool deadTamagotchiValidation(const std::string &name);
/**
* @brief Method used for validating scores
* @param lineToValidate - line to be validated
*/
bool scoreLineValidation(const std::string &lineToValidate);
/**
* @brief Method used for validating food config
* @param lineToValidate - line to be validated
*/
bool foodConfigValidation(const std::string &lineToValidate);
/**
* @brief Method used for validating food config
* @param lineToValidate - line to be validated
*/
bool foodSaveValidation(const std::string &lineToValidate);
/**
* @brief Method used for validating tamagotchi config
* @param tamagotchiFile - tamagotchi file to be validated
*/
bool tamagotchiSaveValidation(const std::string &tamagotchiFile);
/**
* @brief Method used for getting time
* @return time in seconds
*/
long long int getTime();
/**
* @brief Function used for setting icon
* @param window
*/
void setIcon(sf::RenderWindow &window);
/**
* @brief Function used for setting cursor
* @param window
*/
void setCursor(sf::RenderWindow &window);
#endif //PROJECT_NAME_FUNCTIONS_H