HOME FORUMS MEMBERS RECENT POSTS LOG IN  
× Авторизация
Имя пользователя:
Пароль:
Нет аккаунта? Регистрация
Баннер 1   Баннер 2
НОВЫЕ ТОРГОВАЯ НОВОСТИ ЧАТ
loading...
Скрыть
Вернуться   ANTICHAT > ПРОГРАММИРОВАНИЕ > С/С++, C#, Rust, Swift, Go, Java, Perl, Ruby
   
Ответ
 
Опции темы Поиск в этой теме Опции просмотра

  #3361  
Старый 18.03.2019, 22:50
index
Новичок
Регистрация: 18.10.2015
Сообщений: 6
С нами: 5563739

Репутация: 0
По умолчанию

Не подскажете, какой тип имеет выражение?)

Код:





Код:
[](){};
 
Ответить с цитированием

  #3362  
Старый 18.03.2019, 23:56
san0
Постоянный
Регистрация: 15.12.2013
Сообщений: 412
С нами: 6530249

Репутация: 133
По умолчанию

Цитата:
Сообщение от arsh12344  

Не подскажете, какой тип имеет выражение?)

Код:





Код:
[](){};

Стандартом не определена однозначность.

Так называемый closure type - prvalue выражение, которое представляет собой уникальную неименованную неагрегированную структуру/класс, которая имеет перегруженный operator(), ну и еще пару методов.

В случае, когда функция не имеет захватов (сaptures), тогда можно неявно преобразовать в указатель на функцию

C++:





[CODE]
#include
#include
#include
auto
main
(
void
)
->
int
{
void
(
*
dd
)
(
)
=
[
]
{
std
::
cout

pp
=
[
]
{
std
::
cout



Цитата:

Z4mainEUlvE0_
Z4mainEUlvE1_
FvvE
FvvE
Надеюсь, чуточку прояснил ситуацию, но в любом случае советую посмотреть

http://www.open-std.org/jtc1/sc22/wg21/docs/papers/2014/n4296.pdf, 94 страница
 
Ответить с цитированием

  #3363  
Старый 24.03.2019, 18:11
sdfaw
Постоянный
Регистрация: 27.08.2018
Сообщений: 717
С нами: 4060346

Репутация: 43


По умолчанию

дарова, вобщем хочу начать писать sf плагины, можете объяснить в кратце что по чём.

например как пользоваться

SF->тут что-то()->тут что-то()->тут что-то();

или что такое вот это

pPlayer->szPlayerName,

pPlayer->iPing,

pPlayer->iScore,

pPlayer->iIsNPC,

pPlayer->pPlayerData->iAFKState == 2);

где можно найти информацию про это?

где можно найти функции sf api?
 
Ответить с цитированием

  #3364  
Старый 24.03.2019, 18:39
sdfaw
Постоянный
Регистрация: 27.08.2018
Сообщений: 717
С нами: 4060346

Репутация: 43


По умолчанию

Цитата:
Сообщение от mr.krabs  

Структуры это. Заходишь в папку SFAPI, там заголовочные файлы (.h), в этих файлах будут эти структуры.
а где можно почитать про sf api?

p.s видел уроки usShadow, но мало что понял
 
Ответить с цитированием

  #3365  
Старый 25.03.2019, 17:18
atizoff
Познавший АНТИЧАТ
Регистрация: 02.08.2018
Сообщений: 1,295
С нами: 4095395

Репутация: 183


По умолчанию

как применить стиль в имгуи?
 
Ответить с цитированием

  #3366  
Старый 25.03.2019, 17:21
4el0ve4ik
Познавший АНТИЧАТ
Регистрация: 12.11.2015
Сообщений: 1,560
С нами: 5526867

Репутация: 183


По умолчанию

Цитата:
Сообщение от social enemy  

как применить стиль в имгуи?
как то так:

C++:





Код:
ImGuiStyle
&
style
=
ImGui
::
GetStyle
(
)
;
style
.
Colors
[
ImGuiCol_Text
]
=
ImVec4
(
0.90f
,
0.90f
,
0.90f
,
0.93f
)
;
style
.
Colors
[
ImGuiCol_TextDisabled
]
=
ImVec4
(
0.60f
,
0.60f
,
0.60f
,
0.68f
)
;
style
.
Colors
[
ImGuiCol_WindowBg
]
=
ImVec4
(
0.16f
,
0.16f
,
0.16f
,
0.96f
)
;
style
.
Colors
[
ImGuiCol_PopupBg
]
=
ImVec4
(
0.10f
,
0.10f
,
0.10f
,
0.94f
)
;
style
.
Colors
[
ImGuiCol_Border
]
=
ImVec4
(
0.34f
,
0.33f
,
0.34f
,
1.00f
)
;
style
.
Colors
[
ImGuiCol_FrameBg
]
=
ImVec4
(
0.80f
,
0.80f
,
0.80f
,
0.33f
)
;
style
.
Colors
[
ImGuiCol_FrameBgHovered
]
=
ImVec4
(
0.80f
,
0.80f
,
1.00f
,
0.40f
)
;
style
.
Colors
[
ImGuiCol_FrameBgActive
]
=
ImVec4
(
0.50f
,
0.58f
,
0.85f
,
0.65f
)
;
style
.
Colors
[
ImGuiCol_TitleBg
]
=
ImVec4
(
0.40f
,
0.40f
,
0.39f
,
0.80f
)
;
style
.
Colors
[
ImGuiCol_TitleBgCollapsed
]
=
ImVec4
(
0.22f
,
0.39f
,
0.73f
,
0.52f
)
;
style
.
Colors
[
ImGuiCol_TitleBgActive
]
=
ImVec4
(
0.13f
,
0.41f
,
0.71f
,
1.00f
)
;
style
.
Colors
[
ImGuiCol_MenuBarBg
]
=
ImVec4
(
0.30f
,
0.31f
,
0.31f
,
0.80f
)
;
style
.
Colors
[
ImGuiCol_ScrollbarBg
]
=
ImVec4
(
0.20f
,
0.25f
,
0.30f
,
0.00f
)
;
style
.
Colors
[
ImGuiCol_ScrollbarGrab
]
=
ImVec4
(
0.40f
,
0.40f
,
0.40f
,
0.39f
)
;
style
.
Colors
[
ImGuiCol_ScrollbarGrabHovered
]
=
ImVec4
(
0.40f
,
0.40f
,
0.40f
,
0.59f
)
;
style
.
Colors
[
ImGuiCol_ScrollbarGrabActive
]
=
ImVec4
(
0.50f
,
0.50f
,
0.50f
,
0.72f
)
;
style
.
Colors
[
ImGuiCol_CheckMark
]
=
ImVec4
(
0.27f
,
0.58f
,
1.00f
,
1.00f
)
;
style
.
Colors
[
ImGuiCol_SliderGrabActive
]
=
ImVec4
(
0.20f
,
0.57f
,
1.00f
,
0.84f
)
;
style
.
Colors
[
ImGuiCol_Button
]
=
ImVec4
(
0.27f
,
0.58f
,
1.00f
,
0.78f
)
;
style
.
Colors
[
ImGuiCol_ButtonHovered
]
=
ImVec4
(
0.37f
,
0.64f
,
1.00f
,
0.94f
)
;
style
.
Colors
[
ImGuiCol_ButtonActive
]
=
ImVec4
(
0.27f
,
0.44f
,
1.00f
,
1.00f
)
;
style
.
Colors
[
ImGuiCol_Header
]
=
ImVec4
(
0.49f
,
0.49f
,
0.49f
,
0.46f
)
;
style
.
Colors
[
ImGuiCol_HeaderHovered
]
=
ImVec4
(
0.45f
,
0.45f
,
0.50f
,
0.49f
)
;
style
.
Colors
[
ImGuiCol_HeaderActive
]
=
ImVec4
(
0.53f
,
0.53f
,
0.57f
,
0.75f
)
;
style
.
Colors
[
ImGuiCol_ColumnHovered
]
=
ImVec4
(
0.60f
,
0.60f
,
0.70f
,
1.00f
)
;
style
.
Colors
[
ImGuiCol_ColumnActive
]
=
ImVec4
(
0.70f
,
0.70f
,
0.90f
,
1.00f
)
;
style
.
Colors
[
ImGuiCol_ResizeGrip
]
=
ImVec4
(
1.00f
,
1.00f
,
1.00f
,
0.47f
)
;
style
.
Colors
[
ImGuiCol_ResizeGripActive
]
=
ImVec4
(
0.78f
,
0.76f
,
1.00f
,
1.00f
)
;
style
.
Colors
[
ImGuiCol_CloseButton
]
=
ImVec4
(
0.50f
,
0.50f
,
0.50f
,
0.89f
)
;
style
.
Colors
[
ImGuiCol_CloseButtonHovered
]
=
ImVec4
(
0.70f
,
0.70f
,
0.71f
,
0.60f
)
;
style
.
Colors
[
ImGuiCol_PlotLinesHovered
]
=
ImVec4
(
0.27f
,
0.54f
,
1.00f
,
0.47f
)
;
style
.
Colors
[
ImGuiCol_PlotHistogram
]
=
ImVec4
(
0.24f
,
0.58f
,
1.00f
,
1.00f
)
;
style
.
Colors
[
ImGuiCol_PlotHistogramHovered
]
=
ImVec4
(
0.23f
,
0.47f
,
1.00f
,
1.00f
)
;
style
.
Colors
[
ImGuiCol_TextSelectedBg
]
=
ImVec4
(
0.16f
,
0.37f
,
0.98f
,
0.75f
)
;
 
Ответить с цитированием

  #3367  
Старый 25.03.2019, 17:27
atizoff
Познавший АНТИЧАТ
Регистрация: 02.08.2018
Сообщений: 1,295
С нами: 4095395

Репутация: 183


По умолчанию

Цитата:
Сообщение от 4el0ve4ik  

как то так:

C++:





Код:
ImGuiStyle
&
style
=
ImGui
::
GetStyle
(
)
;
style
.
Colors
[
ImGuiCol_Text
]
=
ImVec4
(
0.90f
,
0.90f
,
0.90f
,
0.93f
)
;
style
.
Colors
[
ImGuiCol_TextDisabled
]
=
ImVec4
(
0.60f
,
0.60f
,
0.60f
,
0.68f
)
;
style
.
Colors
[
ImGuiCol_WindowBg
]
=
ImVec4
(
0.16f
,
0.16f
,
0.16f
,
0.96f
)
;
style
.
Colors
[
ImGuiCol_PopupBg
]
=
ImVec4
(
0.10f
,
0.10f
,
0.10f
,
0.94f
)
;
style
.
Colors
[
ImGuiCol_Border
]
=
ImVec4
(
0.34f
,
0.33f
,
0.34f
,
1.00f
)
;
style
.
Colors
[
ImGuiCol_FrameBg
]
=
ImVec4
(
0.80f
,
0.80f
,
0.80f
,
0.33f
)
;
style
.
Colors
[
ImGuiCol_FrameBgHovered
]
=
ImVec4
(
0.80f
,
0.80f
,
1.00f
,
0.40f
)
;
style
.
Colors
[
ImGuiCol_FrameBgActive
]
=
ImVec4
(
0.50f
,
0.58f
,
0.85f
,
0.65f
)
;
style
.
Colors
[
ImGuiCol_TitleBg
]
=
ImVec4
(
0.40f
,
0.40f
,
0.39f
,
0.80f
)
;
style
.
Colors
[
ImGuiCol_TitleBgCollapsed
]
=
ImVec4
(
0.22f
,
0.39f
,
0.73f
,
0.52f
)
;
style
.
Colors
[
ImGuiCol_TitleBgActive
]
=
ImVec4
(
0.13f
,
0.41f
,
0.71f
,
1.00f
)
;
style
.
Colors
[
ImGuiCol_MenuBarBg
]
=
ImVec4
(
0.30f
,
0.31f
,
0.31f
,
0.80f
)
;
style
.
Colors
[
ImGuiCol_ScrollbarBg
]
=
ImVec4
(
0.20f
,
0.25f
,
0.30f
,
0.00f
)
;
style
.
Colors
[
ImGuiCol_ScrollbarGrab
]
=
ImVec4
(
0.40f
,
0.40f
,
0.40f
,
0.39f
)
;
style
.
Colors
[
ImGuiCol_ScrollbarGrabHovered
]
=
ImVec4
(
0.40f
,
0.40f
,
0.40f
,
0.59f
)
;
style
.
Colors
[
ImGuiCol_ScrollbarGrabActive
]
=
ImVec4
(
0.50f
,
0.50f
,
0.50f
,
0.72f
)
;
style
.
Colors
[
ImGuiCol_CheckMark
]
=
ImVec4
(
0.27f
,
0.58f
,
1.00f
,
1.00f
)
;
style
.
Colors
[
ImGuiCol_SliderGrabActive
]
=
ImVec4
(
0.20f
,
0.57f
,
1.00f
,
0.84f
)
;
style
.
Colors
[
ImGuiCol_Button
]
=
ImVec4
(
0.27f
,
0.58f
,
1.00f
,
0.78f
)
;
style
.
Colors
[
ImGuiCol_ButtonHovered
]
=
ImVec4
(
0.37f
,
0.64f
,
1.00f
,
0.94f
)
;
style
.
Colors
[
ImGuiCol_ButtonActive
]
=
ImVec4
(
0.27f
,
0.44f
,
1.00f
,
1.00f
)
;
style
.
Colors
[
ImGuiCol_Header
]
=
ImVec4
(
0.49f
,
0.49f
,
0.49f
,
0.46f
)
;
style
.
Colors
[
ImGuiCol_HeaderHovered
]
=
ImVec4
(
0.45f
,
0.45f
,
0.50f
,
0.49f
)
;
style
.
Colors
[
ImGuiCol_HeaderActive
]
=
ImVec4
(
0.53f
,
0.53f
,
0.57f
,
0.75f
)
;
style
.
Colors
[
ImGuiCol_ColumnHovered
]
=
ImVec4
(
0.60f
,
0.60f
,
0.70f
,
1.00f
)
;
style
.
Colors
[
ImGuiCol_ColumnActive
]
=
ImVec4
(
0.70f
,
0.70f
,
0.90f
,
1.00f
)
;
style
.
Colors
[
ImGuiCol_ResizeGrip
]
=
ImVec4
(
1.00f
,
1.00f
,
1.00f
,
0.47f
)
;
style
.
Colors
[
ImGuiCol_ResizeGripActive
]
=
ImVec4
(
0.78f
,
0.76f
,
1.00f
,
1.00f
)
;
style
.
Colors
[
ImGuiCol_CloseButton
]
=
ImVec4
(
0.50f
,
0.50f
,
0.50f
,
0.89f
)
;
style
.
Colors
[
ImGuiCol_CloseButtonHovered
]
=
ImVec4
(
0.70f
,
0.70f
,
0.71f
,
0.60f
)
;
style
.
Colors
[
ImGuiCol_PlotLinesHovered
]
=
ImVec4
(
0.27f
,
0.54f
,
1.00f
,
0.47f
)
;
style
.
Colors
[
ImGuiCol_PlotHistogram
]
=
ImVec4
(
0.24f
,
0.58f
,
1.00f
,
1.00f
)
;
style
.
Colors
[
ImGuiCol_PlotHistogramHovered
]
=
ImVec4
(
0.23f
,
0.47f
,
1.00f
,
1.00f
)
;
style
.
Colors
[
ImGuiCol_TextSelectedBg
]
=
ImVec4
(
0.16f
,
0.37f
,
0.98f
,
0.75f
)
;

сделал также, но чёт ничего

Цитата:
Сообщение от Спойлер  


C++:





[CODE]
#include
#include
#include "imgui/imgui.h"
#include "GUI.h"
#include "Config.h"
#include "Hacks/Misc.h"
#include "Hacks/Visuals.h"
constexpr
auto
windowFlags
=
ImGuiWindowFlags_NoCollapse
|
ImGuiWindowFlags_NoResize
|
ImGuiWindowFlags_NoScrollbar
|
ImGuiWindowFlags_NoScrollWithMouse
;
void
GUI
::
style
(
)
noexcept
{
#define HI(v) ImVec4(0.502f, 0.075f, 0.256f, v)
#define MED(v) ImVec4(0.455f, 0.198f, 0.301f, v)
#define LOW(v) ImVec4(0.232f, 0.201f, 0.271f, v)
// backgrounds (@todo: complete with BG_MED, BG_LOW)
#define BG(v) ImVec4(0.200f, 0.220f, 0.270f, v)
// text
#define TEXT(v) ImVec4(0.860f, 0.930f, 0.890f, v)
auto
&
style
=
ImGui
::
GetStyle
(
)
;
style
.
Colors
[
ImGuiCol_Text
]
=
TEXT
(
0.78f
)
;
style
.
Colors
[
ImGuiCol_TextDisabled
]
=
TEXT
(
0.28f
)
;
style
.
Colors
[
ImGuiCol_WindowBg
]
=
ImVec4
(
0.13f
,
0.14f
,
0.17f
,
1.00f
)
;
style
.
Colors
[
ImGuiCol_PopupBg
]
=
BG
(
0.9f
)
;
style
.
Colors
[
ImGuiCol_Border
]
=
ImVec4
(
0.31f
,
0.31f
,
1.00f
,
0.00f
)
;
style
.
Colors
[
ImGuiCol_BorderShadow
]
=
ImVec4
(
0.00f
,
0.00f
,
0.00f
,
0.00f
)
;
style
.
Colors
[
ImGuiCol_FrameBg
]
=
BG
(
1.00f
)
;
style
.
Colors
[
ImGuiCol_FrameBgHovered
]
=
MED
(
0.78f
)
;
style
.
Colors
[
ImGuiCol_FrameBgActive
]
=
MED
(
1.00f
)
;
style
.
Colors
[
ImGuiCol_TitleBg
]
=
LOW
(
1.00f
)
;
style
.
Colors
[
ImGuiCol_TitleBgActive
]
=
HI
(
1.00f
)
;
style
.
Colors
[
ImGuiCol_TitleBgCollapsed
]
=
BG
(
0.75f
)
;
style
.
Colors
[
ImGuiCol_MenuBarBg
]
=
BG
(
0.47f
)
;
style
.
Colors
[
ImGuiCol_ScrollbarBg
]
=
BG
(
1.00f
)
;
style
.
Colors
[
ImGuiCol_ScrollbarGrab
]
=
ImVec4
(
0.09f
,
0.15f
,
0.16f
,
1.00f
)
;
style
.
Colors
[
ImGuiCol_ScrollbarGrabHovered
]
=
MED
(
0.78f
)
;
style
.
Colors
[
ImGuiCol_ScrollbarGrabActive
]
=
MED
(
1.00f
)
;
style
.
Colors
[
ImGuiCol_CheckMark
]
=
ImVec4
(
0.71f
,
0.22f
,
0.27f
,
1.00f
)
;
style
.
Colors
[
ImGuiCol_SliderGrab
]
=
ImVec4
(
0.47f
,
0.77f
,
0.83f
,
0.14f
)
;
style
.
Colors
[
ImGuiCol_SliderGrabActive
]
=
ImVec4
(
0.71f
,
0.22f
,
0.27f
,
1.00f
)
;
style
.
Colors
[
ImGuiCol_Button
]
=
ImVec4
(
0.47f
,
0.77f
,
0.83f
,
0.14f
)
;
style
.
Colors
[
ImGuiCol_ButtonHovered
]
=
MED
(
0.86f
)
;
style
.
Colors
[
ImGuiCol_ButtonActive
]
=
MED
(
1.00f
)
;
style
.
Colors
[
ImGuiCol_Header
]
=
MED
(
0.76f
)
;
style
.
Colors
[
ImGuiCol_HeaderHovered
]
=
MED
(
0.86f
)
;
style
.
Colors
[
ImGuiCol_HeaderActive
]
=
HI
(
1.00f
)
;
style
.
Colors
[
ImGuiCol_ResizeGrip
]
=
ImVec4
(
0.47f
,
0.77f
,
0.83f
,
0.04f
)
;
style
.
Colors
[
ImGuiCol_ResizeGripHovered
]
=
MED
(
0.78f
)
;
style
.
Colors
[
ImGuiCol_ResizeGripActive
]
=
MED
(
1.00f
)
;
style
.
Colors
[
ImGuiCol_PlotLines
]
=
TEXT
(
0.63f
)
;
style
.
Colors
[
ImGuiCol_PlotLinesHovered
]
=
MED
(
1.00f
)
;
style
.
Colors
[
ImGuiCol_PlotHistogram
]
=
TEXT
(
0.63f
)
;
style
.
Colors
[
ImGuiCol_PlotHistogramHovered
]
=
MED
(
1.00f
)
;
style
.
Colors
[
ImGuiCol_TextSelectedBg
]
=
MED
(
0.43f
)
;
// [...]
style
.
WindowPadding
=
ImVec2
(
6
,
4
)
;
style
.
WindowRounding
=
0.0f
;
style
.
FramePadding
=
ImVec2
(
5
,
2
)
;
style
.
FrameRounding
=
3.0f
;
style
.
ItemSpacing
=
ImVec2
(
7
,
1
)
;
style
.
ItemInnerSpacing
=
ImVec2
(
1
,
1
)
;
style
.
TouchExtraPadding
=
ImVec2
(
0
,
0
)
;
style
.
IndentSpacing
=
6.0f
;
style
.
ScrollbarSize
=
12.0f
;
style
.
ScrollbarRounding
=
16.0f
;
style
.
GrabMinSize
=
20.0f
;
style
.
GrabRounding
=
2.0f
;
style
.
WindowTitleAlign
.
x
=
0.50f
;
style
.
Colors
[
ImGuiCol_Border
]
=
ImVec4
(
0.539f
,
0.479f
,
0.255f
,
0.162f
)
;
style
.
FrameBorderSize
=
0.0f
;
style
.
WindowBorderSize
=
1.0f
;
}
void
GUI
::
render
(
)
noexcept
{
renderMenuBar
(
)
;
renderGlowWindow
(
)
;
renderVisualsWindow
(
)
;
renderMiscWindow
(
)
;
}
void
GUI
::
checkBoxAndColorPicker
(
const
std
::
string
&
name
,
bool
*
enable
,
float
*
color
)
noexcept
{
ImGui
::
Checkbox
(
(
"##"
+
name
)
.
c_str
(
)
,
enable
)
;
ImGui
::
SameLine
(
0.0f
,
5.0f
)
;
bool
openPopup
=
ImGui
::
ColorButton
(
(
"##"
+
name
+
"ColorButton"
)
.
c_str
(
)
,
ImColor
{
color
[
0
]
,
color
[
1
]
,
color
[
2
]
}
,
ImGuiColorEditFlags_NoTooltip
)
;
ImGui
::
SameLine
(
0.0f
,
5.0f
)
;
ImGui
::
Text
(
name
.
c_str
(
)
)
;
if
(
openPopup
)
ImGui
::
OpenPopup
(
(
"##"
+
name
+
"Popup"
)
.
c_str
(
)
)
;
if
(
ImGui
::
BeginPopup
(
(
"##"
+
name
+
"Popup"
)
.
c_str
(
)
)
)
{
ImGui
::
ColorPicker3
(
(
"##"
+
name
+
"Picker"
)
.
c_str
(
)
,
color
,
ImGuiColorEditFlags_DisplayRGB
|
ImGuiColorEditFlags_NoSidePreview
)
;
ImGui
::
EndPopup
(
)
;
}
}
void
GUI
::
hotkey
(
int
&
key
)
noexcept
{
ImGui
::
Text
(
(
std
::
ostringstream
{
}



 
Ответить с цитированием

  #3368  
Старый 27.03.2019, 19:03
CyberSuslik
Познающий
Регистрация: 16.03.2018
Сообщений: 88
С нами: 4295643

Репутация: 8
По умолчанию

Посоветуйте простенькую не тяжеловесную IDE
 
Ответить с цитированием

  #3369  
Старый 27.03.2019, 19:22
ALF
Постоянный
Регистрация: 14.11.2017
Сообщений: 319
С нами: 4472205

Репутация: 163
По умолчанию

Цитата:
Сообщение от CyberSuslik  

Посоветуйте простенькую не тяжеловесную IDE
блокнот
 
Ответить с цитированием

  #3370  
Старый 28.03.2019, 14:56
Sarutobi1
Новичок
Регистрация: 25.03.2019
Сообщений: 1
С нами: 3756638

Репутация: 0
По умолчанию

void *obj = *(void **)((DWORD)samp + 0x95CD0);

((void(__thiscall *) (void *, int, bool)) ((DWORD)samp + 0x95CD0))(obj, iToggle ? 3 : 0, !iToggle);

За что отвечают эти два адреса ?
 
Ответить с цитированием
Ответ





Здесь присутствуют: 1 (пользователей: 0 , гостей: 1)
 


Быстрый переход




ANTICHAT ™ © 2001- Antichat Kft.