Outerra forum

Please login or register.

Login with username, password and session length
Advanced search  

News:

Outerra Tech Demo download. Help with graphics driver issues

Pages: 1 ... 3 4 [5] 6 7 ... 11

Author Topic: AKs  (Read 85298 times)

PytonPago

  • Hero Member
  • *****
  • Posts: 2284
  • It´s way too complex, dont let me try to explain !
Re: AKs
« Reply #60 on: December 24, 2014, 08:26:35 am »

Well see. The merc is a promo thing right now and i have no idea when characters can be added whyte custom animations for them, but i plan some soldier model too. As for weapon - i hope to make a realistic ballistic trajectory for those (whyte fitting optics to it (maybe even a option to adjust them and the stock ones)) and those animations too, but i want still some few more parts added to be able to speculate whyte modularity options. 
Logged
We are still undeveloped as long as we don´t realize, that all our science is still descriptive, and than beyond that description lies a whole new world we just haven´t even started to fully understand.

Uriah

  • Global Moderator
  • Hero Member
  • *****
  • Posts: 569
  • We do these things not because they are easy. -JFK
Re: AKs
« Reply #61 on: December 24, 2014, 12:30:24 pm »

It looks like the merc's rifle is a seperate object. If you would like a can figure out how to replace the original with your AK. Also if I can call methods from a script for the AK you can include all the modular accessories in the FBX and hide different combinations of visible parts so that you toggle through different configurations in game. If you can send me an FBX file with a list of names for each part I can code up an example. I was already able to load a different weapon for the merc that I downloaded free of Turbo Squid. I would love to see if we can get the AK fully working in game. Character animations will have to wait of course.

EDIT: I found your DAE and blender files, that's all I need. I found a way to include scripts for static objects. I can call some methods and not others like I could for a vehicle. But it is a work in progress. I'll let you know how this works with hiding/un-hiding parts. Need to bind it to a keyboard input to toggle weapon configurations too but that's easy once I get a script working for the AK.

Regards,
Uriah
« Last Edit: December 24, 2014, 12:52:54 pm by Uriah509 »
Logged

PytonPago

  • Hero Member
  • *****
  • Posts: 2284
  • It´s way too complex, dont let me try to explain !
Re: AKs
« Reply #62 on: December 24, 2014, 01:44:23 pm »

It looks like the merc's rifle is a seperate object. If you would like a can figure out how to replace the original with your AK. Also if I can call methods from a script for the AK you can include all the modular accessories in the FBX and hide different combinations of visible parts so that you toggle through different configurations in game. If you can send me an FBX file with a list of names for each part I can code up an example. I was already able to load a different weapon for the merc that I downloaded free of Turbo Squid. I would love to see if we can get the AK fully working in game. Character animations will have to wait of course.

EDIT: I found your DAE and blender files, that's all I need. I found a way to include scripts for static objects. I can call some methods and not others like I could for a vehicle. But it is a work in progress. I'll let you know how this works with hiding/un-hiding parts. Need to bind it to a keyboard input to toggle weapon configurations too but that's easy once I get a script working for the AK.

Regards,
Uriah

 ... And i thought you were busy with the rockets :D Im still waiting for a little more info about characters for this - http://forum.outerra.com/index.php?topic=2821.msg29563#msg29563

 .. and some other, yet a little secret stuff. But the main plan is to do a working set of these weapons, an custom animated soldier (with various stances etc.) and, when the Ural project is near completion and the BTR-80 (doe, those are the biggest brakes it seems, outside time, as i constantly run in some modeling information issues (mostly bound to not having a nice photo-collection or special info-source)), an additional set of animations n interactions with them. If that is pulled out in some time, then i can start seriously on the brother vision of mine ... but must still learn a lot of things ... would like to know the most of the skill-sets to pull that out myself (or understanding them properly).

As for the AK - i know the RPG-7M model was a part of it, also you ,ay sometimes see the issue of scopes being swapped at certain angles/distances, so yes, it will be probably an additionally placed separate model bound to the right hand bone of the model - there should be some way to identify the placement of the gun (that it is at spawn with the hand-guard at the mercenaryes hands) and the one for the "ballistic effect" at shooting. Not sure how those are defined and about the background needs at model and script level. AngryPig said they had an little insight planned for that for us, doe a lot of other things must be finished first and also, the merc is probably not yet ready in regards of a ton of aditional stuff (Hit-meshes, collisions, inventory n weapon systems, extended animations etc). So i mostly am doing the main model stuff till some more bits come to light gradually (i have a lot of stuf there to do anyway till i can do what i intend there). So, no real timelines for my works in progress, nor is the pressure-monster breathing on my neck (well maybe the one i imagine myself).  ;D

Its kinda partly like your project too, i could do accessories as totally separate models placed properly with an extended scripting system to allow use theyr functionalityes when "added" to the certain weapons/vehicles, but at a variational level as i intend, i have to think first what bits will be segregated like that and witch not. As a example - scopes could be as separates each one, where all could have the same script for usage (yes, different animations at needed places) with only changing the "scope-sight" eye view positions and the placing positions accordingly at each one. Problem is doe that there are plenty weapons, that can use the same scope, but the construction intends them at different places in regards to the hand of the mercenary as the weapons it-selves. i would like so have a possibility to have an modifier for the soldier animations, for setting the stocks right at place of the character (mainly that the distance of the hand-shoulder would be set specially for each weapon due to theyr model scales and ergonomics, but maybe have also the possibility to change them on fly - like modular stocks on the M4s to give it forward-backward  --- this also having some effect in playability/gameplay from the "soldiers" view whyle aiming n stuff). Im studying the ARMA way of some things, but found, they just have all the weapon-combinations as separate models with the accessories and some things at character building (modularity of cloths) is needed to be thought rightly off too (but if i get it right, they made special custom animations for each piece of cloth on them, blending perfectly at the joints).

  Can quite imagine one day, that head-tracking could be in someway engaged in weapons handling from the 1st view, or additional controllers ( imagine the two WII controllers being your hands at hand-grip and front stock of the weapon and aligning aim both with hands and head-movement ) -- and yes, just as an separate play-modus, the basic mouse view control is intended to stay. I personally see it as a interesting development in future gaming not only in hardcore sims, but simple shooters, like CoD, or Battlefield-like games too. And i like the process and things behind such things getting to life (even if just from the limited free-time n knowledge in programing i have yet). ... yet something of a similar sort of stuff at handling special vehicle functions (like aiming the BM-21 rocket system, or using gunner and equipment operation positions n full-click cockpits).

Now additionally to it, think of something, not only hardening your life due to weather/terrain and health conditions, but making actual, light effect of psychological impacts. Yes, storyline are the main focus there, but, imagine going trough something as an controlled, simulated shell-shock experience (with no prolonged or real-life side effects off course, no intention to ruin someones head with it) trough visual and sound influences when really bad things going on at battlefield. Something like an sensual punishment and award addition, using just some psychology lessons, the screen and the sound at the headphones.

It is kinda complicated what i have in mind, but i hope you get a piece of the mirror by what i write.
« Last Edit: December 24, 2014, 01:50:09 pm by PytonPago »
Logged
We are still undeveloped as long as we don´t realize, that all our science is still descriptive, and than beyond that description lies a whole new world we just haven´t even started to fully understand.

SteelRat

  • Sr. Member
  • ****
  • Posts: 380
  • newbie
Re: AKs
« Reply #63 on: May 09, 2015, 04:51:33 pm »

Logged

PytonPago

  • Hero Member
  • *****
  • Posts: 2284
  • It´s way too complex, dont let me try to explain !
Re: AKs
« Reply #64 on: May 10, 2015, 01:00:01 am »



What the ? .... how ? ... i crashed my OT a ton of times trying to meld it to the mercenary ! ( ... some attachment definition problems there and a need for mesh-hiding lines, but i want ! )
Logged
We are still undeveloped as long as we don´t realize, that all our science is still descriptive, and than beyond that description lies a whole new world we just haven´t even started to fully understand.

SteelRat

  • Sr. Member
  • ****
  • Posts: 380
  • newbie
Re: AKs
« Reply #65 on: May 10, 2015, 12:06:25 pm »

Rename file
Code: [Select]
scripts\hero.jsin
Code: [Select]
scripts\hero.js~
Create file
Code: [Select]
// scripts\hero.js
$include("scripts/mercenary.js");

Create file
Code: [Select]
// scripts\mercenary.js

"use strict";

/*
called at the end of hero constructor
*/

function initialize(reload)
{
this.set_character_model("outerra/mercenary/mercenary");
this.set_weapon_model("SteelRat/AK-74M_Series/AK-74M_Series"); // You package name
}

/*
called when all geoms are loaded and ready for use
*/
function deferred_initialize()
{

this.geom = this.get_geomob(0);  // get first geometry instance (the first one is always the main geometry object)
this.weapon = this.get_geomob(1);
this.layer0 = this.geom.get_animation_stack().create_blend_tree("weapon_up"); // blending between layers is not finished!

var data = [
{name:"P02_walk_neutral_01.anim", offset:0, pos:{x: 0.0, y: 0.5}},
{name:"P02_run_02.anim", offset:0, pos:{x: 0.0, y: 1.0}},
{name:"P02_walk_backward_01.anim", offset:0, pos:{x: 0.0, y:-0.5}},
{name:"P02_run_backward_01.anim", offset:0, pos:{x: 0.0, y:-1.0}},
{name:"P02_walk_strafe_left_01.anim", offset:18, pos:{x:-0.5, y: 0.0}},
{name:"P02_walk_strafe_right_01.anim", offset:0, pos:{x: 0.5, y: 0.0}},
{name:"P02_run_strafe_right_01.anim", offset:0, pos:{x: 1.0, y: 0.0}},
{name:"P02_run_strafe_left_01.anim", offset:0, pos:{x:-1.0, y: 0.0}},
{name:"P02_idle_breathe_01.anim", offset:0, pos:{x: 0.0, y: 0.0}},
];

for (var i in data) {
var anim = this.geom.load_animation(data[i].name, "", data[i].offset);
this.layer0.add_node(anim, data[i].pos, 1.0);
}
}

function update_frame(dt)
{

}

Weapon config
Code: [Select]
// AK-74M_Series.objdef

{   
"obj" : "AK-74M_Series",
"matlib" : "AK-74M_Series",
"lod_curve" : 850,
"lod_curve1" : 300,
"physics" : "",
"script" : "",
"description" : "AK-74M_Series",
"parameters" : "",
"fdm_root_dir" : ""

Bad idea to gather all in one package. It is not flexible, and headache for coding.

And developers need standartization and more detailed preliminary configuration packages.
« Last Edit: May 10, 2015, 12:17:28 pm by SteelRat »
Logged

PytonPago

  • Hero Member
  • *****
  • Posts: 2284
  • It´s way too complex, dont let me try to explain !
Re: AKs
« Reply #66 on: May 10, 2015, 12:33:02 pm »

That is certainly interestin ...

  ... yes, standardization has a big role in modding stuff as weapons, is surely a big deal. Id say, when weapons are in a special folder meant for them, each with theyr own definition files, than the mercenary script could handle to have seletable veapons based on the existing weapon-folders and theyr definition files. Qestion remains, can the weapons have still theyr own .js files, that would allow them to have visible parts defined ( ... doe i see its the package name there, so if i have more versions defined ... ill have to try this ...) ? If yes, it would be great, if not ... well, there would be another way to do things : - making each part of the weapon (witch would be changable/selectable) and have a script, that would give the ability to select custom parts of it to be visible - doe, there would be then a need for each object type with some function to be defined - like magazines, optics, movable parts that would have defined animations and options (like reticule movement to have the ability to zero them on some range) ... doe, its probably more Camenis guys to figure these out the best way (or the TitanIM guys, not sure how far Cameny plans to go in this for his own OT goals as its probably more a game-developer thing ?).

  Thanks SteelRat ! ( if ya dont get much of this post in Eng, than let me know and i give ya a russian translation in PM ;) )
« Last Edit: May 10, 2015, 12:43:34 pm by PytonPago »
Logged
We are still undeveloped as long as we don´t realize, that all our science is still descriptive, and than beyond that description lies a whole new world we just haven´t even started to fully understand.

SteelRat

  • Sr. Member
  • ****
  • Posts: 380
  • newbie
Re: AKs
« Reply #67 on: May 10, 2015, 01:12:36 pm »

Нам приходится иметь дело с тем что имеем на текущий момент).

Большое не удобство с оружием в том, что оружие придётся конфигурировать в скрипте инициализирующем персонажа, и ещё большая проблема в том, что приходится модифицировать оригинальный файл игры, нельзя задать скрипт с другим именем для инициализации персонажа.

В результате мы имеем вот что, если вы добавляете новый пакет с оружием, то придётся редактировать файл hero.js что бы добавить конфигурацию нового оружия, из за чего скрипт разрастётся до не приличных размеров), и будет постоянно вычислять массу не актуальных данных, это очень плохо.

Будут ли разработчики заниматься этим? Я думаю нет, во всяком случае в ближайшее время точно не будут.

А других развлечений пока всё равно нет).
Logged

PytonPago

  • Hero Member
  • *****
  • Posts: 2284
  • It´s way too complex, dont let me try to explain !
Re: AKs
« Reply #68 on: May 10, 2015, 01:32:58 pm »


Будут ли разработчики заниматься этим? Я думаю нет, во всяком случае в ближайшее время точно не будут.


 ... if not Camenys boys, than the TitanIM guys, im certain. But, they will make the engine modifyable, to design your own way to handle persons, weapons and other stuff in the future anyway, so in time, all will be possible. Doe, you have right, not in the near future - they have plenty do to untill they can play around whyte little problems like this right now.
Logged
We are still undeveloped as long as we don´t realize, that all our science is still descriptive, and than beyond that description lies a whole new world we just haven´t even started to fully understand.

SteelRat

  • Sr. Member
  • ****
  • Posts: 380
  • newbie
Re: AKs
« Reply #69 on: May 10, 2015, 01:41:30 pm »

If it has that interesting, will share information)
Logged

SteelRat

  • Sr. Member
  • ****
  • Posts: 380
  • newbie
Re: AKs
« Reply #70 on: May 11, 2015, 06:15:03 pm »

Hi PytonPago!

Предварительный вариант идеи, в работе не проверялся)
Logged

PytonPago

  • Hero Member
  • *****
  • Posts: 2284
  • It´s way too complex, dont let me try to explain !
Re: AKs
« Reply #71 on: May 12, 2015, 01:59:40 am »

Hi PytonPago!

Предварительный вариант идеи, в работе не проверялся)

-----------------------------------

The initial state of the idea, haven't tested if its working yet  ...  (translation - for others)

-----------------------------------

 ... interesting ... if im right, config.js is defining first all meshes in the package and then the load-out of meshes for the AK, its optical device and launcher ... then function.js is there to select, witch packages should be taken by the mercenary´s script to render and finally, in initCharacter, you choose the weapon by its "name-tag" you gave them in config.js.

I kinda like this script, its well visible, what is in the packages, and seem to be easy to add other weapon-types just by making another set of lines like those .... has even partitioning in magazines, items, launchers ! Great script there SteelRat ... need to try that out when im back on my home PC.

One question here ... "AK_74M:", "Optic_1P29:" and others in the config.js, are in script-terms a function ? Or its just an definition of a set of variables ?

Also, if im right, the "scope: true," line says, that it should be included in the rendered parts later in function.js ... so, would be there be an option in the future, to change these to "true/false" thanks to external means ? (idea is, when you had the mercenary, and you would call up a window with a list of items capable of being rendered, you could then select them by means of a checking-box ... lets say, the script behind it would first check, what components are listed in the config.js and then construct a list of all the parts ( "AK_74M:", "Optic_1P29:" and others) respectively in sections of weapons/magazines/items/launchers, all with a checking-box to change their "scope: ," value to true and false).
 --- would be great to have such thing working. I like that config.js structure, so if each OT-imported weapon would be a separate model with such a set of scripts and the window could search for all of them within some folder in Outerras directory (witch would be reserved for weapons), it would be an awesome in-game weapon changing and modifying tool.

Also, Cameni, if ya reading these things, would it be possible in the future to be able to define placing of individual meshes for weapons ? My idea was, that on picatini rails (or RIS rails), you could customize yourself the placing of optics and other equipment on its length ... it would be an interesting thing, witch I newer seen before done in a game and it would help to set special sets of equipment ( like when ya want to have a magnifier behind an optical device, you wouldn't need to make another mesh with both, but you would just turn both rendered in script and set theyr placing to be one behind another - it also would be then possible, to use all optical devices and magnifiers in combination very easily ). Or is it working the same way as vehicle-scripts and i can just add a "move-mesh script" (this.geom.move_joint_orig(this.weaponpart, {x:0,y:0,z:offset});) in the mercenary's .js script ( that is the Anteworld/scripts/hero.js in a clean OT installation ) ? Id also could use it to set the correct placing of the gun into his hands, instead of tampering with the guns model origin/pivot point.



« Last Edit: May 12, 2015, 02:03:33 am by PytonPago »
Logged
We are still undeveloped as long as we don´t realize, that all our science is still descriptive, and than beyond that description lies a whole new world we just haven´t even started to fully understand.

PytonPago

  • Hero Member
  • *****
  • Posts: 2284
  • It´s way too complex, dont let me try to explain !
Re: AKs
« Reply #72 on: May 12, 2015, 02:16:11 am »

Now i also got an interesting idea ... as all weapons have their handles/stocks at slightly different places and animations could be modified by increasing/decreasing the rotation angles of its bones, maybe there could be also another script-part where such corrections in angles could be defined as an off-set from the basic animation for each weapon and its modification, so the weapon would be held properly no matter, what thing the character has selected ... it also would have the ability to have several sets of there to have different placings of hands (AK users know well, as normally you can hold the gun on its front-stock, or at the magazines base - some slight handling differences could be then defined too if one would want to make some physiological enhancement of weapon-handling in a game) ... just thoughts, but it would be an interesting way to set weapon-selective-configurations.

But its true, one would have to set the off-sets for all three arm-joins ( arm, elbow, hand, --- well, i guess even fingers would go, but that would be an overkill :D )
« Last Edit: May 12, 2015, 02:18:45 am by PytonPago »
Logged
We are still undeveloped as long as we don´t realize, that all our science is still descriptive, and than beyond that description lies a whole new world we just haven´t even started to fully understand.

cameni

  • Brano Kemen
  • Outerra Administrator
  • Hero Member
  • *****
  • Posts: 6721
  • No sense of urgency.
    • outerra.com
Re: AKs
« Reply #73 on: May 12, 2015, 03:05:35 am »

Also, Cameni, if ya reading these things, would it be possible in the future to be able to define placing of individual meshes for weapons ? My idea was, that on picatini rails (or RIS rails), you could customize yourself the placing of optics and other equipment on its length ... it would be an interesting thing, witch I newer seen before done in a game and it would help to set special sets of equipment ( like when ya want to have a magnifier behind an optical device, you wouldn't need to make another mesh with both, but you would just turn both rendered in script and set theyr placing to be one behind another - it also would be then possible, to use all optical devices and magnifiers in combination very easily ). Or is it working the same way as vehicle-scripts and i can just add a "move-mesh script" (this.geom.move_joint_orig(this.weaponpart, {x:0,y:0,z:offset});) in the mercenary's .js script ( that is the Anteworld/scripts/hero.js in a clean OT installation ) ? Id also could use it to set the correct placing of the gun into his hands, instead of tampering with the guns model origin/pivot point.

If it's a sub-mesh then it can be moved freely via the geom api. Problem will be when you also want the optics to work accordingly :)
Logged

SteelRat

  • Sr. Member
  • ****
  • Posts: 380
  • newbie
Re: AKs
« Reply #74 on: May 12, 2015, 09:06:53 am »

Quote
One question here ... "AK_74M:", "Optic_1P29:" and others in the config.js, are in script-terms a function ? Or its just an definition of a set of variables ?

cfgWeapon this variable, type "Object". Эта переменная хранит параметры модели, например "AK_74M", то есть, всех объектов "class Weapon", другого более подходящего определения "class" я не могу подобрать. Конфигурации объектов очень удобно создавать на основе "наследуемых классов", я положительно оценил такой подход в другом проекте.

Файлу config.js можно дать другое имя, например variables.js и это будет тоже корректно, но имя файла config.js более точно выражает суть того что находится внутри этого файла, так удобнее для восприятия).

"AK_74M" this property, type "Object", is in the "cfgWeapon". В этом параметре вы описываете, можно сказать создаёте, объект "AK_74M", и к тому что я уже предложил в описании данного объекта, можно добавить много разного ещё.
Такие объекты как "magazine", "item", "launcher", их описание размещено в другом хранилище "cfgVariable", с целью, заглядывая вперёд, предоставить себе более гибкие возможности реализации взаимодействия с инвентарём(Inventory).

И для обработки всего того что лежит в файле config.js, будут добавляться функции в файл "functions.js".
Logged
Pages: 1 ... 3 4 [5] 6 7 ... 11