|
-
Apprentice
Yes, but there are also FF functions with delay in ms. People are using them instead triggers for example for regeneration script etc. And then there is a problem if game motion has changed.
-
Well make pull request with the new option to follow factor motion delay. Even though minimal number of mods change game speed, changing frame functions delay to respect factor motion would break one or the other... If they change game speed and use frame function for game time related events, it's their bad design.
On the other hand, it is surely needed feature. As I remember Anim8 calculations use system time difference and only check if game is paused, which makes it also game time independent. This package would also benefit from such feature.
-
Apprentice
I'm aware of it. That's why I sugested separate functions that would be dependent on factor.
-
Recently, Lehona introduced a second timer, that runs separately and only while the game is running. So, the ground work is already laid. Nevertheless, this new game timer, much like the original timer, runs with Ikarus's MEM_GetSystemTime, which is based on the system time. I am not sure how to implement the motion factor easily.
Alternatively, you could write a function that iterates over all active frame functions and multiplies their delay value by a certain value. In the event of changing the motion factor, you could call this function passing the same multiplier. Here in pseudo code:
Code:
setNewMotionFactor(int factor)
zCTimer.factorMotion = factor
for all ff in activeframefunctions
ff.delay *= factor
-
So basically we have 2 frame dependent timers, the second being just variation that skips "MEM_Game.timeStep", which is basically the same (it's just quality of life improvement).
According to this, the calculation Rayzer has, should be correct:
Code:
ff.next = ff.delay * (1/factor.motion)
Maybe we should make little refactor, where:
Code:
Timer - real time since last frame
GameTimer - game time since last frame (frame independent)
And then make Frame functions with possibility to "pause" with game and choose timer to use.
This would add more flexibility for FFs to chose paused behavior and timer used in "constructor".
Also I noticed, FFs are not "precise" because they just execute on nearest frame thats after delay, so they actually accumulate imprecision over time. Might be worth implementation, pseudo precise FF.
Pseudocode:
Code:
if(timer >= itm.next) {
var frame_delay; frame_delay = timer - itm.next;
if(itm.delay) {
itm.next += itm.delay - frame_delay;
}
}
-
Ich versuche den Hintergrund einer View schwarz-transparent zu färben
Dafür habe ich folgenden Code verwendet:
Code:
pView = ViewPtr_Create(posX, 400, 1, 1);
ViewPtr_ResizePxl(pView, 100, 30);
ViewPtr_SetColor(pView, RGBA(0, 0, 0, 128));
Leider passiert aber absolut gar nichts durch das ViewPtr_SetColor(...)
Wenn ich ViewPtr_SetTexture("Black.tga") benutze, bekomme ich zwar einen schwarzen Hintergrund, aber ich habe gehofft das ohne eine Textur hinzubekommen
Kann mir hier wer weiterhelfen?
-
Ich glaube tatsächlich, dass eine Textur gesetzt werden muss, um die Farbe zu setzen. Ich hatte glaube ich in dem Fall einfach die Default Textur verwendet: DEFAULT.TGA
Das ist eine Felstextur die zum Einsatz kommt, wenn eine angegebene Textur nicht gefunden wurde. Weil du auf schwarz hinauswillst macht die Struktur der Textur nichts. (Eventuell musst du noch die Alpha-Blend Einstellung ändern.)
-
Can anybody remind me where can I found a code for multi colored text?
Geändert von pawbuj (14.02.2020 um 11:31 Uhr)
-
Geändert von Cryp18Struct (17.02.2020 um 20:46 Uhr)
-
Potenzieller Bug?
Zitat von LootaBox
The OU file is completely opaque to me. I thought this file is just for subtitles and nothing about the flow of dialogs or the actors in those dialogs... I use spacer for creating them.
Anyway, I looked further into this and tested it with the example you gave Cryp18Struct and I managed to find the issue. Long story short, LeGo_Trialoge requires LeGo_AI_Function, but it is not automatically turned on by starting LeGo with the Trialoge flag.
This can easily be fixed by starting LeGo with the AI function flag or by adding the following line to LeGo.d
Code:
func void LeGo_InitFlags(var int f) {
...
if(f & LeGo_Trialoge) { f = f | LeGo_AI_Function; };
_LeGo_Flags = f;
};
Thanks for all the help!
-
Zitat von Kirides
Ich versuche den Hintergrund einer View schwarz-transparent zu färben
Dafür habe ich folgenden Code verwendet:
Code:
pView = ViewPtr_Create(posX, 400, 1, 1);
ViewPtr_ResizePxl(pView, 100, 30);
ViewPtr_SetColor(pView, RGBA(0, 0, 0, 128));
Leider passiert aber absolut gar nichts durch das ViewPtr_SetColor(...)
Wenn ich ViewPtr_SetTexture("Black.tga") benutze, bekomme ich zwar einen schwarzen Hintergrund, aber ich habe gehofft das ohne eine Textur hinzubekommen
Kann mir hier wer weiterhelfen?
Ist schwarz nicht die mit unglücklichste Wahl die man als Transparentbereich wählen kann? In vielen Grafiken wird da so ein abstrakter helllila-Ton verwendet für, ich weis das nur vom Rande aus wenn Editoren Arbeiten von mir in Spielen wie den Fußball-Manager verwendet haben, ich exportiere nur PNG und da ist das mit der Transparenz anders. In einigen Formaten nennt man den Farbwert der Transparent sein soll Alpha-Kanal. Evtl. hilft Dir das weiter?
Ich suche SEHR DRINGEND: Alten Rechner für ein MS-DOS/Windows 3.11/ME System MIT Diskettenlaufwerk.
Aktueller Zustand: Muss im Januar/Februar - wenn es ganz schlecht läuft erst im April in Fachklinik.
Pflegestufe 3 in Bearbeitung, Behinderten Prozente 100% mit Begleitung Bearbeitung, physisch und psychologisch arg angeschlagen.
WICHTIGES THEMA: [KNOWLEDGE HUB] International exchange of knowledge and tools
-
Ich schreibe mal hier, weil das eher LeGo betrifft.
Was ich hier im Ninja-Thread bezüglich eines Respawn-Systems über Patch geschrieben habe ist völliger Blödsinn. Der vorgeschlagene Ansatz ohne gesonderte Respawn-Klasse (siehe Respawn Beispiel im LeGo-Thread) sondern nur über einzelne Strings und Arrays, würde extrem viele Handles verpulvern (etwa 4 pro jedem einzelnen Monster, je nach Implementierung). Damit wird alles unübersichtlicher, fehleranfälliger, aber vor allem viel komplizierter zu handhaben.
Das Problem dabei ist nicht, dass Ninja einige Klassen nicht in PermMem speichert - denn diese Klassen sind für ein Respawnsystem uninteresant - sondern, dass PermMem nicht mit unbekannten, nicht länger existierenden Klassen/Instanzen umgehen kann. Das wäre der Fall, wenn ein Patch mit dieser Klasse/Instanz entfernt würde. Anstatt diese zu überspringen, hört PermMem mit einem Fehler auf, nachfolgende Handles werden nicht geladen und erneutes Speichern resultiert ggf. in einem Spielabsturz. Im Normalfall völlig legitim und das kann ich niemandem vorhalten, denn eine Klasse/Instanz verschwindet nicht einfach aus den Modskripten. Unabhängig von Ninja wird das nur dann zum Problem, wenn durch ein Update einer Mod eine Instanz/Klasse umbenannt wird. Man könnte LeGo einfach unbekannte Klassen/Instanzen überspringen lassen. Da das nur ein Eingriff im Laden bedeutet, ändert das an PermMem sonst nichts und alles bliebe beim alten. (Im gleichen Atemzug könnte man noch Sicherheitschecks für PM_LoadFuncOffset und PM_LoadFuncOffset einführen.) Ich werde mal Tickets im LeGo-Github dafür anlegen, kann mich auch gern selbst um die Implementierung kümmern.
Da eine solche Änderung in LeGo nur in zukünftigen Mods zur Verfügung stünde, werde ich mir von Seiten Ninjas mal anschauen, ob es nicht doch möglich ist, Patch-spezifische SCRPTSAVE.SAV anzulegen. Patch-spezifische Handles (soweit sich das feststellen lässt), würden gesondert in SCRPTSAVE_[PATCHNAME].SAV gespeichert. Geladen werden diese dann nur, wenn eben dieser Patch aktiv ist. Da der Handlecounter global ist, würde es auch keine Überschneidungen geben. So blieben Handles auch bestehen, wenn man einen Patch zwischenzeitlich entfernt. Diese Handhabung würde auch erlauben, einen Patch einfach zu "resetten", in dem man diese Datei aus dem Speicherordner löscht.
-
Ich bin gerade dabei die allermeisten Prints in Gothic 2 auf Softprints umzustellen, damit ich die schöne Animation Ein-/Ausblendung überall habe.
Ein Problem stellt sich mir allerdings, alle Softprints sind gleich groß, aber ich möchte zwei verschiedene Größen bzw. Fonts haben, so wie in G2 Normal halt.
Zum Beispiel wenn man Erfahrung bekomm ist ja normalerweise die Größe anders als wenn man eine Stufe aufsteigt. Wie kann ich das mit den Softprints am besten umsetzen?
-
What is necessary to prevent the game from crashing with the error PAR: Unknown Identifier : FF_Remove_All?
„Einen Dummkopf erkennt man daran, dass er alles abtut, was er anhand seiner eigenen Erfahrungen nicht erklären kann.“ — Farengar Heimlich-Feuer —
-
Zitat von rataj
What is necessary to prevent the game from crashing with the error PAR: Unknown Identifier : FF_Remove_All?
The function is called FF_RemoveAll (no underscore). See here. Wherever you call it, correct its name.
-
Zitat von mud-freak
The function is called FF_RemoveAll (no underscore). See here. Wherever you call it, correct its name.
Ah okay, i've updated from 2.5.0 to 2.5.1 and it works.
Now i can do research about the next error!^^
Thank you
„Einen Dummkopf erkennt man daran, dass er alles abtut, was er anhand seiner eigenen Erfahrungen nicht erklären kann.“ — Farengar Heimlich-Feuer —
Geändert von rataj (12.04.2020 um 17:39 Uhr)
-
Zitat von rataj
Ah okay, i've updated from 2.5.0 to 2.5.1 and it works.
Now i can do research about the next error!^^
Thank you
No problem.
Why 2.5.1? I recommend using the latest released version (2.6.0), see here: https://github.com/Lehona/LeGo/releases/
-
Zitat von mud-freak
The FF_Remove_All comes from a script of another modification and I wonder which one contains the underscore variant? I corrected it, but now I have a problem with Npc_hasVisualBody! But I think it's not really smart to update LeGo in a full final mod?
„Einen Dummkopf erkennt man daran, dass er alles abtut, was er anhand seiner eigenen Erfahrungen nicht erklären kann.“ — Farengar Heimlich-Feuer —
-
Zitat von rataj
But I think it's not really smart to update LeGo in a full final mod?
Why not? I cannot follow.
The problem you are having seems to come from using scripts of a mod using an older LeGo version and that adds the newer LeGo functions under different name (e.g. here with an additional underscore). Just correcting that in the mod scripts you have and using the latest LeGo version should’t be a big issue.
-
Zitat von mud-freak
Why not? I cannot follow.
The problem you are having seems to come from using scripts of a mod using an older LeGo version and that adds the newer LeGo functions under different name (e.g. here with an additional underscore). Just correcting that in the mod scripts you have and using the latest LeGo version should’t be a big issue.
Okay, i will update it. Besides that, i've managed to complete my script.
I guess it isn't hundred percent perfect but should be smart enough for a real good proper version.
I hope it will still working after updating to 2.6.0! But i am looking forward!
„Einen Dummkopf erkennt man daran, dass er alles abtut, was er anhand seiner eigenen Erfahrungen nicht erklären kann.“ — Farengar Heimlich-Feuer —
Berechtigungen
- Neue Themen erstellen: Nein
- Themen beantworten: Nein
- Anhänge hochladen: Nein
- Beiträge bearbeiten: Nein
|
|