mirror of
https://github.com/APercy/ap_airship.git
synced 2025-03-14 23:41:21 +00:00
extendend the passengers capacity to 12
This commit is contained in:
parent
1a0d0b1f3d
commit
6b03e50dbe
3 changed files with 20 additions and 26 deletions
37
entities.lua
37
entities.lua
|
@ -458,32 +458,19 @@ minetest.register_entity("ap_airship:airship", {
|
|||
ap_airship.paint2(self, self.color2)
|
||||
local pos = self.object:get_pos()
|
||||
|
||||
self._passenger_is_sit = ap_airship.copy_vector({[1]=0, [2]=0, [3]=0, [4]=0, [5]=0,})
|
||||
self._passengers_base = ap_airship.copy_vector({[1]=nil, [2]=nil, [3]=nil, [4]=nil, [5]=nil,})
|
||||
self._passengers_base_pos = ap_airship.copy_vector({[1]=nil, [2]=nil, [3]=nil, [4]=nil, [5]=nil,})
|
||||
self._passengers_base_pos = {
|
||||
[1]=ap_airship.copy_vector(ap_airship.passenger_pos[1]),
|
||||
[2]=ap_airship.copy_vector(ap_airship.passenger_pos[2]),
|
||||
[3]=ap_airship.copy_vector(ap_airship.passenger_pos[3]),
|
||||
[4]=ap_airship.copy_vector(ap_airship.passenger_pos[4]),
|
||||
[5]=ap_airship.copy_vector(ap_airship.passenger_pos[5]),} --curr pos
|
||||
--self._passengers = {[1]=nil, [2]=nil, [3]=nil, [4]=nil, [5]=nil,} --passenger names
|
||||
|
||||
self._passengers_base[1]=minetest.add_entity(pos,'ap_airship:stand_base')
|
||||
self._passengers_base[1]:set_attach(self.object,'',self._passengers_base_pos[1],{x=0,y=0,z=0})
|
||||
|
||||
self._passengers_base[2]=minetest.add_entity(pos,'ap_airship:stand_base')
|
||||
self._passengers_base[2]:set_attach(self.object,'',self._passengers_base_pos[2],{x=0,y=0,z=0})
|
||||
|
||||
self._passengers_base[3]=minetest.add_entity(pos,'ap_airship:stand_base')
|
||||
self._passengers_base[3]:set_attach(self.object,'',self._passengers_base_pos[3],{x=0,y=0,z=0})
|
||||
|
||||
self._passengers_base[4]=minetest.add_entity(pos,'ap_airship:stand_base')
|
||||
self._passengers_base[4]:set_attach(self.object,'',self._passengers_base_pos[4],{x=0,y=0,z=0})
|
||||
|
||||
self._passengers_base[5]=minetest.add_entity(pos,'ap_airship:stand_base')
|
||||
self._passengers_base[5]:set_attach(self.object,'',self._passengers_base_pos[5],{x=0,y=0,z=0})
|
||||
--passengers positions
|
||||
self._passenger_is_sit = ap_airship.copy_vector({})
|
||||
self._passengers_base = ap_airship.copy_vector({})
|
||||
self._passengers_base_pos = ap_airship.copy_vector({})
|
||||
for i = 1,ap_airship.max_pos,1
|
||||
do
|
||||
self._passenger_is_sit[i] = 0
|
||||
self._passengers_base_pos[i] = ap_airship.copy_vector(ap_airship.passenger_pos[i])
|
||||
self._passengers_base[i]=minetest.add_entity(pos,'ap_airship:stand_base')
|
||||
self._passengers_base[i]:set_attach(self.object,'',self._passengers_base_pos[i],{x=0,y=0,z=0})
|
||||
end
|
||||
|
||||
--constrols interactors
|
||||
self._control_interactor=minetest.add_entity(pos,'ap_airship:control_interactor')
|
||||
self._control_interactor:set_attach(self.object,'',{x=0,y=-28,z=175},{x=0,y=0,z=0})
|
||||
self._cabin_interactor=minetest.add_entity(pos,'ap_airship:cabin_interactor')
|
||||
|
|
0
extended_collision_system.lua
Normal file
0
extended_collision_system.lua
Normal file
9
init.lua
9
init.lua
|
@ -8,7 +8,7 @@ ap_airship.rudder_limit = 30
|
|||
ap_airship.iddle_rotation = 50
|
||||
ap_airship.max_engine_acc = 1.5
|
||||
ap_airship.max_speed = 8
|
||||
ap_airship.max_pos = 5
|
||||
ap_airship.max_pos = 12
|
||||
ap_airship.max_seats = 21
|
||||
ap_airship.pilot_base_pos = {x=0.0,y=-29,z=170}
|
||||
ap_airship.passenger_pos = {
|
||||
|
@ -17,6 +17,13 @@ ap_airship.passenger_pos = {
|
|||
[3] = {x=32,y=0,z=20},
|
||||
[4] = {x=-32,y=0,z=80},
|
||||
[5] = {x=32,y=0,z=80},
|
||||
[6] = {x=0.0,y=0,z=50},
|
||||
[7] = {x=-32,y=0,z=30},
|
||||
[8] = {x=32,y=0,z=30},
|
||||
[9] = {x=-32,y=0,z=70},
|
||||
[10] = {x=32,y=0,z=70},
|
||||
[11] = {x=0.0,y=0,z=40},
|
||||
[12] = {x=0.0,y=0,z=30},
|
||||
}
|
||||
|
||||
ap_airship.canvas_texture = "wool_white.png^[colorize:#f4e7c1:128"
|
||||
|
|
Loading…
Add table
Reference in a new issue