Current time: 23.04.2024, 15:22 Hello There, Guest! (LoginRegister)
Language: english | russian  

Post Reply 
Threaded Mode | Linear Mode
Ваши вопросы по ERM-скриптам
Author Message
daemon_n Offline
Administrators

Posts: 4338
Post: #8296

Berserker, разве одно? Почему-то показалось, что оно каждый цикл это делать будет


Image: widget.png?style=banner2

Новейший Heroes 3 Launcher
02.08.2021 21:44
Visit this user's website Find all posts by this user Quote this message in a reply
Berserker Offline
Administrators

Posts: 16488
Post: #8297

Объявления переменных — это этап прекомпиляции в ЕРМ 1. Нажми F11, чтобы увидеть то, что реально выполняется.

Будет:

    !!re y2/0/7;
    !!en;


Скачать Герои 3 Эра и всё, что с ней связано / ERA 2.46f для старых модов
Поддержать проект
02.08.2021 22:14
Find all posts by this user Quote this message in a reply
Archer30 Offline
Moderators

Posts: 1117
Post: #8298

Berserker, thanks for clarification 132


Latest ERA mods and scripts in development - My GitHub
02.08.2021 23:09
Find all posts by this user Quote this message in a reply
daemon_n Offline
Administrators

Posts: 4338
Post: #8299

Berserker, y-2166


Image: widget.png?style=banner2

Новейший Heroes 3 Launcher
03.08.2021 00:05
Visit this user's website Find all posts by this user Quote this message in a reply
Berserker Offline
Administrators

Posts: 16488
Post: #8300

daemon_n, с чего бы? Именно что положительная y-переменная. Отрицательные не используются.


Скачать Герои 3 Эра и всё, что с ней связано / ERA 2.46f для старых модов
Поддержать проект
03.08.2021 01:00
Find all posts by this user Quote this message in a reply
Bes Offline

Posts: 5422
Post: #8301

ну ,видимо он нажал F11 и по факту сказал тебе что встало Yes
03.08.2021 01:02
Visit this user's website Find all posts by this user Quote this message in a reply
Berserker Offline
Administrators

Posts: 16488
Post: #8302

Там по факту будет y1 или y2 Rolleyes


Скачать Герои 3 Эра и всё, что с ней связано / ERA 2.46f для старых модов
Поддержать проект
03.08.2021 01:03
Find all posts by this user Quote this message in a reply
Archer30 Offline
Moderators

Posts: 1117
Post: #8303

Hi, is initialising variables still recommended or necessary? Is it true that every variable when declaring for the first time in a function, the value of it is either 0 or empty (except for x)?


Latest ERA mods and scripts in development - My GitHub
(This post was last modified: 04.08.2021 02:10 by Archer30.)
04.08.2021 02:08
Find all posts by this user Quote this message in a reply
daemon_n Offline
Administrators

Posts: 4338
Post: #8304

Archer30, in fact :y or :z is initialisation into 0 or ^^ - without that you cant use them, actually Yes


Image: widget.png?style=banner2

Новейший Heroes 3 Launcher
04.08.2021 03:39
Visit this user's website Find all posts by this user Quote this message in a reply
Archer30 Offline
Moderators

Posts: 1117
Post: #8305

daemon_n, what about :x?

Also another question, is mixing :x and x16 in a same function legit?


Latest ERA mods and scripts in development - My GitHub
(This post was last modified: 04.08.2021 16:23 by Archer30.)
04.08.2021 11:33
Find all posts by this user Quote this message in a reply
daemon_n Offline
Administrators

Posts: 4338
Post: #8306

Archer30, :x takes parameters from call. If new ones, then also 0


Image: widget.png?style=banner2

Новейший Heroes 3 Launcher
04.08.2021 18:49
Visit this user's website Find all posts by this user Quote this message in a reply
Berserker Offline
Administrators

Posts: 16488
Post: #8307

Archer30, yes, you really should initialize all variables. Without initialisation any variable value should be considered a garbage. daemon_n is wrong.

Example:



Скачать Герои 3 Эра и всё, что с ней связано / ERA 2.46f для старых модов
Поддержать проект
04.08.2021 23:40
Find all posts by this user Quote this message in a reply
daemon_n Offline
Administrators

Posts: 4338
Post: #8308

Berserker, what? i told about !#VA initialisation;


Image: widget.png?style=banner2

Новейший Heroes 3 Launcher
05.08.2021 00:41
Visit this user's website Find all posts by this user Quote this message in a reply
Berserker Offline
Administrators

Posts: 16488
Post: #8309

Quote:Archer30, in fact :y or :z is initialisation into 0 or ^^
Это неправда. Это просто привязка имени к ERM 1 переменной с индексом без инициализации.
!#VA или :? — разницы нет.


Скачать Герои 3 Эра и всё, что с ней связано / ERA 2.46f для старых модов
Поддержать проект
05.08.2021 03:59
Find all posts by this user Quote this message in a reply
daemon_n Offline
Administrators

Posts: 4338
Post: #8310

Berserker, понял - спасибо за ликбез.


Image: widget.png?style=banner2

Новейший Heroes 3 Launcher
05.08.2021 17:03
Visit this user's website Find all posts by this user Quote this message in a reply
« Next Oldest | Next Newest »
Post Reply 


Forum Jump:

Powered by MyBB Copyright © 2002-2024 MyBB Group