Jump to content

Lindor

Sacred Game Modder
  • Posts

    1,101
  • Joined

  • Last visited

  • Days Won

    37

Everything posted by Lindor

  1. ? For me it looks like they match? I found many more examples where the getQuestState function is called with an int as parameter. Actually it seems like the call with a table as a parameter is the exception and not vice versa. I still don't know if one of those routines is a bug. If the table call is a bug, then a couple of main quest scripts are a little bit broken, like the teleporting scripts at the Octagolamus valley. But ingame they seem to work well, so I think that the function can be called both ways, I'm just not 100% sure.
  2. Usually the hardcoded "getQuestState" function is called like this: getQuestState({id = 3650}) But for the functions "blutsee" and "blutgrotte" it's called like this: getQuestState(3650) getQuestState(3649) I don't know wether it's a bug or not, but I think so. These are questscripts for some blood forest quests I think. Any known bugs for these quests?
  3. would be interesting to know which teleporter this fixes. any ideas? EDIT: I think it's a teleporter in the blood forest which teleports your hero to sector BB-30
  4. The "Platte8G" exists twice EDIT: I'm convinced that the second "Platte8G" was an accidental spelling mistake, it should be named "Platte8H" instead. Doesn't matter which one you rename, they both do the same. This should fix a broken teleporter somewhere.
  5. The cutscenes questscripts are interesting. They are all nested functions; the outer function always defines an inner function called "feedback", but the feedback function is never called. Other than with object oriented programming languages like python, in lua functions defined without the "local" keyword really aren't local. I think the cutscenes functions are all just there to overwrite a global (hardcoded) feedback function. Which, if being called, plays a movie or some music or whatever. In a nutshell, the cutscenes questscripts don't actually play the movie, they define which movie is played next or which music is played next. The actual play happens inside by the "feedback" function, which is never called from inside questscripts.txt.
  6. Welp, I'm doing it all by hand. For now, I'm only formatting every function which doesn't begin with "quest.setScript" and leave the rest alone. I'm already halfway through. Given the size, a full format by hand including the "real" questscripts could take about a year I think. I sorted everything into different files like events.lua, position.lua, teleport.lua etc. to increase overview. The idea is to build a tool which merges these files into a final questscripts.txt. This way you don't need to keep searching long.
  7. I'm working on reviewing, cleaning, fixing, improving, commenting and increasing readibility of questscripts.txt. I want to post main fixes here. Final questscripts.txt can be downloaded when I finish my mod, but might take a while. On request, previews can be uploaded. I think it's best when I both post new fixes here and update it in OP to get a list without requiring a read-through of this topic. Fixes: CM_TimedKillCheatEvent: Comparison operator fix from >= to >. This fix is mandatory, as it prevents quest stages from triggering at inappropriate events CM_TimerResolve: This is a missing brackets fix. Previously, it was checking if getQuestState(quest_id) == ("TASK_AWAITING" and not cm_timequest[index].tcount) then which is wrong. CM_GetSessionStatus: break statement added to skip unnecessary calculaions, sppeding up the function significantly given that the position table is large enough. getn: Absolutely mandatory. Previously, this funtion was using keywords as variable names which is a NoGo. CM_convertPosition_To_SimpleTable: Not that important. Previously that function had an unused variable. I deleted that. The "Platte8G" function exists twice. Rename one to "Platte8H". Doesn't matter which one. onInitWorldobjects: fixed "FTYPE_MAGICLIGHT" spelling mistake to "FXTYPE_MAGICLIGHT" _AREA_CENTER_GHOSTVILLAGE: Originally, the creatures in the "AreaCreatures" table would overwrite each other until just one creature is left. The above code fisex that. _AREA_CENTER_HUMANS_CAPITAL: Originally, this function would spawn two creatures per spawn point instead of one as it should be. The above code fixes that. _AREA_CENTER_LIZARD_2: Same issue as above, originally it was double the amount of creatures spawned.
  8. I'm working on questscripts.txt fixes and readibility cleanup. The function CM_convertPosition_To_SimpleTable has an unused variable I. Just delete the line "local I". Also interesting for EE and Addendum (@dimitrius154) BTW maybe I'm able to shorten this function and speed it up significantly. EDIT why does this forum convert my lower case letter I to an upper case letter? When I say "local I", "I" is meant as a lower case letter.
  9. I have thought of another function: f(x, y) = x-xy+y Just that at x=y, it isn't f(x) = x, it's f(x) = x(2-x) Still kinda cool, though.
  10. @Flix this is not important, but can you share a data dump about all the texture file / fx relations you know? It'd be a great asset both for the fx ist as well as another, older dream of mine: an fx finding and editing tool. Now that I have acquired the skills to create GUI applications, this dream moved into closer proximity
  11. Lucky news, the wrapper doesn't compile the script into bytecode, instead it just glues the whole script at the end of an interpreter's bytecode. It can be done with a simple Hex Editor and it's easy to do. A full recovery is to be expected. There can be future user friendliness updates for this modding tool. Still impressive. One day I want to accomplish the same skills. Specifically the damage calculation function fixes, the enter-dungeon-with-mount fixes, the %LL functionality change and the possibility of opening up previously weapon damage based item modifiers to spell damage from addendum all sound very appealing to me.
  12. Unless someone can provide a way to unwrap the utf-8 lua script off of a srlua wrapped execuable (@dimitrius154?), the source code of this massive project's exes is lost. There's a very very thin, slight chance. Maybe a Hex-Editor or ollydbg could work. Don't know, not skilled/experienced enough yet.
  13. @Flix @dimitrius154 Sacred 2 EE 3.2a: spells.txt: mgr.addTokenBonus( {"et_provo_area", 906 }) -- 906 = bb_chance_block_CC bonus 906 does not exist in blueprint.txt. typification.txt: The bonusgroups 172, 173, 177, 239, 224, 251, 261, 252, 253, 254, 563, 737 and 769 being called in typification.txt do not exist in blueprint.txt. This is a Vanilla issue, could be hardcoded bonusgroups. Don't know wether Addendum has the same or similar inconsistencies, could be.
  14. This is actually good news for me. It means I don't have to update my mod everytime you update yours anymore xD Enjoy yourself, it may open up some well-deserved free time. As fun as modding and as satisfiying as positive community feedback is, it can not replace real life. At least for me. Haha same Haha thx It's a dark future you're drawing here, and I hope not. I can speak only for myself, but just because I'm focusing on other things doesn't mean that I will forget Sacred 2. It's simply not my top priority right now. BTW @Dax I've answered your PMs but I noticed that you left the chats before I answered them. Unlucky
  15. Yee, what he and Pesmontis did for Elite Mounts mod looks absolutely gorgeous. I think the armoured spider is Dmitriys work, isn't it?
  16. I have written a whole python repository for RGB/HSL conversion. Can be acquired here: https://github.com/General-Lindor/Color_space_conversion_with_gamma_correction/blob/main/Visualization/Visualization.pdf Four different models and their visualization are provided. Enjoy
  17. Figured out Formula for Hue calculation; it's basically the angle between the s_vector of the color and the s_vector of (1, 0, 0) a.k.a red. Original post has been updated.
  18. Oh. Okay. Well, that's not a good sign for me, but thx for clarification
  19. But I'm not the only one? Also If that was the case, the quirks wouldn't be as ...specific, I think. Also I've had supposedly undroppable items like blacksmith arts or forge slots dropping for me before, on another computer with another installation. Also crashes in the swamp have bee very common in the past, I remember there was a time where loading the swamp creature's model which is part of the main questline always crash my game. A rune crashing my game however is a new one. Can't remember seeing that before. I can try a clean install in the future, but today I really don't feel like sitting here all day waiting for the download to complete again I've had another thought: might using legacy characters be a possible source? I mean, I really don't see why that should have an impact on Lithos' BLOODFX, but just to be sure.
  20. There's just 2069 left, which has the same itemtype and template as 2060. @FlixPossible that template creature ID, which is actally the fen fire, is overwriting the lithos BLOODFX? mgr.createCreature { id = 1755, itemtype_id = 4831, name = "Template_energy_willowisp", behaviour = "defaultBehaviour", dangerclass = 0, groupmaxcount = 0, probabilityforelite = 0.000000, rank = 0, livesremaining = 0, unconscioustime = 20, palettebits = "1111111111111111", monstertype = 0, faction_id = 26, modelscale = 1.000000, rise_from_ground = 0, has_corpse = 1, has_soul = 1, can_strafe = 0, } newCreatureInfo = { type = 4831, walkSpeed = 50, runSpeed = 150, fightDistMin = 50, fightDistMax = 75, gender = 1, agegroup = 1, validEquipSlots = "0", defaultSMType = SMT_DEFAULT, behaviour = "WildAnimal", hair1Itemtype = 0, hair2Itemtype = 0, hair3Itemtype = 0, hair4Itemtype = 0, hair5Itemtype = 0, hair6Itemtype = 0, tailItemtype = 0, dangerClass = 0, eBloodEffect = "BLOODFX_RED", } mgr.creatureInfoCreate(newCreatureInfo);
  21. Maxed out all graphic settings, cleared all temp file including shader cache, used only EE shaders. No difference, still no FX. I used S2rw to decode global.res, I searched for "lithos", the first result was "4205936562 Lithos". I used my Loka-ID reverse engineering tool to get the following result: "4205936562 CREATURE_2060". I searched for "id = 2060," in EEs creatures.txt and voila: mgr.createCreature { id = 2060, itemtype_id = 12707, name = "tenergy_crystal_crystalstone", behaviour = "Enemy_mage", dangerclass = 4, groupmaxcount = 1, elite_creature_id = 2060, probabilityforelite = 0.000000, rank = 20, tenergy_creature_id = 2060, template_creature_id = 1755, livesremaining = 0, unconscioustime = 20, palettebits = "1111111111111111", monstertype = 0, faction_id = 27, equipset_id = 413, modelscale = 0.200000, rise_from_ground = 0, has_corpse = 0, has_soul = 1, can_strafe = 0, spells = { entry0 = { "enemy_electricity_shock" }, }, } newCreatureInfo = { type = 12707, walkSpeed = 50, runSpeed = 130, fightDistMin = 12, fightDistMax = 16, gender = 1, agegroup = 1, validEquipSlots = "EID_HELMET + EID_SHOULDER + EID_CHEST + EID_ARM + EID_HAND + EID_BOOT", defaultSMType = SMT_DEFAULT, behaviour = "BoulderDash", hair1Itemtype = 0, hair2Itemtype = 0, hair3Itemtype = 0, hair4Itemtype = 0, hair5Itemtype = 0, hair6Itemtype = 0, tailItemtype = 0, dangerClass = 4, weight = 450, eBloodEffect = "BLOODFX_TENERGY", } mgr.creatureInfoCreate(newCreatureInfo); They have the BLOODFX_TENERGY. But that's not important. What is important is that I have now a way to reverse engineer the creature IDs just from the creature name. There are more entries in global.res with "lithos". Will grant a list next.
  22. But - it doesn't do that for me. One frame they're there, the next they're not. Maybe a thing with PhysX? I'll check if it's enabled for me. EDIT: Even with PhysX enabled and cleared temp files, they simply vanish. Yesn't. At the occurence, I used a modified blueprint.txt, but the very only thing where it differs from EE's blueprint.txt is at id = 2952, name = "admin_only_ring", an item which isn't droppable anyway except for a force-drop via quest.txt. I use it to test ingame feeling of certain boni strengths, like casting speed. That and the fur and tree shader. And Elite Textures Trimmed. Other than that, I used completely standard EE files.
  23. The last of the nameless uardians dropped a dryad rune. I think it was sinister predator or ancient bark. The rune wouldn't let itself be cllected via autocollect, so I left-cicked it instead. As soon as my character reached it, the game crashed. Windows event log: Name der fehlerhaften Anwendung: s2gs.exe, Version: 2.65.1.0, Zeitstempel: 0x4adf82d7 Name des fehlerhaften Moduls: s2core.dll, Version: 2.65.2.0, Zeitstempel: 0x4b27a297 Ausnahmecode: 0xc0000005 Fehleroffset: 0x000a11b3 ID des fehlerhaften Prozesses: 0x29b8 Startzeit der fehlerhaften Anwendung: 0x01d96abcd29e6dae Pfad der fehlerhaften Anwendung: C:\Program Files (x86)\Steam\steamapps\common\Sacred 2 Gold\system\s2gs.exe Pfad des fehlerhaften Moduls: C:\Program Files (x86)\Steam\steamapps\common\Sacred 2 Gold\system\s2core.dll Berichtskennung: e8a290dc-e1e4-46bc-85bc-0e032eadeeb8 Vollständiger Name des fehlerhaften Pakets: Anwendungs-ID, die relativ zum fehlerhaften Paket ist: - <Event xmlns="http://schemas.microsoft.com/win/2004/08/events/event"> - <System> <Provider Name="Application Error" /> <EventID Qualifiers="0">1000</EventID> <Version>0</Version> <Level>2</Level> <Task>100</Task> <Opcode>0</Opcode> <Keywords>0x80000000000000</Keywords> <TimeCreated SystemTime="2023-04-09T09:20:55.0557095Z" /> <EventRecordID>1853</EventRecordID> <Correlation /> <Execution ProcessID="0" ThreadID="0" /> <Channel>Application</Channel> <Computer>CENSORED BY ME</Computer> <Security /> </System> - <EventData> <Data>s2gs.exe</Data> <Data>2.65.1.0</Data> <Data>4adf82d7</Data> <Data>s2core.dll</Data> <Data>2.65.2.0</Data> <Data>4b27a297</Data> <Data>c0000005</Data> <Data>000a11b3</Data> <Data>29b8</Data> <Data>01d96abcd29e6dae</Data> <Data>C:\Program Files (x86)\Steam\steamapps\common\Sacred 2 Gold\system\s2gs.exe</Data> <Data>C:\Program Files (x86)\Steam\steamapps\common\Sacred 2 Gold\system\s2core.dll</Data> <Data>e8a290dc-e1e4-46bc-85bc-0e032eadeeb8</Data> <Data /> <Data /> </EventData> </Event>
  24. Don't know wether it's intentional or not, but the Lithos (crystals in facetteleon cave e.g.) lack a proper death animation / BLOODFX and simply disappear on defeat. Looks kinda wierd.
×
×
  • Create New...
Please Sign In or Sign Up