Перейти к содержимому
View in the app

A better way to browse. Learn more.

Zloplay community

A full-screen app on your home screen with push notifications, badges and more.

To install this app on iOS and iPadOS
  1. Tap the Share icon in Safari
  2. Scroll the menu and tap Add to Home Screen.
  3. Tap Add in the top-right corner.
To install this app on Android
  1. Tap the 3-dot menu (⋮) in the top-right corner of the browser.
  2. Tap Add to Home screen or Install app.
  3. Confirm by tapping Install.
Опубликовано:

Revision 15

 

  • More complete dvar_t struct - along with dvar flags
    Updated all Dvar_Register functions to use the flags.
     
    Added iw4m_suicideMsg (default 1), controls whether or not to use the custom suicide messages, possible use is in videos where you might not want such messages.

 

Changes:

 

 

Committed by pigophone on 2012-04-11 - 03:44:33

Featured Replies

Опубликовано:

Dvar Type 8, it takes 4 floats as its value in the registercolor dvar function but in the struct its stored as 4 bytes not floats.

The function converts float values to BYTE's along the lines of this:

( BYTE )( ( value * 255.0 + 0.001000000047497451 ) + 9.313225746154785e-10 ) )

 

Then if you want to get float value from BYTE value stored in struct you can simply do it like this:

value * 0.003921568859368563

 

Very nice work on the dvar_t struct, nicely reversed & clean.

Опубликовано:
Dvar Type 8, it takes 4 floats as its value in the registercolor dvar function but in the struct its stored as 4 bytes not floats.

The function converts float values to BYTE's along the lines of this:

( BYTE )( ( value * 255.0 + 0.001000000047497451 ) + 9.313225746154785e-10 ) )

 

Then if you want to get float value from BYTE value stored in struct you can simply do it like this:

value * 0.003921568859368563

 

Very nice work on the dvar_t struct, nicely reversed & clean.

You so hax us but help too. What gives? Although, some could say that you helped us.

Anyways, I'll update it in the next revision ;p

Опубликовано:

or just

__declspec(align(1)) struct Color
	{
		unsigned char red;
		unsigned char green;
		unsigned char blue;
		unsigned char alpha;
	} color;
[...]

(float)dvar->current.color.red / UCHAR_MAX

suprise! it's hex encoded!

Опубликовано:
or just

__declspec(align(1)) struct Color
	{
		unsigned char red;
		unsigned char green;
		unsigned char blue;
		unsigned char alpha;
	} color;
[...]

(float)dvar->current.color.red / UCHAR_MAX

suprise! it's hex encoded!

Referring to it as an array is easier.

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Гость
Ответить в тему...

Сейчас на странице 0

  • Нет пользователей, просматривающих эту страницу

Важная информация

Используя этот сайт, вы соглашаетесь Условия использования.

Account

Navigation

Поиск

Поиск

Configure browser push notifications

Chrome (Android)
  1. Tap the lock icon next to the address bar.
  2. Tap Permissions → Notifications.
  3. Adjust your preference.
Chrome (Desktop)
  1. Click the padlock icon in the address bar.
  2. Select Site settings.
  3. Find Notifications and adjust your preference.