Oni Central Forum

A forum for the Oni community

You are not logged in.

#26 09/26/13 19:09

Dirk Gently
Member
From: Boston, MA
Registered: 06/12/09
Website

Re: Engine hacking questions 2

ltemplar wrote:

Yes you are right.
I also suspect that this limitations where do the hardware available that time (the oni minimum requirement was 32 mb ram, voodo banshe and P166  if I recall correctly).
But now we have year 2013, where such limitations are no more.
So why not remove them and check what will happen?
Correct me if I'm wrong, but I think most engines that time were mostly based on cpu power and memory rather than video card, so things , that are more advanced now.

Don't know to what space in the engine you are referring to..Memory for example?
Can you en-light me?Because in my understanding such briers are added do the hardware issues..not the engines itself..but maybe I'm wrong.As i said before I'm not an expert here.

I'm curious , why you think that such changes will alert game engine greatly yes , but in negative way(or misinterpreted this?)?

The engine patches that EdT and others have done so far are a matter of locating the static defines of some of the code and altering them to change the values. For example the edits to increase the supported texture sizes and resolutions is an easy fix because you are looking for the values of the textures 256x256 and increasing the value stored there so it can look for larger sizes (1024x1024) and by luck that the engine was coded well enough to not screw that up and correctly render these larger textures with error.

The engine changes you are talking about are going to involve introducing new code into the application. As Iritscen stated, the three of us (EdT, Iritscen, and myself) are all mac people and we know the mac side of things better. I know a fair bit about how this process works to the point that i can try to explain how this would be expected to work on the OS X platform. You are looking to introduce new functionality and behaviors into the game. For us, it isn't really all that possible to inject new behavior like that, as we have no daodan.dll or comparable loadable runtime library we depend on that we can inject new code into. Even still, much of what you are talking about would be involving inserting new code in the middle of existing code, which frankly isn't possible without smashing the loaded symbol table at runtime and reassigning function symbols and provide new "injected" code as a replacement for it. This isn't runtime safe or stable, and can cause serious crashes on the system with even a minor ABI change on the system. You are talking about redefining some of the core functionality at such a level and introducing new system check to the game for new features.

Some of what you are talking about is possibly scriptable, but others are either a runtime limitation of the engine based on the original system requirements, but also what the engine itself can handle. I know some of this doesn't make much sense, but engine performance and speed doesn't scale directly with hardware it is run on. It is highly dependent on the algorithms used to power the game. While it could be possible to allow for more than 20 weapons active at any one time, it might cause some serious slow downs everywhere else. While the algorithm for iterating over what active weapons are "alive" in the environment, it could start causing some AI lag if you are going to go past 40. Yes I am speculating on this because I don't know what would happen beyond what the existing engine limitations are. I do know that there is a max poly count per scene, and if it goes past this then it will start dropping the rendering of some things in the scene. For example, if you push too many polygons into a scene then projectiles and particles have the potential to not be visible because they get dropped from the rendering because they aren't as high of a priority as characters and landscape rendering. I have seen this happen in the engine before, and it does become very annoying to play.

What little i do know about oni is that it doesn't use a sophisticated rendering system, everything is drawn per frame and then pushed to the scene and then that is what we see on screen. However, unlike a lot of games, Oni doesn't run the game engine and the rendering separately. This means that when the game performs slowly, everything else performs slowly. So, for example, if you played at a max of 15fps, that means the game is running 15 updates per second. the AI pathing, decision-making, collision checks, combat behavior, scripting behavior, etc; is all only being updated 15 times per second. Compare that to having 60fps, or 60 updates per second. Faster the game runs the "smarter" it will also run and behave. It has more time to make decisions and generate new decisions for AI and gameplay.

I say this with a word of warning, because it is something that should be carefully heeded. Modifying aspects of the engine such as rendering buffers and live objects and characters can have ramifications far beyond any scope you may realize about it. All of these systems are co-dependent on each other in an indirect manner. Editing even a small portion of them can cause havoc in other systems that you might not even realize.

As I said earlier in my post i am from the OS X side of things, so i cannot tell you how this would differ for a windows system or method for getting these hacks in place. Keep in mind that the OS X and windows versions are different builds of the same game. windows uses 1.0 whereas mac is 1.1, we also have different content types than windows. What might work on one system isn't guaranteed to work on another. So if you decide to move forward and investigate more into this, we can help you to what extend we can, but this is ultimately a challenge that you will have to overcome at some point of the cross-platform testing and feasibility of these sorts of engine patches.

Offline

#27 09/26/13 19:09

EdT
Moderator
From: Los Angeles, CA
Registered: 01/13/07
Website

Re: Engine hacking questions 2

Just a few more bits of info from the wiki (Thanks, Iritscen)

'if I remember correctly there is 128 physics context limit. That means the number of active characters + objects + powerups and whatever else needs a physics context is limited to 128. Anyway it will very likely crawl before you reach that limit. " http://wiki.oni2.net/User_talk:Neo/Archive3

"The actual number that we will be able to teleport will depend on your computer. Typically if you have more than 32 "active" AI, they'll become stupid, if more than 64, Oni will crash)." http://wiki.oni2.net/BSL:Tutorial/Scratch2

According to this screenshot, you can spawn up to 128 characters, but only 64 are active.
army0_db.jpg
You can find the script and more screenshots here: http://geyser.oni2.net/pics/screenshots/armyofme/

Note: On the Mac I'm getting the error message PHrAddCharacterToGrid: too many obstructions in one BNV,  also, Mac crashes when I try to view all the characters. As long as I spawn 59 or less AI's Mac will not crash.

Offline

#28 09/27/13 02:09

ltemplar
Member
From: Poland
Registered: 08/23/12

Re: Engine hacking questions 2

Heh... that's something...128 context limit is new to me. So actually this is the limit I should be looking for...

Well it still don't allow us to produce an army,but the lifeless objects don't need to be calculated by AI(can be visible? but not active), Only be there to be or not to be(wow smile) destroyed.They will also have less poly.. than "normal" char...

I wasn't aware of the problems the mac users have, nor that you guys can't use DLL....

Still think that Test level having such things will be a good motivator for us and others.
So EdT if you help me with export and oni importing thous objects, and scripting, I will handle the rest(create level objects etc)

Offline

#29 09/27/13 09:09

EdT
Moderator
From: Los Angeles, CA
Registered: 01/13/07
Website

Re: Engine hacking questions 2

ltemplar:  I will be glad to help with the Test Level, I want to see your version of the Deadly Brain

Edit: Also the floating weapons bug, is more likely due to physics context, rather than the number of weapons.  Physics contexts are used by dropped weapons, active chars, doors, probably powerups and other stuff such as animated objects like the crane in level1.

Do you have the script where you spawned the 60 weapons for me to test?

Edit2: Actually, in speaking with Neo, the physics context limit is 256 in PC and from my testing 60 for the Mac.

Last edited by EdT (09/27/13 09:09)

Offline

#30 09/27/13 10:09

ltemplar
Member
From: Poland
Registered: 08/23/12

Re: Engine hacking questions 2

Any level from my mod if the weapons life time is set infinite(or very high via BSL command) will have this bug. The best candidate is TCTF HQ for testing it.

256 is something to be honest.....but of course higher mens better...I'm worried about Mac version however, 60 is really low one...and making a mod only for one platform is not a god start..right?

Ok but first i will post (maybe by email) the level layout.And entire concept(nothing fancy - is only a test but, complex enough to show the idea).
Draw scan will be ok for you or full geometry?

Last edited by ltemplar (09/27/13 17:09)

Offline

#31 09/27/13 11:09

Dirk Gently
Member
From: Boston, MA
Registered: 06/12/09
Website

Re: Engine hacking questions 2

Something to make note of, there is also a limit of how many AIs can be pathing at any one time. Even if we could create armies, there is no way to make them all work at once even if the AI limits were increased. The game can only handle generating so many AI paths per frame based on how i described how the rendering engine works.

Offline

#32 09/27/13 11:09

ltemplar
Member
From: Poland
Registered: 08/23/12

Re: Engine hacking questions 2

The memory issue? Yes patch finding can be a serious problem....But there must be some way to overcome this. Maybe increasing limit of rendered objects by one frame?

Last edited by ltemplar (09/27/13 11:09)

Offline

#33 09/27/13 11:09

EdT
Moderator
From: Los Angeles, CA
Registered: 01/13/07
Website

Re: Engine hacking questions 2

ltemplar full geometry please.  I sent you an email through the forum, so you can have my email address.

I say go for what the PC can handle in your test level.  It should be a demo that pushed Oni to the limit.  Don't worry about the Mac, as mentioned between the 3 of us Mac users, we will figure things out.

Offline

#34 09/27/13 13:09

ltemplar
Member
From: Poland
Registered: 08/23/12

Re: Engine hacking questions 2

Ok.

I will send you an email of all things I have ... ]:D

EDIT1EdT: did you get an e-mail from me?
EDIT2EdT: And now?

Last edited by ltemplar (09/27/13 17:09)

Offline

#35 09/28/13 03:09

Samer
Member
From: Lebanon
Registered: 09/04/09
Website

Re: Engine hacking questions 2

This is interesting.
i hope we can increase the particle limit, and i do agree with ltemplar that ''it's too hard we're not going to even attempt it'' is not an encouraging answer to continue to mod, i know the particle limit issues have discouraged me from continuing making characters i had planned which were going to use custom particles, because i know eventually i won't be able to use them together or with packs like new weapons. So i was very dissapointed with the ''won't fix'' result on the bug tracker.
I can't contribute anything useful to the discussion, but i need to ask ...
When we have such issues that we can't fix, do we ask those who might be able to or do we just presume they won't help?
Haven't RossyMiles, Sfeli, YourMom, geyser, and gumby worked on the engine at some point, can't they be contacted and gather all the info they have on the subject, the collective info may make things easier, or ask them if they are interested in helping ?

Last edited by Samer (09/28/13 05:09)


Join our Oni Facebook Group
Check My YouTube Channel for my Oni Videos.
Check My Wiki page for all my stuff

Offline

#36 09/28/13 07:09

Iritscen
Moderator
From: NC, USA
Registered: 10/22/07

Re: Engine hacking questions 2

It's extremely unlikely that anyone has specific knowledge that would help with the particle limit except Neo, who already gave us the suggestion I placed on the bug tracker.  It's more a matter of someone being comfortable enough with the subject of memhacking that they can implement a solution.  We might try to contact Sfeli, he's the only one who is likely to be able to help.


Check out the Anniversary Edition Seven at ae.oni2.net!

Offline

#37 09/28/13 09:09

Dirk Gently
Member
From: Boston, MA
Registered: 06/12/09
Website

Re: Engine hacking questions 2

Samer wrote:

This is interesting.
i hope we can increase the particle limit, and i do agree with ltemplar that ''it's too hard we're not going to even attempt it'' is not an encouraging answer to continue to mod, i know the particle limit issues have discouraged me from continuing making characters i had planned which were going to use custom particles, because i know eventually i won't be able to use them together or with packs like new weapons. So i was very dissapointed with the ''won't fix'' result on the bug tracker.
I can't contribute anything useful to the discussion, but i need to ask ...
When we have such issues that we can't fix, do we ask those who might be able to or do we just presume they won't help?
Haven't RossyMiles, Sfeli, YourMom, geyser, and gumby worked on the engine at some point, can't they be contacted and gather all the info they have on the subject, the collective info may make things easier, or ask them if they are interested in helping ?

I take it that this "it's too hard we're not going to even attempt it" is aimed at my posts. To clarify i am all for someone trying, however I believe that if someone wants to attempt this then they should know exactly what they are walking into and how this is going to affect other aspects of the game. Oni is quite different from most games in design, to the point of being more challenging to modify due to the interconnectedness of the engine rendering to each individual aspect of the game. I am not sure if everyone fully appreciates the level of difficulty involved that requires balancing of all aspects of play.

Offline

#38 09/28/13 09:09

EdT
Moderator
From: Los Angeles, CA
Registered: 01/13/07
Website

Re: Engine hacking questions 2

To give a ray of hope to this discussion, Neo, who is probably the most knowledgable person on the Oni engine plans on making plugins for Oni to improve and fix some of the issues we have been discussing.  But he cannot give a timetable as to when it will be released, only, when he fixes all the bugs in his code.

Even Neo admits, that trying to patch the current engine is very difficult, thus, it is easier for him to write new code to replace existing code.

Until that time, we just have to live with Oni's limitation.

Offline

#39 09/28/13 11:09

Samer
Member
From: Lebanon
Registered: 09/04/09
Website

Re: Engine hacking questions 2

Dirk Gently wrote:

I take it that this "it's too hard we're not going to even attempt it" is aimed at my posts.

not really no, to be honest I didn't read all your posts Dirk, I'm referring to previous answers we got about anything engine related. for me particle limit and increasing polygon\vertices limit to allow HD characters (these are the topics that I've been very vocal about before) and the result of the bug tracker for particle limit ... and neither involved you Dirk as I recall ...
and I know\can only imagine that it's very difficult (the one time I tried to do something with hex I hated it and didn't understand a thing) ... but there were times when we thought we could never have new levels for example, but the continuous effort of the community made it possible. For engine modifications we only had few people like gumby, geyser, and sfeli who could make them, but aren't active anymore, so if those who know don't share the knowledge (or if we don't even attempt to ask them and just settle with it's too hard, we don't know how to) those who are willing to\have the basic skills to start engine modification (Dirk, Alloc, Iritscen, ltemplar?) will never be able to make any real progress.


Join our Oni Facebook Group
Check My YouTube Channel for my Oni Videos.
Check My Wiki page for all my stuff

Offline

#40 09/28/13 12:09

Dirk Gently
Member
From: Boston, MA
Registered: 06/12/09
Website

Re: Engine hacking questions 2

Samer wrote:
Dirk Gently wrote:

I take it that this "it's too hard we're not going to even attempt it" is aimed at my posts.

not really no, to be honest I didn't read all your posts Dirk, I'm referring to previous answers we got about anything engine related. for me particle limit and increasing polygon\vertices limit to allow HD characters (these are the topics that I've been very vocal about before) and the result of the bug tracker for particle limit ... and neither involved you Dirk as I recall ...
and I know\can only imagine that it's very difficult (the one time I tried to do something with hex I hated it and didn't understand a thing) ... but there were times when we thought we could never have new levels for example, but the continuous effort of the community made it possible. For engine modifications we only had few people like gumby, geyser, and sfeli who could make them, but aren't active anymore, so if those who know don't share the knowledge (or if we don't even attempt to ask them and just settle with it's too hard, we don't know how to) those who are willing to\have the basic skills to start engine modification (Dirk, Alloc, Iritscen, ltemplar?) will never be able to make any real progress.

My apologies then. I've been out of touch with many of the people that might have the knowledge to undertake something like this, i am very open to hear anything new that can be brought to the table.

Offline

#41 12/07/14 16:12

Noneatme
Member
From: Germany, Niedersachsen
Registered: 05/01/14
Website

Re: Engine hacking questions 2

I think removing the limits is possible. Back in the days were oni was developed they had very bad computers and they probably added the limits just in case.
I can tell this because Rockstar Games did the same thing in GTA, and modders (MTA) removed the limits.
(If you want to read more about the engine hacking of GTA:SA, I cannot post links that's sad. Write a PM to me)____ Links ___ (...) here for the streaming problem, fixed by engine manipulation. I think you can transfer the logic right into the bungie framework.)


Greetings

Offline

#42 12/07/14 18:12

Iritscen
Moderator
From: NC, USA
Registered: 10/22/07

Re: Engine hacking questions 2

Welcome.  There has been some progress in replacing the graphics code in order to make small improvements like raising the limits, so we can still hold out hope.  Sorry about the link-blocking of new members, but you can probably paste the URL by adding some spaces to it or something.


Check out the Anniversary Edition Seven at ae.oni2.net!

Offline

Board footer

Powered by FluxBB