Outerra forum

Please login or register.

Login with username, password and session length
Advanced search  

News:

Download Outerra Tech Demo. Unofficial Outerra Discord server, MicroProse Discord server for OWS.

Pages: 1 ... 7 8 [9] 10 11 ... 20

Author Topic: CARsim  (Read 189148 times)

SteelRat

  • Sr. Member
  • ****
  • Posts: 380
  • newbie
Re: CARsim
« Reply #120 on: December 30, 2015, 09:48:47 pm »

SteelRat + PytonPago =



 :)

Are in your plans adding some recoil?

Если Cameni поделится партиклами, то можно и такое)

А пока ZU23

Logged

PytonPago

  • Hero Member
  • *****
  • Posts: 2284
  • It´s way too complex, dont let me try to explain !
Re: CARsim
« Reply #121 on: December 31, 2015, 12:35:04 am »

For a realistic recoil, there could be some wheels in places of the stand-legs, that would have a constant brake force applied. Then when firing, it would slightly push it away. But it had to have a variation od slip-coeficients for various surfaces, otherwise, it wouldnt look realistic on concrete vs. soil.  But on vehicles, its easy. Will rock the suspension.

But it rotates a little bit too fast ... cant imagine wielding those levers like that. :D ( ... and i dont know how the ratio of rotation between the valves and the gun direction/elevation movement looks like. Couldnt find any info about it.)
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: CARsim
« Reply #122 on: December 31, 2015, 09:20:49 am »

Quote
For a realistic recoil, there could be some wheels in places of the stand-legs, that would have a constant brake force applied. Then when firing, it would slightly push it away. But it had to have a variation od slip-coeficients for various surfaces, otherwise, it wouldnt look realistic on concrete vs. soil.  But on vehicles, its easy. Will rock the suspension.

Code: [Select]
this.extra_force(modelSpacePos, forceVec);
Я уверен с помощью этого можно будет реализовать.

Quote
But it rotates a little bit too fast ... cant imagine wielding those levers like that. :D ( ... and i dont know how the ratio of rotation between the valves and the gun direction/elevation movement looks like. Couldnt find any info about it.)

Code: [Select]
const MAX_TURRET_X_SPEED = 1; // deg/dt
const MAX_TURRET_Y_SPEED = 1; // deg/dt

Я вижу что нужно убавить значения).

Code: [Select]
this.register_axis("car/weapons/mantlet", {minval:-1, maxval:1, center:1000, vel:1000, acc:1000}, function(v, dt) {
this.mantletVal = v;
}, 0);

this.register_axis("car/weapons/turret", {minval:-1, maxval:1, center:1000, vel:1000, acc:1000}, function(v, dt) {
this.turretVal = v;
}, 0);

Игровым контролёром можно будет управлять скоростью.

PS
У меня есть вопрос.
Два орудия(KPV_14_5mm_GunL, KPV_14_5mm_GunR) производят выстрелы синхронно?
Сейчас реализовано так
Code: [Select]
if (this.fireCurrent == "L") {
// Gun KPV_14_5mm_GunL fired
this.fireCurrent = "R";
} else {
// Gun KPV_14_5mm_GunR fired
this.fireCurrent = "L";
}
« Last Edit: December 31, 2015, 09:27:23 am by SteelRat »
Logged

PytonPago

  • Hero Member
  • *****
  • Posts: 2284
  • It´s way too complex, dont let me try to explain !
Re: CARsim
« Reply #123 on: December 31, 2015, 11:59:46 am »

Synchronically as you step on the pedals ... basically each pedal for one of the guns, but i made them in the model in a single mesh (so it should be sinchronized like this). I could separate them, then you could fire each by a separate command ...
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: CARsim
« Reply #124 on: December 31, 2015, 03:25:28 pm »

Synchronically as you step on the pedals ... basically each pedal for one of the guns, but i made them in the model in a single mesh (so it should be sinchronized like this). I could separate them, then you could fire each by a separate command ...

Я так скажу, клавиатура и мышь это всё таки не реальность, если бы мы строили симулятор ZU23, а игровым контролёром была бы реальная ZU23  :), это другое дело, я бы оставил так как есть, для удобства управления.

Будет два типа стрельбы, одиночный выстрел, и автоматический.
Logged

PytonPago

  • Hero Member
  • *****
  • Posts: 2284
  • It´s way too complex, dont let me try to explain !
Re: CARsim
« Reply #125 on: January 01, 2016, 07:11:13 am »

Synchronically as you step on the pedals ... basically each pedal for one of the guns, but i made them in the model in a single mesh (so it should be sinchronized like this). I could separate them, then you could fire each by a separate command ...

Я так скажу, клавиатура и мышь это всё таки не реальность, если бы мы строили симулятор ZU23, а игровым контролёром была бы реальная ZU23  :), это другое дело, я бы оставил так как есть, для удобства управления.

Будет два типа стрельбы, одиночный выстрел, и автоматический.


 ... if someone had pedals from a steering wheel or a flight-set, it would be possible ... ill split it for possible future use. Doe, you dont have to implement anything like that.
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: CARsim
« Reply #126 on: January 01, 2016, 08:36:05 am »

Synchronically as you step on the pedals ... basically each pedal for one of the guns, but i made them in the model in a single mesh (so it should be sinchronized like this). I could separate them, then you could fire each by a separate command ...

Я так скажу, клавиатура и мышь это всё таки не реальность, если бы мы строили симулятор ZU23, а игровым контролёром была бы реальная ZU23  :), это другое дело, я бы оставил так как есть, для удобства управления.

Будет два типа стрельбы, одиночный выстрел, и автоматический.


 ... if someone had pedals from a steering wheel or a flight-set, it would be possible ... ill split it for possible future use. Doe, you dont have to implement anything like that.

Можно разделить, для меня не проблема создать переключатель.

Я сейчас добавляю в модель нужные мне точки, к которым я обращаюсь из скрипта.
Когда закончу отдам вам модель, вы приведёте её в порядок, при импорте в Outerra у меня есть ошибки, но на мою работу это не влияет. Мои упражнения с 3D редактором можно сравнить с заточкой карандаша топором)
Logged

PytonPago

  • Hero Member
  • *****
  • Posts: 2284
  • It´s way too complex, dont let me try to explain !
Re: CARsim
« Reply #127 on: January 01, 2016, 01:40:38 pm »

No problem ... just do what ya like to in scripts and let me know what ya need in 3D.  :))
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: CARsim
« Reply #128 on: January 02, 2016, 09:02:27 pm »

Logged

Uriah

  • Global Moderator
  • Hero Member
  • *****
  • Posts: 569
  • We do these things not because they are easy. -JFK
Re: CARsim
« Reply #129 on: January 03, 2016, 12:13:52 am »

Nice!  :D

How are you implementing the rate of fire? I haven't been able to come up with a good function where you simply define the rate of fire in rounds per minute, and the function calls the fire method at that rate.

Regards,
Uriah
Logged

SteelRat

  • Sr. Member
  • ****
  • Posts: 380
  • newbie
Re: CARsim
« Reply #130 on: January 03, 2016, 08:13:53 am »

Nice!  :D

How are you implementing the rate of fire? I haven't been able to come up with a good function where you simply define the rate of fire in rounds per minute, and the function calls the fire method at that rate.

Regards,
Uriah

Code: [Select]
// ZS-23-2.js

const RATE_OF_FIRE = 60 / 1000; // sec, темп срельбы ЗУ 23-2, (800 -> 1000) выстрелов в минуту

function init_vehicle() {
...
this.fireTime = 0;
}

function update_frame(dt) {
...
this.fireTime += dt;
if (this.fireTime >= RATE_OF_FIRE) {
...
this.fireTime = 0;
}
}
Logged

Uriah

  • Global Moderator
  • Hero Member
  • *****
  • Posts: 569
  • We do these things not because they are easy. -JFK
Re: CARsim
« Reply #131 on: January 03, 2016, 07:36:08 pm »

Nice, reset fireTime to zero each time it exceeds the constant! That's so simple and perfect. Thanks! :-)

Regards,
Uriah
« Last Edit: January 03, 2016, 07:40:30 pm by Uriah »
Logged

SteelRat

  • Sr. Member
  • ****
  • Posts: 380
  • newbie
Re: CARsim
« Reply #132 on: January 04, 2016, 12:36:54 pm »

Logged

PytonPago

  • Hero Member
  • *****
  • Posts: 2284
  • It´s way too complex, dont let me try to explain !
Re: CARsim
« Reply #133 on: January 04, 2016, 01:27:29 pm »

круто с прицелом !  ... im making some ammo crates for it now too. And 3-types of munition : БЗТ, ФЗТ and ОФЗТ.



... whats that LAN-Party ? :D
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: CARsim
« Reply #134 on: January 04, 2016, 02:33:03 pm »

Code: [Select]
$include("ammunition/ammo_23x152_ait.js");
$include("ammunition/ammo_23x152_hei.js");
$include("ammunition/ammo_23x152_heit.js");
$include("ammunition/mag_23x152x80_4hei_1ait.js");
:)

Code: [Select]
var localization = {
ammo_23x152_ait_displayName: {
en: "Ammo 23x152 AIT",
ru: "Снаряд 23x152 БЗТ"
},
ammo_23x152_ait_description: {
en: "",
ru: "Бронебойно-зажигательно-трассирующий снаряд"
},
ammo_23x152_hei_displayName: {
en: "Ammo 23x152 HEI",
ru: "Снаряд 23x152 ОФЗ"
},
ammo_23x152_hei_description: {
en: "",
ru: "Осколочно-фугасный-зажигательный снаряд"
},
ammo_23x152_heit_displayName: {
en: "Ammo 23x152 HEIT",
ru: "Снаряд 23x152 ОФЗТ"
},
ammo_23x152_heit_description: {
en: "",
ru: "Осколочно-фугасный-зажигательно-трассирующий снаряд"
},

mag_23x152x80_empty_displayName: {
en: "Magazine ammo 23x152 empty",
ru: "Магазин снарядов 23x152 пустой"
},
mag_23x152x80_empty_description: {
en: "",
ru: "Для ЗУ-23-2"
},
mag_23x152x80_4hei_1ait_displayName: {
en: "Magazine ammo 23x152 80pcs",
ru: "Магазин снарядов 23x152 80шт"
},
mag_23x152x80_4hei_1ait_description: {
en: "",
ru: "Очерёдность снарядов: 4 ОФЗ, 1 БЗТ\n Для ЗУ-23-2"
}
};
Logged
Pages: 1 ... 7 8 [9] 10 11 ... 20