Castrum 1.7.0 upload

Game-5.3.0
Der1248 2018-11-11 13:49:33 +01:00
parent e831bd9fa7
commit 5bd096f175
5 changed files with 1593 additions and 610 deletions

Binary file not shown.

434
mods/castrum/Chapter5.lua Normal file
View File

@ -0,0 +1,434 @@
local list = {
{1, {x=-173, y=9, z=-70},{x=-172, y=9, z=-70},2},
{2, {x=-173, y=9, z=-62},{x=-172, y=9, z=-62},2},
{3, {x=-171, y=9, z=-69},{x=-170, y=9, z=-69},2},
{4, {x=-171, y=9, z=-63},{x=-170, y=9, z=-63},2},
{5, {x=-170, y=9, z=-67},{x=-169, y=9, z=-67},2},
{6, {x=-170, y=9, z=-65},{x=-169, y=9, z=-65},2},
{7, {x=-174, y=9, z=-72},{x=-173, y=9, z=-72},2},
{8, {x=-174, y=9, z=-60},{x=-173, y=9, z=-60},2},
{9, {x=-172, y=9, z=-70},{x=-171, y=9, z=-71},2},
{10, {x=-172, y=9, z=-62},{x=-171, y=9, z=-61},2},
{11, {x=-172, y=9, z=-71},{x=-171, y=9, z=-72},2},
{12, {x=-172, y=9, z=-61},{x=-171, y=9, z=-60},2},
{13, {x=-173, y=9, z=-72},{x=-172, y=9, z=-73},2},
{14, {x=-173, y=9, z=-60},{x=-172, y=9, z=-59},2},
{15, {x=-172, y=9, z=-73},{x=-171, y=9, z=-73},2},
{16, {x=-172, y=9, z=-59},{x=-171, y=9, z=-59},2},
{17, {x=-171, y=9, z=-72},{x=-170, y=9, z=-72},2},
{18, {x=-171, y=9, z=-60},{x=-170, y=9, z=-60},2},
{19, {x=-171, y=9, z=-71},{x=-170, y=9, z=-71},2},
{20, {x=-171, y=9, z=-61},{x=-170, y=9, z=-61},2},
{21, {x=-170, y=9, z=-70},{x=-169, y=9, z=-70},2},
{22, {x=-170, y=9, z=-62},{x=-169, y=9, z=-62},2},
{23, {x=-170, y=9, z=-69},{x=-169, y=9, z=-69},2},
{24, {x=-170, y=9, z=-63},{x=-169, y=9, z=-63},2},
{25, {x=-169, y=9, z=-68},{x=-168, y=9, z=-68},2},
{26, {x=-169, y=9, z=-64},{x=-168, y=9, z=-64},2},
{27, {x=-169, y=9, z=-67},{x=-168, y=9, z=-67},2},
{28, {x=-169, y=9, z=-65},{x=-168, y=9, z=-65},2},
{29, {x=-168, y=9, z=-66},{x=-167, y=9, z=-66},2},
{30, {x=-171, y=9, z=-73},{x=-170, y=9, z=-74},2},
{31, {x=-171, y=9, z=-59},{x=-170, y=9, z=-58},2},
{32, {x=-170, y=9, z=-72},{x=-169, y=9, z=-72},2},
{33, {x=-170, y=9, z=-60},{x=-169, y=9, z=-60},2},
{34, {x=-170, y=9, z=-71},{x=-169, y=9, z=-71},2},
{35, {x=-170, y=9, z=-61},{x=-169, y=9, z=-61},2},
{36, {x=-169, y=9, z=-70},{x=-168, y=9, z=-70},2},
{37, {x=-169, y=9, z=-62},{x=-168, y=9, z=-62},2},
{38, {x=-169, y=9, z=-69},{x=-168, y=9, z=-69},2},
{39, {x=-169, y=9, z=-63},{x=-168, y=9, z=-63},2},
{40, {x=-168, y=9, z=-68},{x=-167, y=9, z=-68},2},
{41, {x=-168, y=9, z=-64},{x=-167, y=9, z=-64},2},
{42, {x=-168, y=9, z=-67},{x=-167, y=9, z=-67},2},
{43, {x=-168, y=9, z=-65},{x=-167, y=9, z=-65},2},
{44, {x=-167, y=9, z=-66},{x=-166, y=9, z=-66},2},
{45, {x=-170, y=9, z=-74},{x=-169, y=9, z=-75},2},
{46, {x=-170, y=9, z=-58},{x=-169, y=9, z=-57},2},
{47, {x=-169, y=9, z=-72},{x=-168, y=9, z=-73},2},
{48, {x=-169, y=9, z=-60},{x=-168, y=9, z=-59},2},
{49, {x=-169, y=9, z=-71},{x=-168, y=9, z=-71},2},
{50, {x=-169, y=9, z=-61},{x=-168, y=9, z=-61},2},
{51, {x=-168, y=9, z=-70},{x=-167, y=9, z=-70},2},
{52, {x=-168, y=9, z=-62},{x=-167, y=9, z=-62},2},
{53, {x=-168, y=9, z=-69},{x=-167, y=9, z=-69},2},
{54, {x=-168, y=9, z=-63},{x=-167, y=9, z=-63},2},
{55, {x=-167, y=9, z=-68},{x=-166, y=9, z=-68},2},
{56, {x=-167, y=9, z=-64},{x=-166, y=9, z=-64},2},
{57, {x=-167, y=9, z=-67},{x=-166, y=9, z=-67},2},
{58, {x=-167, y=9, z=-65},{x=-166, y=9, z=-65},2},
{59, {x=-166, y=9, z=-66},{x=-165, y=9, z=-66},2},
{60, {x=-169, y=9, z=-75},{x=-168, y=9, z=-76},2},
{61, {x=-169, y=9, z=-57},{x=-168, y=9, z=-56},2},
{62, {x=-168, y=9, z=-73},{x=-167, y=9, z=-74},2},
{63, {x=-168, y=9, z=-59},{x=-167, y=9, z=-58},2},
{64, {x=-168, y=9, z=-71},{x=-167, y=9, z=-72},2},
{65, {x=-168, y=9, z=-61},{x=-167, y=9, z=-60},2},
{66, {x=-167, y=9, z=-70},{x=-166, y=9, z=-70},2},
{67, {x=-167, y=9, z=-62},{x=-166, y=9, z=-62},2},
{68, {x=-167, y=9, z=-69},{x=-166, y=9, z=-69},2},
{69, {x=-167, y=9, z=-63},{x=-166, y=9, z=-63},2},
{70, {x=-166, y=9, z=-68},{x=-165, y=9, z=-68},2},
{71, {x=-166, y=9, z=-64},{x=-165, y=9, z=-64},2},
{72, {x=-166, y=9, z=-67},{x=-165, y=9, z=-67},2},
{73, {x=-166, y=9, z=-65},{x=-165, y=9, z=-65},2},
{74, {x=-165, y=9, z=-66},{x=-164, y=9, z=-66},2},
{75, {x=-168, y=9, z=-76},{x=-167, y=9, z=-77},2},
{76, {x=-168, y=9, z=-56},{x=-167, y=9, z=-55},2},
{77, {x=-167, y=9, z=-74},{x=-166, y=9, z=-75},2},
{78, {x=-167, y=9, z=-58},{x=-166, y=9, z=-57},2},
{79, {x=-167, y=9, z=-72},{x=-166, y=9, z=-73},2},
{80, {x=-167, y=9, z=-60},{x=-166, y=9, z=-59},2},
{81, {x=-166, y=9, z=-70},{x=-165, y=9, z=-71},2},
{82, {x=-166, y=9, z=-62},{x=-165, y=9, z=-61},2},
{83, {x=-166, y=9, z=-69},{x=-165, y=9, z=-69},2},
{84, {x=-166, y=9, z=-63},{x=-165, y=9, z=-63},2},
{85, {x=-165, y=9, z=-68},{x=-164, y=9, z=-68},2},
{86, {x=-165, y=9, z=-64},{x=-164, y=9, z=-64},2},
{87, {x=-165, y=9, z=-67},{x=-164, y=9, z=-67},2},
{88, {x=-165, y=9, z=-65},{x=-164, y=9, z=-65},2},
{89, {x=-164, y=9, z=-66},{x=-163, y=9, z=-66},2},
{90, {x=-167, y=9, z=-77},{x=-166, y=9, z=-77},2},
{91, {x=-167, y=9, z=-55},{x=-166, y=9, z=-55},2},
{92, {x=-166, y=9, z=-75},{x=-165, y=9, z=-75},2},
{93, {x=-166, y=9, z=-57},{x=-165, y=9, z=-57},2},
{94, {x=-166, y=9, z=-73},{x=-165, y=9, z=-73},2},
{95, {x=-166, y=9, z=-59},{x=-165, y=9, z=-59},2},
{96, {x=-165, y=9, z=-71},{x=-164, y=9, z=-71},2},
{97, {x=-165, y=9, z=-61},{x=-164, y=9, z=-61},2},
{98, {x=-165, y=9, z=-69},{x=-164, y=9, z=-69},2},
{99, {x=-165, y=9, z=-63},{x=-164, y=9, z=-63},2},
{100, {x=-164, y=9, z=-68},{x=-163, y=9, z=-68},2},
{101, {x=-164, y=9, z=-64},{x=-163, y=9, z=-64},2},
{102, {x=-164, y=9, z=-67},{x=-163, y=9, z=-67},2},
{103, {x=-164, y=9, z=-65},{x=-163, y=9, z=-65},2},
{104, {x=-163, y=9, z=-66},{x=-162, y=9, z=-66},2},
{105, {x=-166, y=9, z=-77},{x=-165, y=9, z=-78},2},
{106, {x=-166, y=9, z=-55},{x=-165, y=9, z=-54},2},
{107, {x=-165, y=9, z=-75},{x=-164, y=9, z=-76},2},
{108, {x=-165, y=9, z=-57},{x=-164, y=9, z=-56},2},
{109, {x=-165, y=9, z=-73},{x=-164, y=9, z=-74},2},
{110, {x=-165, y=9, z=-59},{x=-164, y=9, z=-58},2},
{111, {x=-164, y=9, z=-71},{x=-163, y=9, z=-72},2},
{112, {x=-164, y=9, z=-61},{x=-163, y=9, z=-60},2},
{113, {x=-164, y=9, z=-69},{x=-163, y=9, z=-69},2},
{114, {x=-164, y=9, z=-63},{x=-163, y=9, z=-63},2},
{115, {x=-163, y=9, z=-68},{x=-162, y=9, z=-68},2},
{116, {x=-163, y=9, z=-64},{x=-162, y=9, z=-64},2},
{117, {x=-163, y=9, z=-67},{x=-162, y=9, z=-67},2},
{118, {x=-163, y=9, z=-65},{x=-162, y=9, z=-65},2},
{119, {x=-162, y=9, z=-66},{x=-161, y=9, z=-66},2},
{120, {x=-165, y=9, z=-78},{x=-164, y=9, z=-78},2},
{121, {x=-165, y=9, z=-54},{x=-164, y=9, z=-54},2},
{122, {x=-164, y=9, z=-76},{x=-163, y=9, z=-76},2},
{123, {x=-164, y=9, z=-56},{x=-163, y=9, z=-56},2},
{124, {x=-164, y=9, z=-74},{x=-163, y=9, z=-74},2},
{125, {x=-164, y=9, z=-58},{x=-163, y=9, z=-58},2},
{126, {x=-163, y=9, z=-72},{x=-162, y=9, z=-72},2},
{127, {x=-163, y=9, z=-60},{x=-162, y=9, z=-60},2},
{128, {x=-163, y=9, z=-69},{x=-162, y=9, z=-70},2},
{129, {x=-163, y=9, z=-63},{x=-162, y=9, z=-62},2},
{130, {x=-162, y=9, z=-68},{x=-161, y=9, z=-68},2},
{131, {x=-162, y=9, z=-64},{x=-161, y=9, z=-64},2},
{132, {x=-162, y=9, z=-67},{x=-161, y=9, z=-67},2},
{133, {x=-162, y=9, z=-65},{x=-161, y=9, z=-65},2},
{134, {x=-161, y=9, z=-66},{x=-160, y=9, z=-66},2},
{135, {x=-164, y=9, z=-78},{x=-163, y=9, z=-79},2},
{136, {x=-164, y=9, z=-54},{x=-163, y=9, z=-53},2},
{137, {x=-163, y=9, z=-76},{x=-162, y=9, z=-77},2},
{138, {x=-163, y=9, z=-56},{x=-162, y=9, z=-55},2},
{139, {x=-163, y=9, z=-74},{x=-162, y=9, z=-75},2},
{140, {x=-163, y=9, z=-58},{x=-162, y=9, z=-57},2},
{141, {x=-162, y=9, z=-72},{x=-161, y=9, z=-73},2},
{142, {x=-162, y=9, z=-60},{x=-161, y=9, z=-59},2},
{143, {x=-162, y=9, z=-70},{x=-161, y=9, z=-70},2},
{144, {x=-162, y=9, z=-62},{x=-161, y=9, z=-62},2},
{145, {x=-161, y=9, z=-68},{x=-160, y=9, z=-68},2},
{146, {x=-161, y=9, z=-64},{x=-160, y=9, z=-64},2},
{147, {x=-161, y=9, z=-67},{x=-160, y=9, z=-67},2},
{148, {x=-161, y=9, z=-65},{x=-160, y=9, z=-65},2},
{149, {x=-160, y=9, z=-66},{x=-159, y=9, z=-66},2},
{150, {x=-163, y=9, z=-79},{x=-162, y=9, z=-79},2},
{151, {x=-163, y=9, z=-53},{x=-162, y=9, z=-53},2},
{152, {x=-162, y=9, z=-77},{x=-161, y=9, z=-77},2},
{153, {x=-162, y=9, z=-55},{x=-161, y=9, z=-55},2},
{154, {x=-162, y=9, z=-75},{x=-161, y=9, z=-75},2},
{155, {x=-162, y=9, z=-57},{x=-161, y=9, z=-57},2},
{156, {x=-161, y=9, z=-73},{x=-160, y=9, z=-73},2},
{157, {x=-161, y=9, z=-59},{x=-160, y=9, z=-59},2},
{158, {x=-161, y=9, z=-70},{x=-160, y=9, z=-71},2},
{159, {x=-161, y=9, z=-62},{x=-160, y=9, z=-61},2},
{160, {x=-160, y=9, z=-68},{x=-159, y=9, z=-69},2},
{161, {x=-160, y=9, z=-64},{x=-159, y=9, z=-63},2},
{162, {x=-160, y=9, z=-67},{x=-159, y=9, z=-67},2},
{163, {x=-160, y=9, z=-65},{x=-159, y=9, z=-65},2},
{164, {x=-159, y=9, z=-66},{x=-158, y=9, z=-66},2},
{165, {x=-162, y=9, z=-79},{x=-161, y=9, z=-80},2},
{166, {x=-162, y=9, z=-53},{x=-161, y=9, z=-52},2},
{167, {x=-161, y=9, z=-77},{x=-160, y=9, z=-78},2},
{168, {x=-161, y=9, z=-55},{x=-160, y=9, z=-54},2},
{169, {x=-161, y=9, z=-75},{x=-160, y=9, z=-76},2},
{170, {x=-161, y=9, z=-57},{x=-160, y=9, z=-56},2},
{171, {x=-160, y=9, z=-73},{x=-159, y=9, z=-74},2},
{172, {x=-160, y=9, z=-59},{x=-159, y=9, z=-58},2},
{173, {x=-160, y=9, z=-71},{x=-159, y=9, z=-71},2},
{174, {x=-160, y=9, z=-61},{x=-159, y=9, z=-61},2},
{175, {x=-159, y=9, z=-69},{x=-158, y=9, z=-69},2},
{176, {x=-159, y=9, z=-63},{x=-158, y=9, z=-63},2},
{177, {x=-159, y=9, z=-67},{x=-158, y=9, z=-67},2},
{178, {x=-159, y=9, z=-65},{x=-158, y=9, z=-65},2},
{179, {x=-161, y=9, z=-80},{x=-160, y=9, z=-80},2},
{180, {x=-161, y=9, z=-52},{x=-160, y=9, z=-52},2},
{181, {x=-160, y=9, z=-78},{x=-159, y=9, z=-78},2},
{182, {x=-160, y=9, z=-54},{x=-159, y=9, z=-54},2},
{183, {x=-160, y=9, z=-76},{x=-159, y=9, z=-76},2},
{184, {x=-160, y=9, z=-56},{x=-159, y=9, z=-56},2},
{185, {x=-159, y=9, z=-74},{x=-158, y=9, z=-74},2},
{186, {x=-159, y=9, z=-58},{x=-158, y=9, z=-58},2},
{187, {x=-159, y=9, z=-71},{x=-158, y=9, z=-71},2},
{188, {x=-159, y=9, z=-61},{x=-158, y=9, z=-61},2},
{189, {x=-160, y=9, z=-80},{x=-159, y=9, z=-80},2},
{190, {x=-160, y=9, z=-52},{x=-159, y=9, z=-52},2},
{191, {x=-159, y=9, z=-78},{x=-158, y=9, z=-78},2},
{192, {x=-159, y=9, z=-54},{x=-158, y=9, z=-54},2},
{193, {x=-159, y=9, z=-76},{x=-158, y=9, z=-76},2},
{194, {x=-159, y=9, z=-56},{x=-158, y=9, z=-56},2},
{195, {x=-159, y=9, z=-80},{x=-158, y=9, z=-80},2},
{196, {x=-159, y=9, z=-52},{x=-158, y=9, z=-52},2},
{197, {x=-158, y=9, z=-80},{x=-157, y=9, z=-79},2},
{198, {x=-158, y=9, z=-52},{x=-157, y=9, z=-53},2},
{199, {x=-157, y=9, z=-79},{x=-156, y=9, z=-79},2},
{200, {x=-157, y=9, z=-53},{x=-156, y=9, z=-53},2},
{201, {x=-158, y=9, z=-78},{x=-157, y=9, z=-77},2},
{202, {x=-158, y=9, z=-54},{x=-157, y=9, z=-55},2},
{203, {x=-158, y=9, z=-76},{x=-157, y=9, z=-75},2},
{204, {x=-158, y=9, z=-56},{x=-157, y=9, z=-57},2},
{205, {x=-156, y=9, z=-79},{x=-155, y=9, z=-79},2},
{206, {x=-156, y=9, z=-53},{x=-155, y=9, z=-53},2},
{207, {x=-157, y=9, z=-77},{x=-156, y=9, z=-77},2},
{208, {x=-157, y=9, z=-55},{x=-156, y=9, z=-55},2},
{209, {x=-157, y=9, z=-75},{x=-156, y=9, z=-75},2},
{210, {x=-157, y=9, z=-57},{x=-156, y=9, z=-57},2},
{211, {x=-158, y=9, z=-74},{x=-157, y=9, z=-73},2},
{212, {x=-158, y=9, z=-58},{x=-157, y=9, z=-59},2},
{213, {x=-158, y=9, z=-71},{x=-157, y=9, z=-71},2},
{214, {x=-158, y=9, z=-61},{x=-157, y=9, z=-61},2},
{215, {x=-155, y=9, z=-79},{x=-154, y=9, z=-79},2},
{216, {x=-155, y=9, z=-53},{x=-154, y=9, z=-53},2},
{217, {x=-156, y=9, z=-77},{x=-155, y=9, z=-77},2},
{218, {x=-156, y=9, z=-55},{x=-155, y=9, z=-55},2},
{219, {x=-156, y=9, z=-75},{x=-155, y=9, z=-75},2},
{220, {x=-156, y=9, z=-57},{x=-155, y=9, z=-57},2},
{221, {x=-157, y=9, z=-73},{x=-156, y=9, z=-73},2},
{222, {x=-157, y=9, z=-59},{x=-156, y=9, z=-59},2},
{223, {x=-157, y=9, z=-71},{x=-156, y=9, z=-70},2},
{224, {x=-157, y=9, z=-61},{x=-156, y=9, z=-62},2},
{225, {x=-158, y=9, z=-69},{x=-157, y=9, z=-69},2},
{226, {x=-158, y=9, z=-63},{x=-157, y=9, z=-63},2},
{227, {x=-158, y=9, z=-67},{x=-157, y=9, z=-67},2},
{228, {x=-158, y=9, z=-65},{x=-157, y=9, z=-65},2},
{229, {x=-154, y=9, z=-79},{x=-153, y=9, z=-78},2},
{230, {x=-154, y=9, z=-53},{x=-153, y=9, z=-54},2},
{231, {x=-155, y=9, z=-77},{x=-154, y=9, z=-76},2},
{232, {x=-155, y=9, z=-55},{x=-154, y=9, z=-56},2},
{233, {x=-155, y=9, z=-75},{x=-154, y=9, z=-74},2},
{234, {x=-155, y=9, z=-57},{x=-154, y=9, z=-58},2},
{235, {x=-156, y=9, z=-73},{x=-155, y=9, z=-72},2},
{236, {x=-156, y=9, z=-59},{x=-155, y=9, z=-60},2},
{237, {x=-156, y=9, z=-70},{x=-155, y=9, z=-70},2},
{238, {x=-156, y=9, z=-62},{x=-155, y=9, z=-62},2},
{239, {x=-157, y=9, z=-69},{x=-156, y=9, z=-68},2},
{240, {x=-157, y=9, z=-63},{x=-156, y=9, z=-64},2},
{241, {x=-157, y=9, z=-67},{x=-156, y=9, z=-67},2},
{242, {x=-157, y=9, z=-65},{x=-156, y=9, z=-65},2},
{243, {x=-158, y=9, z=-66},{x=-157, y=9, z=-66},2},
{244, {x=-153, y=9, z=-78},{x=-152, y=9, z=-78},2},
{245, {x=-153, y=9, z=-54},{x=-152, y=9, z=-54},2},
{246, {x=-154, y=9, z=-76},{x=-153, y=9, z=-76},2},
{247, {x=-154, y=9, z=-56},{x=-153, y=9, z=-56},2},
{248, {x=-154, y=9, z=-74},{x=-153, y=9, z=-74},2},
{249, {x=-154, y=9, z=-58},{x=-153, y=9, z=-58},2},
{250, {x=-155, y=9, z=-72},{x=-154, y=9, z=-72},2},
{251, {x=-155, y=9, z=-60},{x=-154, y=9, z=-60},2},
{252, {x=-155, y=9, z=-70},{x=-154, y=9, z=-70},2},
{253, {x=-155, y=9, z=-62},{x=-154, y=9, z=-62},2},
{254, {x=-156, y=9, z=-68},{x=-155, y=9, z=-68},2},
{255, {x=-156, y=9, z=-64},{x=-155, y=9, z=-64},2},
{256, {x=-156, y=9, z=-67},{x=-155, y=9, z=-67},2},
{257, {x=-156, y=9, z=-65},{x=-155, y=9, z=-65},2},
{258, {x=-157, y=9, z=-66},{x=-156, y=9, z=-66},2},
{259, {x=-152, y=9, z=-78},{x=-151, y=9, z=-77},2},
{260, {x=-152, y=9, z=-54},{x=-151, y=9, z=-55},2},
{261, {x=-153, y=9, z=-76},{x=-152, y=9, z=-75},2},
{262, {x=-153, y=9, z=-56},{x=-152, y=9, z=-57},2},
{263, {x=-153, y=9, z=-74},{x=-152, y=9, z=-74},2},
{264, {x=-153, y=9, z=-58},{x=-152, y=9, z=-58},2},
{265, {x=-154, y=9, z=-72},{x=-153, y=9, z=-72},2},
{266, {x=-154, y=9, z=-60},{x=-153, y=9, z=-60},2},
{267, {x=-154, y=9, z=-70},{x=-153, y=9, z=-69},2},
{268, {x=-154, y=9, z=-62},{x=-153, y=9, z=-63},2},
{269, {x=-155, y=9, z=-68},{x=-154, y=9, z=-68},2},
{270, {x=-155, y=9, z=-64},{x=-154, y=9, z=-64},2},
{271, {x=-155, y=9, z=-67},{x=-154, y=9, z=-67},2},
{272, {x=-155, y=9, z=-65},{x=-154, y=9, z=-65},2},
{273, {x=-156, y=9, z=-66},{x=-155, y=9, z=-66},2},
{274, {x=-151, y=9, z=-77},{x=-150, y=9, z=-76},2},
{275, {x=-151, y=9, z=-55},{x=-150, y=9, z=-56},2},
{276, {x=-152, y=9, z=-75},{x=-151, y=9, z=-74},2},
{277, {x=-152, y=9, z=-57},{x=-151, y=9, z=-58},2},
{278, {x=-152, y=9, z=-74},{x=-151, y=9, z=-73},2},
{279, {x=-152, y=9, z=-58},{x=-151, y=9, z=-59},2},
{280, {x=-153, y=9, z=-72},{x=-152, y=9, z=-71},2},
{281, {x=-153, y=9, z=-60},{x=-152, y=9, z=-61},2},
{282, {x=-153, y=9, z=-69},{x=-152, y=9, z=-69},2},
{283, {x=-153, y=9, z=-63},{x=-152, y=9, z=-63},2},
{284, {x=-154, y=9, z=-68},{x=-153, y=9, z=-68},2},
{285, {x=-154, y=9, z=-64},{x=-153, y=9, z=-64},2},
{286, {x=-154, y=9, z=-67},{x=-153, y=9, z=-67},2},
{287, {x=-154, y=9, z=-65},{x=-153, y=9, z=-65},2},
{288, {x=-155, y=9, z=-66},{x=-154, y=9, z=-66},2},
{289, {x=-150, y=9, z=-76},{x=-149, y=9, z=-75},2},
{290, {x=-150, y=9, z=-56},{x=-149, y=9, z=-57},2},
{291, {x=-151, y=9, z=-74},{x=-150, y=9, z=-74},2},
{292, {x=-151, y=9, z=-58},{x=-150, y=9, z=-58},2},
{293, {x=-151, y=9, z=-73},{x=-150, y=9, z=-73},2},
{294, {x=-151, y=9, z=-59},{x=-150, y=9, z=-59},2},
{295, {x=-152, y=9, z=-71},{x=-151, y=9, z=-71},2},
{296, {x=-152, y=9, z=-61},{x=-151, y=9, z=-61},2},
{297, {x=-152, y=9, z=-69},{x=-151, y=9, z=-69},2},
{298, {x=-152, y=9, z=-63},{x=-151, y=9, z=-63},2},
{299, {x=-153, y=9, z=-68},{x=-152, y=9, z=-68},2},
{300, {x=-153, y=9, z=-64},{x=-152, y=9, z=-64},2},
{301, {x=-153, y=9, z=-67},{x=-152, y=9, z=-67},2},
{302, {x=-153, y=9, z=-65},{x=-152, y=9, z=-65},2},
{303, {x=-154, y=9, z=-66},{x=-153, y=9, z=-66},2},
{304, {x=-149, y=9, z=-75},{x=-148, y=9, z=-75},2},
{305, {x=-149, y=9, z=-57},{x=-148, y=9, z=-57},2},
{306, {x=-150, y=9, z=-74},{x=-149, y=9, z=-74},2},
{307, {x=-150, y=9, z=-58},{x=-149, y=9, z=-58},2},
{308, {x=-150, y=9, z=-73},{x=-149, y=9, z=-73},2},
{309, {x=-150, y=9, z=-59},{x=-149, y=9, z=-59},2},
{310, {x=-151, y=9, z=-71},{x=-150, y=9, z=-71},2},
{311, {x=-151, y=9, z=-61},{x=-150, y=9, z=-61},2},
{312, {x=-151, y=9, z=-69},{x=-150, y=9, z=-69},2},
{313, {x=-151, y=9, z=-63},{x=-150, y=9, z=-63},2},
{314, {x=-152, y=9, z=-68},{x=-151, y=9, z=-68},2},
{315, {x=-152, y=9, z=-64},{x=-151, y=9, z=-64},2},
{316, {x=-152, y=9, z=-67},{x=-151, y=9, z=-67},2},
{317, {x=-152, y=9, z=-65},{x=-151, y=9, z=-65},2},
{318, {x=-153, y=9, z=-66},{x=-152, y=9, z=-66},2},
{319, {x=-148, y=9, z=-75},{x=-147, y=9, z=-74},2},
{320, {x=-148, y=9, z=-57},{x=-147, y=9, z=-58},2},
{321, {x=-149, y=9, z=-74},{x=-148, y=9, z=-73},2},
{322, {x=-149, y=9, z=-58},{x=-148, y=9, z=-59},2},
{323, {x=-149, y=9, z=-73},{x=-148, y=9, z=-72},2},
{324, {x=-149, y=9, z=-59},{x=-148, y=9, z=-60},2},
{325, {x=-150, y=9, z=-71},{x=-149, y=9, z=-70},2},
{326, {x=-150, y=9, z=-61},{x=-149, y=9, z=-62},2},
{327, {x=-150, y=9, z=-69},{x=-149, y=9, z=-69},2},
{328, {x=-150, y=9, z=-63},{x=-149, y=9, z=-63},2},
{329, {x=-151, y=9, z=-68},{x=-150, y=9, z=-68},2},
{330, {x=-151, y=9, z=-64},{x=-150, y=9, z=-64},2},
{331, {x=-151, y=9, z=-67},{x=-150, y=9, z=-67},2},
{332, {x=-151, y=9, z=-65},{x=-150, y=9, z=-65},2},
{333, {x=-152, y=9, z=-66},{x=-151, y=9, z=-66},2},
{334, {x=-147, y=9, z=-74},{x=-146, y=9, z=-73},2},
{335, {x=-147, y=9, z=-58},{x=-146, y=9, z=-59},2},
{336, {x=-148, y=9, z=-73},{x=-147, y=9, z=-72},2},
{337, {x=-148, y=9, z=-59},{x=-147, y=9, z=-60},2},
{338, {x=-148, y=9, z=-72},{x=-147, y=9, z=-71},2},
{339, {x=-148, y=9, z=-60},{x=-147, y=9, z=-61},2},
{340, {x=-149, y=9, z=-70},{x=-148, y=9, z=-70},2},
{341, {x=-149, y=9, z=-62},{x=-148, y=9, z=-62},2},
{342, {x=-149, y=9, z=-69},{x=-148, y=9, z=-69},2},
{343, {x=-149, y=9, z=-63},{x=-148, y=9, z=-63},2},
{344, {x=-150, y=9, z=-68},{x=-149, y=9, z=-68},2},
{345, {x=-150, y=9, z=-64},{x=-149, y=9, z=-64},2},
{346, {x=-146, y=9, z=-73},{x=-145, y=9, z=-73},2},
{347, {x=-146, y=9, z=-59},{x=-145, y=9, z=-59},2},
{348, {x=-147, y=9, z=-72},{x=-146, y=9, z=-72},2},
{349, {x=-147, y=9, z=-60},{x=-146, y=9, z=-60},2},
{350, {x=-147, y=9, z=-71},{x=-146, y=9, z=-71},2},
{351, {x=-147, y=9, z=-61},{x=-146, y=9, z=-61},2},
{352, {x=-148, y=9, z=-70},{x=-147, y=9, z=-70},2},
{353, {x=-148, y=9, z=-62},{x=-147, y=9, z=-62},2},
{354, {x=-145, y=9, z=-73},{x=-144, y=9, z=-73},2},
{355, {x=-145, y=9, z=-59},{x=-144, y=9, z=-59},2},
{356, {x=-146, y=9, z=-72},{x=-145, y=9, z=-72},2},
{357, {x=-146, y=9, z=-60},{x=-145, y=9, z=-60},2},
{358, {x=-144, y=9, z=-73},{x=-144, y=9, z=-72},2},
{359, {x=-144, y=9, z=-59},{x=-144, y=9, z=-60},2},
{360, {x=-145, y=9, z=-72},{x=-145, y=9, z=-71},2},
{361, {x=-145, y=9, z=-60},{x=-145, y=9, z=-61},2},
{362, {x=-144, y=9, z=-72},{x=-144, y=9, z=-71},2},
{363, {x=-144, y=9, z=-60},{x=-144, y=9, z=-61},2},
{364, {x=-147, y=9, z=-70},{x=-146, y=9, z=-70},2},
{365, {x=-147, y=9, z=-62},{x=-146, y=9, z=-62},2},
{366, {x=-148, y=9, z=-69},{x=-147, y=9, z=-69},2},
{367, {x=-148, y=9, z=-63},{x=-147, y=9, z=-63},2},
{368, {x=-149, y=9, z=-68},{x=-148, y=9, z=-68},2},
{369, {x=-149, y=9, z=-64},{x=-148, y=9, z=-64},2},
{370, {x=-150, y=9, z=-67},{x=-149, y=9, z=-67},2},
{371, {x=-150, y=9, z=-65},{x=-149, y=9, z=-65},2},
{372, {x=-151, y=9, z=-66},{x=-150, y=9, z=-66},2},
{373, {x=-147, y=9, z=-69},{x=-146, y=9, z=-69},2},
{374, {x=-147, y=9, z=-63},{x=-146, y=9, z=-63},2},
{375, {x=-148, y=9, z=-68},{x=-147, y=9, z=-68},2},
{376, {x=-148, y=9, z=-64},{x=-147, y=9, z=-64},2},
{377, {x=-149, y=9, z=-67},{x=-148, y=9, z=-67},2},
{378, {x=-149, y=9, z=-65},{x=-148, y=9, z=-65},2},
{379, {x=-150, y=9, z=-66},{x=-149, y=9, z=-66},2},
{380, {x=-146, y=9, z=-71},{x=-145, y=9, z=-70},2},
{381, {x=-146, y=9, z=-61},{x=-145, y=9, z=-62},2},
{382, {x=-147, y=9, z=-68},{x=-146, y=9, z=-68},2},
{383, {x=-147, y=9, z=-64},{x=-146, y=9, z=-64},2},
{384, {x=-148, y=9, z=-67},{x=-147, y=9, z=-67},2},
{385, {x=-148, y=9, z=-65},{x=-147, y=9, z=-65},2},
{386, {x=-149, y=9, z=-66},{x=-148, y=9, z=-66},2},
{387, {x=-145, y=9, z=-71},{x=-144, y=9, z=-70},2},
{388, {x=-145, y=9, z=-61},{x=-144, y=9, z=-62},2},
{389, {x=-146, y=9, z=-70},{x=-145, y=9, z=-69},2},
{390, {x=-146, y=9, z=-62},{x=-145, y=9, z=-63},2},
{391, {x=-148, y=9, z=-66},{x=-147, y=9, z=-66},2},
{392, {x=-144, y=9, z=-70},{x=-144, y=9, z=-69},2},
{393, {x=-144, y=9, z=-62},{x=-144, y=9, z=-63},2},
{394, {x=-146, y=9, z=-68},{x=-146, y=9, z=-67},2},
{395, {x=-146, y=9, z=-64},{x=-146, y=9, z=-65},2},
{396, {x=-146, y=9, z=-69},{x=-146, y=9, z=-68},2},
{397, {x=-146, y=9, z=-63},{x=-146, y=9, z=-64},2},
{398, {x=-145, y=9, z=-69},{x=-145, y=9, z=-68},2},
{399, {x=-145, y=9, z=-63},{x=-145, y=9, z=-64},2},
{400, {x=-145, y=9, z=-70},{x=-145, y=9, z=-69},2},
{401, {x=-145, y=9, z=-62},{x=-145, y=9, z=-63},2},
{402, {x=-144, y=9, z=-69},{x=-144, y=9, z=-68},2},
{403, {x=-144, y=9, z=-63},{x=-144, y=9, z=-64},2},
{404, {x=-144, y=9, z=-71},{x=-144, y=9, z=-70},2},
{405, {x=-144, y=9, z=-61},{x=-144, y=9, z=-62},2},
{406, {x=-144, y=9, z=-70},{x=-144, y=9, z=-69},2},
{407, {x=-144, y=9, z=-62},{x=-144, y=9, z=-63},2},
{408, {x=-146, y=9, z=-67},{x=-145, y=9, z=-67},2},
{409, {x=-146, y=9, z=-65},{x=-145, y=9, z=-65},2},
{410, {x=-145, y=9, z=-68},{x=-145, y=9, z=-67},2},
{411, {x=-145, y=9, z=-64},{x=-145, y=9, z=-65},2},
{412, {x=-144, y=9, z=-68},{x=-144, y=9, z=-67},2},
{413, {x=-144, y=9, z=-64},{x=-144, y=9, z=-65},2},
{414, {x=-145, y=9, z=-69},{x=-145, y=9, z=-68},2},
{415, {x=-145, y=9, z=-63},{x=-145, y=9, z=-64},2},
{416, {x=-144, y=9, z=-69},{x=-144, y=9, z=-68},2},
{417, {x=-144, y=9, z=-63},{x=-144, y=9, z=-64},2},
{418, {x=-147, y=9, z=-67},{x=-146, y=9, z=-67},2},
{419, {x=-147, y=9, z=-65},{x=-146, y=9, z=-65},2},
{420, {x=-147, y=9, z=-66},{x=-146, y=9, z=-66},2},
{421, {x=-146, y=9, z=-68},{x=-145, y=9, z=-67},2},
{422, {x=-146, y=9, z=-64},{x=-145, y=9, z=-65},2},
{423, {x=-145, y=9, z=-68},{x=-145, y=9, z=-67},2},
{424, {x=-145, y=9, z=-64},{x=-145, y=9, z=-65},2},
{425, {x=-144, y=9, z=-68},{x=-144, y=9, z=-67},2},
{426, {x=-144, y=9, z=-64},{x=-144, y=9, z=-65},2},
{427, {x=-146, y=9, z=-67},{x=-145, y=9, z=-67},2},
{428, {x=-146, y=9, z=-65},{x=-145, y=9, z=-65},2},
{429, {x=-146, y=9, z=-66},{x=-145, y=9, z=-66},2},
}
function Chapter5()
return list
end

View File

@ -47,31 +47,54 @@ end
minetest.register_on_punchnode(function(pos, node, puncher, pointed_thing)
if minetest.get_node({x=pos.x, y=pos.y-1, z=pos.z}).name == "castrum:fight2" then
local dig = false
local dignum = math.random(4)
local dignum = math.random(8)
local com = 0
if node.name == "castrum:knight_dark" then
dig = true
elseif node.name == "castrum:knight_lv1_dark" then
local fightnode = puncher:get_attribute("fightnode")
if fightnode == "1" then
com = 3
com = 5
elseif fightnode == "2" then
com = 4
com = 7
elseif fightnode == "3" then
com = 8
elseif fightnode == "6" then
com = 3
com = 5
elseif fightnode == "7" then
com = 4
com = 7
elseif fightnode == "8" then
com = 8
end
elseif node.name == "castrum:knight_lv2_dark" then
local fightnode = puncher:get_attribute("fightnode")
if fightnode == "1" then
com = 3
elseif fightnode == "2" then
com = 5
elseif fightnode == "3" then
com = 7
elseif fightnode == "6" then
com = 2
elseif fightnode == "7" then
com = 5
elseif fightnode == "8" then
com = 7
end
elseif node.name == "castrum:knight_lv3_dark" then
local fightnode = puncher:get_attribute("fightnode")
if fightnode == "1" then
com = 2
elseif fightnode == "2" then
com = 3
elseif fightnode == "3" then
com = 5
elseif fightnode == "6" then
com = 2
elseif fightnode == "7" then
com = 3
elseif fightnode == "8" then
com = 5
end
end
if dignum < com then
@ -94,6 +117,12 @@ minetest.register_on_punchnode(function(pos, node, puncher, pointed_thing)
screwdriver_handler(puncher, {type="node", under=minetest.string_to_pos(fightpos), above=minetest.string_to_pos(fightpos)}, 1)
local inv = puncher:get_inventory()
inv:remove_item("main", "castrum:knight_lv2")
end
if fightnode == "3" then
minetest.set_node(minetest.string_to_pos(fightpos), {name="castrum:knight_lv3"})
screwdriver_handler(puncher, {type="node", under=minetest.string_to_pos(fightpos), above=minetest.string_to_pos(fightpos)}, 1)
local inv = puncher:get_inventory()
inv:remove_item("main", "castrum:knight_lv3")
end
if fightnode == "6" then
local pos = minetest.string_to_pos(fightpos)
@ -110,6 +139,14 @@ minetest.register_on_punchnode(function(pos, node, puncher, pointed_thing)
screwdriver_handler(puncher, {type="node", under={x=pos.x,y=pos.y+1,z=pos.z}, above={x=pos.x,y=pos.y+2,z=pos.z}}, 1)
local inv = puncher:get_inventory()
inv:remove_item("main", "castrum:horse1_item_2")
end
if fightnode == "8" then
local pos = minetest.string_to_pos(fightpos)
minetest.set_node({x=pos.x,y=pos.y,z=pos.z}, {name="castrum:horse1"})
minetest.set_node({x=pos.x,y=pos.y+1,z=pos.z}, {name="castrum:knight_lv3_sit"})
screwdriver_handler(puncher, {type="node", under={x=pos.x,y=pos.y+1,z=pos.z}, above={x=pos.x,y=pos.y+2,z=pos.z}}, 1)
local inv = puncher:get_inventory()
inv:remove_item("main", "castrum:horse1_item_3")
end
for j=144,174 do
for i=51,81 do
@ -124,12 +161,16 @@ end)
function get_fight(level,player)
player:set_attribute("fightkill1", "0")
player:set_attribute("fightkill2", "0")
player:set_attribute("fightkill3", "0")
player:set_attribute("fighthkill1", "0")
file = io.open(minetest.get_worldpath().."/SAVE/Knight_1.txt", "r")
local knight_1 = file:read("*l")
file:close()
file = io.open(minetest.get_worldpath().."/SAVE/Knight_2.txt", "r")
local knight_2 = file:read("*l")
file:close()
file = io.open(minetest.get_worldpath().."/SAVE/Knight_3.txt", "r")
local knight_3 = file:read("*l")
file:close()
local inv = player:get_inventory()
local num = 0
@ -138,7 +179,7 @@ function get_fight(level,player)
num = num+1
end
end
if tonumber(knight_1) > 0 or tonumber(knight_2) > 0 then
if tonumber(knight_1) > 0 or tonumber(knight_2) > 0 or tonumber(knight_3) > 0 then
if num > 9 then
for j=144,174 do
for i=51,81 do
@ -184,8 +225,8 @@ function get_fight(level,player)
file = io.open(minetest.get_worldpath().."/SAVE/Knight_2.txt", "r")
local knight_2 = file:read("*l")
file:close()
file = io.open(minetest.get_worldpath().."/SAVE/Knight_2.txt", "r")
local knight_2 = file:read("*l")
file = io.open(minetest.get_worldpath().."/SAVE/Knight_3.txt", "r")
local knight_3 = file:read("*l")
file:close()
file = io.open(minetest.get_worldpath().."/SAVE/Horse_1.txt", "r")
local horse_1 = file:read("*l")
@ -196,6 +237,9 @@ function get_fight(level,player)
if tonumber(knight_2) > 0 then
inv:add_item("main","castrum:knight_lv2 "..knight_2)
end
if tonumber(knight_3) > 0 then
inv:add_item("main","castrum:knight_lv3 "..knight_3)
end
if tonumber(horse_1) > 0 then
inv:add_item("main","castrum:horse1_item "..horse_1)
end
@ -321,6 +365,47 @@ function set_fight(player,level)
turn(player,{x=-174, y=9, z=-72},3)
minetest.set_node({x=-174, y=9, z=-60}, {name="castrum:knight_lv2_dark"})
turn(player,{x=-174, y=9, z=-60},3)
elseif level == 5 then
minetest.set_node({x=-173, y=9, z=-65}, {name="castrum:knight_lv3_dark"})
turn(player,{x=-173, y=9, z=-65},3)
minetest.set_node({x=-173, y=9, z=-67}, {name="castrum:knight_lv3_dark"})
turn(player,{x=-173, y=9, z=-67},3)
minetest.set_node({x=-174, y=9, z=-64}, {name="castrum:knight_lv3_dark"})
turn(player,{x=-174, y=9, z=-64},3)
minetest.set_node({x=-174, y=9, z=-68}, {name="castrum:knight_lv3_dark"})
turn(player,{x=-174, y=9, z=-68},3)
minetest.set_node({x=-172, y=9, z=-66}, {name="castrum:knight_lv3_dark"})
turn(player,{x=-172, y=9, z=-66},3)
minetest.set_node({x=-173, y=9, z=-62}, {name="castrum:knight_lv3_dark"})
turn(player,{x=-173, y=9, z=-62},3)
minetest.set_node({x=-173, y=9, z=-70}, {name="castrum:knight_lv3_dark"})
turn(player,{x=-173, y=9, z=-70},3)
minetest.set_node({x=-171, y=9, z=-69}, {name="castrum:knight_lv3_dark"})
turn(player,{x=-171, y=9, z=-69},3)
minetest.set_node({x=-171, y=9, z=-63}, {name="castrum:knight_lv3_dark"})
turn(player,{x=-171, y=9, z=-63},3)
minetest.set_node({x=-170, y=9, z=-65}, {name="castrum:knight_lv3_dark"})
turn(player,{x=-170, y=9, z=-65},3)
minetest.set_node({x=-170, y=9, z=-67}, {name="castrum:knight_lv3_dark"})
turn(player,{x=-170, y=9, z=-67},3)
minetest.set_node({x=-170, y=9, z=-70}, {name="castrum:knight_lv3_dark"})
turn(player,{x=-170, y=9, z=-70},3)
minetest.set_node({x=-169, y=9, z=-68}, {name="castrum:knight_lv3_dark"})
turn(player,{x=-169, y=9, z=-68},3)
minetest.set_node({x=-169, y=9, z=-64}, {name="castrum:knight_lv3_dark"})
turn(player,{x=-169, y=9, z=-64},3)
minetest.set_node({x=-168, y=9, z=-66}, {name="castrum:knight_lv3_dark"})
turn(player,{x=-168, y=9, z=-66},3)
minetest.set_node({x=-170, y=9, z=-62}, {name="castrum:knight_lv3_dark"})
turn(player,{x=-170, y=9, z=-62},3)
minetest.set_node({x=-172, y=9, z=-71}, {name="castrum:knight_lv3_dark"})
turn(player,{x=-172, y=9, z=-71},3)
minetest.set_node({x=-172, y=9, z=-61}, {name="castrum:knight_lv3_dark"})
turn(player,{x=-172, y=9, z=-61},3)
minetest.set_node({x=-174, y=9, z=-72}, {name="castrum:knight_lv3_dark"})
turn(player,{x=-174, y=9, z=-72},3)
minetest.set_node({x=-174, y=9, z=-60}, {name="castrum:knight_lv3_dark"})
turn(player,{x=-174, y=9, z=-60},3)
end
player:set_attribute("fightlv", ""..level)
end
@ -330,10 +415,10 @@ function fight_step1(player)
local start = false
for j=144,174 do
for i=51,81 do
if minetest.get_node({x=j*(-1), y=9, z=i*(-1)}).name == "castrum:knight_lv1" or minetest.get_node({x=j*(-1), y=9, z=i*(-1)}).name == "castrum:knight_lv2" then
if minetest.get_node({x=j*(-1), y=9, z=i*(-1)}).name == "castrum:knight_lv1" or minetest.get_node({x=j*(-1), y=9, z=i*(-1)}).name == "castrum:knight_lv2" or minetest.get_node({x=j*(-1), y=9, z=i*(-1)}).name == "castrum:knight_lv3" then
start = true
end
if minetest.get_node({x=j*(-1), y=10, z=i*(-1)}).name == "castrum:knight_lv1_sit" or minetest.get_node({x=j*(-1), y=10, z=i*(-1)}).name == "castrum:knight_lv2_sit" then
if minetest.get_node({x=j*(-1), y=10, z=i*(-1)}).name == "castrum:knight_lv1_sit" or minetest.get_node({x=j*(-1), y=10, z=i*(-1)}).name == "castrum:knight_lv2_sit" or minetest.get_node({x=j*(-1), y=10, z=i*(-1)}).name == "castrum:knight_lv3_sit" then
start = true
end
end
@ -347,6 +432,7 @@ function fight_step1(player)
local inv = player:get_inventory()
inv:remove_item("main", "castrum:knight_lv1 80")
inv:remove_item("main", "castrum:knight_lv2 80")
inv:remove_item("main", "castrum:knight_lv3 80")
inv:remove_item("main", "castrum:horse1_item 5")
for j=144,174 do
for i=51,81 do
@ -356,7 +442,136 @@ function fight_step1(player)
end
end
end
function fight_step3(player,num2,num,dignum,m,j,i)
if minetest.get_node({x=j*(-1), y=9, z=i*(-1)}).name == "castrum:knight_lv"..num2.."_dark" and dignum < m then
if minetest.get_node({x=j*(-1)+1, y=9, z=i*(-1)}).name == "castrum:knight_lv"..num or minetest.get_node({x=j*(-1)+1, y=10, z=i*(-1)}).name == "castrum:knight_lv"..num.."_sit" then
player:set_attribute("fightkill"..num, ""..(player:get_attribute("fightkill"..num)+1))
dd = 1
if minetest.get_node({x=j*(-1)+1, y=9, z=i*(-1)}).name == "castrum:horse1" then
player:set_attribute("fighthkill1", ""..(player:get_attribute("fighthkill1")+1))
end
minetest.set_node({x=j*(-1)+1, y=9, z=i*(-1)}, {name="air"})
minetest.set_node({x=j*(-1)+1, y=10, z=i*(-1)}, {name="air"})
end
if minetest.get_node({x=j*(-1)-1, y=9, z=i*(-1)}).name == "castrum:knight_lv"..num or minetest.get_node({x=j*(-1)-1, y=10, z=i*(-1)}).name == "castrum:knight_lv"..num.."_sit" then
player:set_attribute("fightkill"..num, ""..(player:get_attribute("fightkill"..num)+1))
dd = 1
if minetest.get_node({x=j*(-1)-1, y=9, z=i*(-1)}).name == "castrum:horse1" then
player:set_attribute("fighthkill1", ""..(player:get_attribute("fighthkill1")+1))
end
minetest.set_node({x=j*(-1)-1, y=9, z=i*(-1)}, {name="air"})
minetest.set_node({x=j*(-1)-1, y=10, z=i*(-1)}, {name="air"})
end
if minetest.get_node({x=j*(-1), y=9, z=i*(-1)}).name == "castrum:knight_lv"..num or minetest.get_node({x=j*(-1), y=10, z=i*(-1)}).name == "castrum:knight_lv"..num.."_sit" then
player:set_attribute("fightkill"..num, ""..(player:get_attribute("fightkill"..num)+1))
dd = 1
if minetest.get_node({x=j*(-1), y=9, z=i*(-1)}).name == "castrum:horse1" then
player:set_attribute("fighthkill1", ""..(player:get_attribute("fighthkill1")+1))
end
minetest.set_node({x=j*(-1), y=9, z=i*(-1)}, {name="air"})
minetest.set_node({x=j*(-1), y=10, z=i*(-1)}, {name="air"})
end
if minetest.get_node({x=j*(-1)+1, y=9, z=i*(-1)-1}).name == "castrum:knight_lv"..num or minetest.get_node({x=j*(-1)+1, y=10, z=i*(-1)-1}).name == "castrum:knight_lv"..num.."_sit" then
player:set_attribute("fightkill"..num, ""..(player:get_attribute("fightkill"..num)+1))
dd = 1
if minetest.get_node({x=j*(-1)+1, y=9, z=i*(-1)-1}).name == "castrum:horse1" then
player:set_attribute("fighthkill1", ""..(player:get_attribute("fighthkill1")+1))
end
minetest.set_node({x=j*(-1)+1, y=9, z=i*(-1)-1}, {name="air"})
minetest.set_node({x=j*(-1)+1, y=10, z=i*(-1)-1}, {name="air"})
end
if minetest.get_node({x=j*(-1)-1, y=9, z=i*(-1)-1}).name == "castrum:knight_lv"..num or minetest.get_node({x=j*(-1)-1, y=10, z=i*(-1)-1}).name == "castrum:knight_lv"..num.."_sit" then
player:set_attribute("fightkill"..num, ""..(player:get_attribute("fightkill"..num)+1))
dd = 1
if minetest.get_node({x=j*(-1)-1, y=9, z=i*(-1)-1}).name == "castrum:horse1" then
player:set_attribute("fighthkill1", ""..(player:get_attribute("fighthkill1")+1))
end
minetest.set_node({x=j*(-1)-1, y=9, z=i*(-1)-1}, {name="air"})
minetest.set_node({x=j*(-1)-1, y=10, z=i*(-1)-1}, {name="air"})
end
if minetest.get_node({x=j*(-1), y=9, z=i*(-1)-1}).name == "castrum:knight_lv"..num or minetest.get_node({x=j*(-1), y=10, z=i*(-1)-1}).name == "castrum:knight_lv"..num.."_sit" then
player:set_attribute("fightkill"..num, ""..(player:get_attribute("fightkill"..num)+1))
dd = 1
if minetest.get_node({x=j*(-1), y=9, z=i*(-1)-1}).name == "castrum:horse1" then
player:set_attribute("fighthkill1", ""..(player:get_attribute("fighthkill1")+1))
end
minetest.set_node({x=j*(-1), y=9, z=i*(-1)-1}, {name="air"})
minetest.set_node({x=j*(-1), y=10, z=i*(-1)-1}, {name="air"})
end
if minetest.get_node({x=j*(-1)-1, y=9, z=i*(-1)+1}).name == "castrum:knight_lv"..num or minetest.get_node({x=j*(-1)-1, y=10, z=i*(-1)+1}).name == "castrum:knight_lv"..num.."_sit" then
player:set_attribute("fightkill"..num, ""..(player:get_attribute("fightkill"..num)+1))
dd = 1
if minetest.get_node({x=j*(-1)-1, y=9, z=i*(-1)+1}).name == "castrum:horse1" then
player:set_attribute("fighthkill1", ""..(player:get_attribute("fighthkill1")+1))
end
minetest.set_node({x=j*(-1)-1, y=9, z=i*(-1)+1}, {name="air"})
minetest.set_node({x=j*(-1)-1, y=10, z=i*(-1)+1}, {name="air"})
end
if minetest.get_node({x=j*(-1)+1, y=9, z=i*(-1)+1}).name == "castrum:knight_lv"..num or minetest.get_node({x=j*(-1)+1, y=10, z=i*(-1)+1}).name == "castrum:knight_lv"..num.."_sit" then
player:set_attribute("fightkill"..num, ""..(player:get_attribute("fightkill"..num)+1))
dd = 1
if minetest.get_node({x=j*(-1)+1, y=9, z=i*(-1)+1}).name == "castrum:horse1" then
player:set_attribute("fighthkill1", ""..(player:get_attribute("fighthkill1")+1))
end
minetest.set_node({x=j*(-1)+1, y=9, z=i*(-1)+1}, {name="air"})
minetest.set_node({x=j*(-1)+1, y=10, z=i*(-1)+1}, {name="air"})
end
if minetest.get_node({x=j*(-1), y=9, z=i*(-1)+1}).name == "castrum:knight_lv"..num or minetest.get_node({x=j*(-1), y=10, z=i*(-1)+1}).name == "castrum:knight_lv"..num.."_sit" then
player:set_attribute("fightkill"..num, ""..(player:get_attribute("fightkill"..num)+1))
dd = 1
if minetest.get_node({x=j*(-1), y=9, z=i*(-1)+1}).name == "castrum:horse1" then
player:set_attribute("fighthkill1", ""..(player:get_attribute("fighthkill1")+1))
end
minetest.set_node({x=j*(-1), y=9, z=i*(-1)+1}, {name="air"})
minetest.set_node({x=j*(-1), y=10, z=i*(-1)+1}, {name="air"})
end
if minetest.get_node({x=j*(-1)+1, y=9, z=i*(-1)}).name == "castrum:castrum_knight"..num and dd == 0 then
minetest.set_node({x=j*(-1)+1, y=9, z=i*(-1)}, {name="air"})
player:set_attribute("fightkill"..num, ""..(player:get_attribute("fightkill"..num)+1))
dd = 1
end
if minetest.get_node({x=j*(-1)-1, y=9, z=i*(-1)}).name == "castrum:castrum_knight"..num and dd == 0 then
minetest.set_node({x=j*(-1)-1, y=9, z=i*(-1)}, {name="air"})
player:set_attribute("fightkill"..num, ""..(player:get_attribute("fightkill"..num)+1))
dd = 1
end
if minetest.get_node({x=j*(-1), y=9, z=i*(-1)}).name == "castrum:castrum_knight"..num and dd == 0 then
minetest.set_node({x=j*(-1), y=9, z=i*(-1)}, {name="air"})
player:set_attribute("fightkill"..num, ""..(player:get_attribute("fightkill"..num)+1))
dd = 1
end
if minetest.get_node({x=j*(-1)+1, y=9, z=i*(-1)-1}).name == "castrum:castrum_knight"..num and dd == 0 then
minetest.set_node({x=j*(-1)+1, y=9, z=i*(-1)-1}, {name="air"})
player:set_attribute("fightkill"..num, ""..(player:get_attribute("fightkill"..num)+1))
dd = 1
end
if minetest.get_node({x=j*(-1)-1, y=9, z=i*(-1)-1}).name == "castrum:castrum_knight"..num and dd == 0 then
minetest.set_node({x=j*(-1)-1, y=9, z=i*(-1)-1}, {name="air"})
player:set_attribute("fightkill"..num, ""..(player:get_attribute("fightkill"..num)+1))
dd = 1
end
if minetest.get_node({x=j*(-1), y=9, z=i*(-1)-1}).name == "castrum:castrum_knight"..num and dd == 0 then
minetest.set_node({x=j*(-1), y=9, z=i*(-1)-1}, {name="air"})
player:set_attribute("fightkill"..num, ""..(player:get_attribute("fightkill"..num)+1))
dd = 1
end
if minetest.get_node({x=j*(-1)+1, y=9, z=i*(-1)+1}).name == "castrum:castrum_knight"..num and dd == 0 then
minetest.set_node({x=j*(-1)+1, y=9, z=i*(-1)+1}, {name="air"})
player:set_attribute("fightkill"..num, ""..(player:get_attribute("fightkill"..num)+1))
dd = 1
end
if minetest.get_node({x=j*(-1)-1, y=9, z=i*(-1)+1}).name == "castrum:castrum_knight"..num and dd == 0 then
minetest.set_node({x=j*(-1)-1, y=9, z=i*(-1)+1}, {name="air"})
player:set_attribute("fightkill"..num, ""..(player:get_attribute("fightkill"..num)+1))
dd = 1
end
if minetest.get_node({x=j*(-1), y=9, z=i*(-1)+1}).name == "castrum:castrum_knight"..num and dd == 0 then
minetest.set_node({x=j*(-1), y=9, z=i*(-1)+1}, {name="air"})
player:set_attribute("fightkill"..num, ""..(player:get_attribute("fightkill"..num)+1))
dd = 1
end
end
end
function fight_step2(player)
local move = tonumber(player:get_attribute("fightmove"))
file = io.open(minetest.get_worldpath().."/SAVE/Chapter.txt", "r")
@ -371,6 +586,8 @@ function fight_step2(player)
list = Chapter3()
elseif tonumber(chapter) == 4 then
list = Chapter4()
elseif tonumber(chapter) == 5 then
list = Chapter5()
end
local move2 = move
local d = 0
@ -378,478 +595,20 @@ function fight_step2(player)
local dignum = 0
for j=144,174 do
for i=51,81 do
dignum = math.random(4)
if minetest.get_node({x=j*(-1), y=9, z=i*(-1)}).name == "castrum:knight_lv1_dark" and dignum < 3 then
if minetest.get_node({x=j*(-1)+1, y=9, z=i*(-1)}).name == "castrum:knight_lv1" or minetest.get_node({x=j*(-1)+1, y=10, z=i*(-1)}).name == "castrum:knight_lv1_sit" then
player:set_attribute("fightkill1", ""..(player:get_attribute("fightkill1")+1))
dd = 1
if minetest.get_node({x=j*(-1)+1, y=9, z=i*(-1)}).name == "castrum:horse1" then
player:set_attribute("fighthkill1", ""..(player:get_attribute("fighthkill1")+1))
end
minetest.set_node({x=j*(-1)+1, y=9, z=i*(-1)}, {name="air"})
minetest.set_node({x=j*(-1)+1, y=10, z=i*(-1)}, {name="air"})
end
if minetest.get_node({x=j*(-1)-1, y=9, z=i*(-1)}).name == "castrum:knight_lv1" or minetest.get_node({x=j*(-1)-1, y=10, z=i*(-1)}).name == "castrum:knight_lv1_sit" then
player:set_attribute("fightkill1", ""..(player:get_attribute("fightkill1")+1))
dd = 1
if minetest.get_node({x=j*(-1)-1, y=9, z=i*(-1)}).name == "castrum:horse1" then
player:set_attribute("fighthkill1", ""..(player:get_attribute("fighthkill1")+1))
end
minetest.set_node({x=j*(-1)-1, y=9, z=i*(-1)}, {name="air"})
minetest.set_node({x=j*(-1)-1, y=10, z=i*(-1)}, {name="air"})
end
if minetest.get_node({x=j*(-1), y=9, z=i*(-1)}).name == "castrum:knight_lv1" or minetest.get_node({x=j*(-1), y=10, z=i*(-1)}).name == "castrum:knight_lv1_sit" then
player:set_attribute("fightkill1", ""..(player:get_attribute("fightkill1")+1))
dd = 1
if minetest.get_node({x=j*(-1), y=9, z=i*(-1)}).name == "castrum:horse1" then
player:set_attribute("fighthkill1", ""..(player:get_attribute("fighthkill1")+1))
end
minetest.set_node({x=j*(-1), y=9, z=i*(-1)}, {name="air"})
minetest.set_node({x=j*(-1), y=10, z=i*(-1)}, {name="air"})
end
if minetest.get_node({x=j*(-1)+1, y=9, z=i*(-1)-1}).name == "castrum:knight_lv1" or minetest.get_node({x=j*(-1)+1, y=10, z=i*(-1)-1}).name == "castrum:knight_lv1_sit" then
player:set_attribute("fightkill1", ""..(player:get_attribute("fightkill1")+1))
dd = 1
if minetest.get_node({x=j*(-1)+1, y=9, z=i*(-1)-1}).name == "castrum:horse1" then
player:set_attribute("fighthkill1", ""..(player:get_attribute("fighthkill1")+1))
end
minetest.set_node({x=j*(-1)+1, y=9, z=i*(-1)-1}, {name="air"})
minetest.set_node({x=j*(-1)+1, y=10, z=i*(-1)-1}, {name="air"})
end
if minetest.get_node({x=j*(-1)-1, y=9, z=i*(-1)-1}).name == "castrum:knight_lv1" or minetest.get_node({x=j*(-1)-1, y=10, z=i*(-1)-1}).name == "castrum:knight_lv1_sit" then
player:set_attribute("fightkill1", ""..(player:get_attribute("fightkill1")+1))
dd = 1
if minetest.get_node({x=j*(-1)-1, y=9, z=i*(-1)-1}).name == "castrum:horse1" then
player:set_attribute("fighthkill1", ""..(player:get_attribute("fighthkill1")+1))
end
minetest.set_node({x=j*(-1)-1, y=9, z=i*(-1)-1}, {name="air"})
minetest.set_node({x=j*(-1)-1, y=10, z=i*(-1)-1}, {name="air"})
end
if minetest.get_node({x=j*(-1), y=9, z=i*(-1)-1}).name == "castrum:knight_lv1" or minetest.get_node({x=j*(-1), y=10, z=i*(-1)-1}).name == "castrum:knight_lv1_sit" then
player:set_attribute("fightkill1", ""..(player:get_attribute("fightkill1")+1))
dd = 1
if minetest.get_node({x=j*(-1), y=9, z=i*(-1)-1}).name == "castrum:horse1" then
player:set_attribute("fighthkill1", ""..(player:get_attribute("fighthkill1")+1))
end
minetest.set_node({x=j*(-1), y=9, z=i*(-1)-1}, {name="air"})
minetest.set_node({x=j*(-1), y=10, z=i*(-1)-1}, {name="air"})
end
if minetest.get_node({x=j*(-1)-1, y=9, z=i*(-1)+1}).name == "castrum:knight_lv1" or minetest.get_node({x=j*(-1)-1, y=10, z=i*(-1)+1}).name == "castrum:knight_lv1_sit" then
player:set_attribute("fightkill1", ""..(player:get_attribute("fightkill1")+1))
dd = 1
if minetest.get_node({x=j*(-1)-1, y=9, z=i*(-1)+1}).name == "castrum:horse1" then
player:set_attribute("fighthkill1", ""..(player:get_attribute("fighthkill1")+1))
end
minetest.set_node({x=j*(-1)-1, y=9, z=i*(-1)+1}, {name="air"})
minetest.set_node({x=j*(-1)-1, y=10, z=i*(-1)+1}, {name="air"})
end
if minetest.get_node({x=j*(-1)+1, y=9, z=i*(-1)+1}).name == "castrum:knight_lv1" or minetest.get_node({x=j*(-1)+1, y=10, z=i*(-1)+1}).name == "castrum:knight_lv1_sit" then
player:set_attribute("fightkill1", ""..(player:get_attribute("fightkill1")+1))
dd = 1
if minetest.get_node({x=j*(-1)+1, y=9, z=i*(-1)+1}).name == "castrum:horse1" then
player:set_attribute("fighthkill1", ""..(player:get_attribute("fighthkill1")+1))
end
minetest.set_node({x=j*(-1)+1, y=9, z=i*(-1)+1}, {name="air"})
minetest.set_node({x=j*(-1)+1, y=10, z=i*(-1)+1}, {name="air"})
end
if minetest.get_node({x=j*(-1), y=9, z=i*(-1)+1}).name == "castrum:knight_lv1" or minetest.get_node({x=j*(-1), y=10, z=i*(-1)+1}).name == "castrum:knight_lv1_sit" then
player:set_attribute("fightkill1", ""..(player:get_attribute("fightkill1")+1))
dd = 1
if minetest.get_node({x=j*(-1), y=9, z=i*(-1)+1}).name == "castrum:horse1" then
player:set_attribute("fighthkill1", ""..(player:get_attribute("fighthkill1")+1))
end
minetest.set_node({x=j*(-1), y=9, z=i*(-1)+1}, {name="air"})
minetest.set_node({x=j*(-1), y=10, z=i*(-1)+1}, {name="air"})
end
if minetest.get_node({x=j*(-1)+1, y=9, z=i*(-1)}).name == "castrum:castrum_knight1" and dd == 0 then
minetest.set_node({x=j*(-1)+1, y=9, z=i*(-1)}, {name="air"})
player:set_attribute("fightkill1", ""..(player:get_attribute("fightkill1")+1))
dd = 1
end
if minetest.get_node({x=j*(-1)-1, y=9, z=i*(-1)}).name == "castrum:castrum_knight1" and dd == 0 then
minetest.set_node({x=j*(-1)-1, y=9, z=i*(-1)}, {name="air"})
player:set_attribute("fightkill1", ""..(player:get_attribute("fightkill1")+1))
dd = 1
end
if minetest.get_node({x=j*(-1), y=9, z=i*(-1)}).name == "castrum:castrum_knight1" and dd == 0 then
minetest.set_node({x=j*(-1), y=9, z=i*(-1)}, {name="air"})
player:set_attribute("fightkill1", ""..(player:get_attribute("fightkill1")+1))
dd = 1
end
if minetest.get_node({x=j*(-1)+1, y=9, z=i*(-1)-1}).name == "castrum:castrum_knight1" and dd == 0 then
minetest.set_node({x=j*(-1)+1, y=9, z=i*(-1)-1}, {name="air"})
player:set_attribute("fightkill1", ""..(player:get_attribute("fightkill1")+1))
dd = 1
end
if minetest.get_node({x=j*(-1)-1, y=9, z=i*(-1)-1}).name == "castrum:castrum_knight1" and dd == 0 then
minetest.set_node({x=j*(-1)-1, y=9, z=i*(-1)-1}, {name="air"})
player:set_attribute("fightkill1", ""..(player:get_attribute("fightkill1")+1))
dd = 1
end
if minetest.get_node({x=j*(-1), y=9, z=i*(-1)-1}).name == "castrum:castrum_knight1" and dd == 0 then
minetest.set_node({x=j*(-1), y=9, z=i*(-1)-1}, {name="air"})
player:set_attribute("fightkill1", ""..(player:get_attribute("fightkill1")+1))
dd = 1
end
if minetest.get_node({x=j*(-1)+1, y=9, z=i*(-1)+1}).name == "castrum:castrum_knight1" and dd == 0 then
minetest.set_node({x=j*(-1)+1, y=9, z=i*(-1)+1}, {name="air"})
player:set_attribute("fightkill1", ""..(player:get_attribute("fightkill1")+1))
dd = 1
end
if minetest.get_node({x=j*(-1)-1, y=9, z=i*(-1)+1}).name == "castrum:castrum_knight1" and dd == 0 then
minetest.set_node({x=j*(-1)-1, y=9, z=i*(-1)+1}, {name="air"})
player:set_attribute("fightkill1", ""..(player:get_attribute("fightkill1")+1))
dd = 1
end
if minetest.get_node({x=j*(-1), y=9, z=i*(-1)+1}).name == "castrum:castrum_knight1" and dd == 0 then
minetest.set_node({x=j*(-1), y=9, z=i*(-1)+1}, {name="air"})
player:set_attribute("fightkill1", ""..(player:get_attribute("fightkill1")+1))
dd = 1
end
end
if minetest.get_node({x=j*(-1), y=9, z=i*(-1)}).name == "castrum:knight_lv1_dark" and dignum < 2 then
if minetest.get_node({x=j*(-1)+1, y=9, z=i*(-1)}).name == "castrum:knight_lv2" or minetest.get_node({x=j*(-1)+1, y=10, z=i*(-1)}).name == "castrum:knight_lv2_sit" then
player:set_attribute("fightkill2", ""..(player:get_attribute("fightkill2")+1))
dd = 1
if minetest.get_node({x=j*(-1)+1, y=9, z=i*(-1)}).name == "castrum:horse1" then
player:set_attribute("fighthkill1", ""..(player:get_attribute("fighthkill1")+1))
end
minetest.set_node({x=j*(-1)+1, y=9, z=i*(-1)}, {name="air"})
minetest.set_node({x=j*(-1)+1, y=10, z=i*(-1)}, {name="air"})
end
if minetest.get_node({x=j*(-1)-1, y=9, z=i*(-1)}).name == "castrum:knight_lv2" or minetest.get_node({x=j*(-1)-1, y=10, z=i*(-1)}).name == "castrum:knight_lv2_sit" then
player:set_attribute("fightkill2", ""..(player:get_attribute("fightkill2")+1))
dd = 1
if minetest.get_node({x=j*(-1)-1, y=9, z=i*(-1)}).name == "castrum:horse1" then
player:set_attribute("fighthkill1", ""..(player:get_attribute("fighthkill1")+1))
end
minetest.set_node({x=j*(-1)-1, y=9, z=i*(-1)}, {name="air"})
minetest.set_node({x=j*(-1)-1, y=10, z=i*(-1)}, {name="air"})
end
if minetest.get_node({x=j*(-1), y=9, z=i*(-1)}).name == "castrum:knight_lv2" or minetest.get_node({x=j*(-1), y=10, z=i*(-1)}).name == "castrum:knight_lv2_sit" then
player:set_attribute("fightkill2", ""..(player:get_attribute("fightkill2")+1))
dd = 1
if minetest.get_node({x=j*(-1), y=9, z=i*(-1)}).name == "castrum:horse1" then
player:set_attribute("fighthkill1", ""..(player:get_attribute("fighthkill1")+1))
end
minetest.set_node({x=j*(-1), y=9, z=i*(-1)}, {name="air"})
minetest.set_node({x=j*(-1), y=10, z=i*(-1)}, {name="air"})
end
if minetest.get_node({x=j*(-1)+1, y=9, z=i*(-1)-1}).name == "castrum:knight_lv2" or minetest.get_node({x=j*(-1)+1, y=10, z=i*(-1)-1}).name == "castrum:knight_lv2_sit" then
player:set_attribute("fightkill2", ""..(player:get_attribute("fightkill2")+1))
dd = 1
if minetest.get_node({x=j*(-1)+1, y=9, z=i*(-1)-1}).name == "castrum:horse1" then
player:set_attribute("fighthkill1", ""..(player:get_attribute("fighthkill1")+1))
end
minetest.set_node({x=j*(-1)+1, y=9, z=i*(-1)-1}, {name="air"})
minetest.set_node({x=j*(-1)+1, y=10, z=i*(-1)-1}, {name="air"})
end
if minetest.get_node({x=j*(-1)-1, y=9, z=i*(-1)-1}).name == "castrum:knight_lv2" or minetest.get_node({x=j*(-1)-1, y=10, z=i*(-1)-1}).name == "castrum:knight_lv2_sit" then
player:set_attribute("fightkill2", ""..(player:get_attribute("fightkill2")+1))
dd = 1
if minetest.get_node({x=j*(-1)-1, y=9, z=i*(-1)-1}).name == "castrum:horse1" then
player:set_attribute("fighthkill1", ""..(player:get_attribute("fighthkill1")+1))
end
minetest.set_node({x=j*(-1)-1, y=9, z=i*(-1)-1}, {name="air"})
minetest.set_node({x=j*(-1)-1, y=10, z=i*(-1)-1}, {name="air"})
end
if minetest.get_node({x=j*(-1), y=9, z=i*(-1)-1}).name == "castrum:knight_lv2" or minetest.get_node({x=j*(-1), y=10, z=i*(-1)-1}).name == "castrum:knight_lv2_sit" then
player:set_attribute("fightkill2", ""..(player:get_attribute("fightkill2")+1))
dd = 1
if minetest.get_node({x=j*(-1), y=9, z=i*(-1)-1}).name == "castrum:horse1" then
player:set_attribute("fighthkill1", ""..(player:get_attribute("fighthkill1")+1))
end
minetest.set_node({x=j*(-1), y=9, z=i*(-1)-1}, {name="air"})
minetest.set_node({x=j*(-1), y=10, z=i*(-1)-1}, {name="air"})
end
if minetest.get_node({x=j*(-1)-1, y=9, z=i*(-1)+1}).name == "castrum:knight_lv2" or minetest.get_node({x=j*(-1)-1, y=10, z=i*(-1)+1}).name == "castrum:knight_lv2_sit" then
player:set_attribute("fightkill2", ""..(player:get_attribute("fightkill2")+1))
dd = 1
if minetest.get_node({x=j*(-1)-1, y=9, z=i*(-1)+1}).name == "castrum:horse1" then
player:set_attribute("fighthkill1", ""..(player:get_attribute("fighthkill1")+1))
end
minetest.set_node({x=j*(-1)-1, y=9, z=i*(-1)+1}, {name="air"})
minetest.set_node({x=j*(-1)-1, y=10, z=i*(-1)+1}, {name="air"})
end
if minetest.get_node({x=j*(-1)+1, y=9, z=i*(-1)+1}).name == "castrum:knight_lv2" or minetest.get_node({x=j*(-1)+1, y=10, z=i*(-1)+1}).name == "castrum:knight_lv12_sit" then
player:set_attribute("fightkill2", ""..(player:get_attribute("fightkill2")+1))
dd = 1
if minetest.get_node({x=j*(-1)+1, y=9, z=i*(-1)+1}).name == "castrum:horse1" then
player:set_attribute("fighthkill1", ""..(player:get_attribute("fighthkill1")+1))
end
minetest.set_node({x=j*(-1)+1, y=9, z=i*(-1)+1}, {name="air"})
minetest.set_node({x=j*(-1)+1, y=10, z=i*(-1)+1}, {name="air"})
end
if minetest.get_node({x=j*(-1), y=9, z=i*(-1)+1}).name == "castrum:knight_lv2" or minetest.get_node({x=j*(-1), y=10, z=i*(-1)+1}).name == "castrum:knight_lv2_sit" then
player:set_attribute("fightkill2", ""..(player:get_attribute("fightkill2")+1))
dd = 1
if minetest.get_node({x=j*(-1), y=9, z=i*(-1)+1}).name == "castrum:horse1" then
player:set_attribute("fighthkill1", ""..(player:get_attribute("fighthkill1")+1))
end
minetest.set_node({x=j*(-1), y=9, z=i*(-1)+1}, {name="air"})
minetest.set_node({x=j*(-1), y=10, z=i*(-1)+1}, {name="air"})
end
if minetest.get_node({x=j*(-1)+1, y=9, z=i*(-1)}).name == "castrum:knight_lv2" and dd == 0 then
minetest.set_node({x=j*(-1)+1, y=9, z=i*(-1)}, {name="air"})
player:set_attribute("fightkill2", ""..(player:get_attribute("fightkill2")+1))
dd = 1
end
if minetest.get_node({x=j*(-1)-1, y=9, z=i*(-1)}).name == "castrum:knight_lv2" and dd == 0 then
minetest.set_node({x=j*(-1)-1, y=9, z=i*(-1)}, {name="air"})
player:set_attribute("fightkill2", ""..(player:get_attribute("fightkill2")+1))
dd = 1
end
if minetest.get_node({x=j*(-1), y=9, z=i*(-1)}).name == "castrum:knight_lv2" and dd == 0 then
minetest.set_node({x=j*(-1), y=9, z=i*(-1)}, {name="air"})
player:set_attribute("fightkill2", ""..(player:get_attribute("fightkill2")+1))
dd = 1
end
if minetest.get_node({x=j*(-1)+1, y=9, z=i*(-1)-1}).name == "castrum:knight_lv2" and dd == 0 then
minetest.set_node({x=j*(-1)+1, y=9, z=i*(-1)-1}, {name="air"})
player:set_attribute("fightkill2", ""..(player:get_attribute("fightkill2")+1))
dd = 1
end
if minetest.get_node({x=j*(-1)-1, y=9, z=i*(-1)-1}).name == "castrum:knight_lv2" and dd == 0 then
minetest.set_node({x=j*(-1)-1, y=9, z=i*(-1)-1}, {name="air"})
player:set_attribute("fightkill2", ""..(player:get_attribute("fightkill2")+1))
dd = 1
end
if minetest.get_node({x=j*(-1), y=9, z=i*(-1)-1}).name == "castrum:knight_lv2" and dd == 0 then
minetest.set_node({x=j*(-1), y=9, z=i*(-1)-1}, {name="air"})
player:set_attribute("fightkill2", ""..(player:get_attribute("fightkill2")+1))
dd = 1
end
if minetest.get_node({x=j*(-1)+1, y=9, z=i*(-1)+1}).name == "castrum:knight_lv2" and dd == 0 then
minetest.set_node({x=j*(-1)+1, y=9, z=i*(-1)+1}, {name="air"})
player:set_attribute("fightkill2", ""..(player:get_attribute("fightkill2")+1))
dd = 1
end
if minetest.get_node({x=j*(-1)-1, y=9, z=i*(-1)+1}).name == "castrum:knight_lv2" and dd == 0 then
minetest.set_node({x=j*(-1)-1, y=9, z=i*(-1)+1}, {name="air"})
player:set_attribute("fightkill2", ""..(player:get_attribute("fightkill2")+1))
dd = 1
end
if minetest.get_node({x=j*(-1), y=9, z=i*(-1)+1}).name == "castrum:knight_lv2" and dd == 0 then
minetest.set_node({x=j*(-1), y=9, z=i*(-1)+1}, {name="air"})
player:set_attribute("fightkill2", ""..(player:get_attribute("fightkill2")+1))
dd = 1
end
end
if minetest.get_node({x=j*(-1), y=9, z=i*(-1)}).name == "castrum:knight_lv2_dark" and dignum < 4 then
if minetest.get_node({x=j*(-1)+1, y=9, z=i*(-1)}).name == "castrum:knight_lv1" or minetest.get_node({x=j*(-1)+1, y=10, z=i*(-1)}).name == "castrum:knight_lv1_sit" then
player:set_attribute("fightkill1", ""..(player:get_attribute("fightkill1")+1))
dd = 1
if minetest.get_node({x=j*(-1)+1, y=9, z=i*(-1)}).name == "castrum:horse1" then
player:set_attribute("fighthkill1", ""..(player:get_attribute("fighthkill1")+1))
end
minetest.set_node({x=j*(-1)+1, y=9, z=i*(-1)}, {name="air"})
minetest.set_node({x=j*(-1)+1, y=10, z=i*(-1)}, {name="air"})
end
if minetest.get_node({x=j*(-1)-1, y=9, z=i*(-1)}).name == "castrum:knight_lv1" or minetest.get_node({x=j*(-1)-1, y=10, z=i*(-1)}).name == "castrum:knight_lv1_sit" then
player:set_attribute("fightkill1", ""..(player:get_attribute("fightkill1")+1))
dd = 1
if minetest.get_node({x=j*(-1)-1, y=9, z=i*(-1)}).name == "castrum:horse1" then
player:set_attribute("fighthkill1", ""..(player:get_attribute("fighthkill1")+1))
end
minetest.set_node({x=j*(-1)-1, y=9, z=i*(-1)}, {name="air"})
minetest.set_node({x=j*(-1)-1, y=10, z=i*(-1)}, {name="air"})
end
if minetest.get_node({x=j*(-1), y=9, z=i*(-1)}).name == "castrum:knight_lv1" or minetest.get_node({x=j*(-1), y=10, z=i*(-1)}).name == "castrum:knight_lv1_sit" then
player:set_attribute("fightkill1", ""..(player:get_attribute("fightkill1")+1))
dd = 1
if minetest.get_node({x=j*(-1), y=9, z=i*(-1)}).name == "castrum:horse1" then
player:set_attribute("fighthkill1", ""..(player:get_attribute("fighthkill1")+1))
end
minetest.set_node({x=j*(-1), y=9, z=i*(-1)}, {name="air"})
minetest.set_node({x=j*(-1), y=10, z=i*(-1)}, {name="air"})
end
if minetest.get_node({x=j*(-1)+1, y=9, z=i*(-1)-1}).name == "castrum:knight_lv1" or minetest.get_node({x=j*(-1)+1, y=10, z=i*(-1)-1}).name == "castrum:knight_lv1_sit" then
player:set_attribute("fightkill1", ""..(player:get_attribute("fightkill1")+1))
dd = 1
if minetest.get_node({x=j*(-1)+1, y=9, z=i*(-1)-1}).name == "castrum:horse1" then
player:set_attribute("fighthkill1", ""..(player:get_attribute("fighthkill1")+1))
end
minetest.set_node({x=j*(-1)+1, y=9, z=i*(-1)-1}, {name="air"})
minetest.set_node({x=j*(-1)+1, y=10, z=i*(-1)-1}, {name="air"})
end
if minetest.get_node({x=j*(-1)-1, y=9, z=i*(-1)-1}).name == "castrum:knight_lv1" or minetest.get_node({x=j*(-1)-1, y=10, z=i*(-1)-1}).name == "castrum:knight_lv1_sit" then
player:set_attribute("fightkill1", ""..(player:get_attribute("fightkill1")+1))
dd = 1
if minetest.get_node({x=j*(-1)-1, y=9, z=i*(-1)-1}).name == "castrum:horse1" then
player:set_attribute("fighthkill1", ""..(player:get_attribute("fighthkill1")+1))
end
minetest.set_node({x=j*(-1)-1, y=9, z=i*(-1)-1}, {name="air"})
minetest.set_node({x=j*(-1)-1, y=10, z=i*(-1)-1}, {name="air"})
end
if minetest.get_node({x=j*(-1), y=9, z=i*(-1)-1}).name == "castrum:knight_lv1" or minetest.get_node({x=j*(-1), y=10, z=i*(-1)-1}).name == "castrum:knight_lv1_sit" then
player:set_attribute("fightkill1", ""..(player:get_attribute("fightkill1")+1))
dd = 1
if minetest.get_node({x=j*(-1), y=9, z=i*(-1)-1}).name == "castrum:horse1" then
player:set_attribute("fighthkill1", ""..(player:get_attribute("fighthkill1")+1))
end
minetest.set_node({x=j*(-1), y=9, z=i*(-1)-1}, {name="air"})
minetest.set_node({x=j*(-1), y=10, z=i*(-1)-1}, {name="air"})
end
if minetest.get_node({x=j*(-1)-1, y=9, z=i*(-1)+1}).name == "castrum:knight_lv1" or minetest.get_node({x=j*(-1)-1, y=10, z=i*(-1)+1}).name == "castrum:knight_lv1_sit" then
player:set_attribute("fightkill1", ""..(player:get_attribute("fightkill1")+1))
dd = 1
if minetest.get_node({x=j*(-1)-1, y=9, z=i*(-1)+1}).name == "castrum:horse1" then
player:set_attribute("fighthkill1", ""..(player:get_attribute("fighthkill1")+1))
end
minetest.set_node({x=j*(-1)-1, y=9, z=i*(-1)+1}, {name="air"})
minetest.set_node({x=j*(-1)-1, y=10, z=i*(-1)+1}, {name="air"})
end
if minetest.get_node({x=j*(-1)+1, y=9, z=i*(-1)+1}).name == "castrum:knight_lv1" or minetest.get_node({x=j*(-1)+1, y=10, z=i*(-1)+1}).name == "castrum:knight_lv1_sit" then
player:set_attribute("fightkill1", ""..(player:get_attribute("fightkill1")+1))
dd = 1
if minetest.get_node({x=j*(-1)+1, y=9, z=i*(-1)+1}).name == "castrum:horse1" then
player:set_attribute("fighthkill1", ""..(player:get_attribute("fighthkill1")+1))
end
minetest.set_node({x=j*(-1)+1, y=9, z=i*(-1)+1}, {name="air"})
minetest.set_node({x=j*(-1)+1, y=10, z=i*(-1)+1}, {name="air"})
end
if minetest.get_node({x=j*(-1), y=9, z=i*(-1)+1}).name == "castrum:knight_lv1" or minetest.get_node({x=j*(-1), y=10, z=i*(-1)+1}).name == "castrum:knight_lv1_sit" then
player:set_attribute("fightkill1", ""..(player:get_attribute("fightkill1")+1))
dd = 1
if minetest.get_node({x=j*(-1), y=9, z=i*(-1)+1}).name == "castrum:horse1" then
player:set_attribute("fighthkill1", ""..(player:get_attribute("fighthkill1")+1))
end
minetest.set_node({x=j*(-1), y=9, z=i*(-1)+1}, {name="air"})
minetest.set_node({x=j*(-1), y=10, z=i*(-1)+1}, {name="air"})
end
if minetest.get_node({x=j*(-1)+1, y=9, z=i*(-1)}).name == "castrum:castrum_knight1" and dd == 0 then
minetest.set_node({x=j*(-1)+1, y=9, z=i*(-1)}, {name="air"})
player:set_attribute("fightkill1", ""..(player:get_attribute("fightkill1")+1))
dd = 1
end
if minetest.get_node({x=j*(-1)-1, y=9, z=i*(-1)}).name == "castrum:castrum_knight1" and dd == 0 then
minetest.set_node({x=j*(-1)-1, y=9, z=i*(-1)}, {name="air"})
player:set_attribute("fightkill1", ""..(player:get_attribute("fightkill1")+1))
dd = 1
end
if minetest.get_node({x=j*(-1), y=9, z=i*(-1)}).name == "castrum:castrum_knight1" and dd == 0 then
minetest.set_node({x=j*(-1), y=9, z=i*(-1)}, {name="air"})
player:set_attribute("fightkill1", ""..(player:get_attribute("fightkill1")+1))
dd = 1
end
if minetest.get_node({x=j*(-1)+1, y=9, z=i*(-1)-1}).name == "castrum:castrum_knight1" and dd == 0 then
minetest.set_node({x=j*(-1)+1, y=9, z=i*(-1)-1}, {name="air"})
player:set_attribute("fightkill1", ""..(player:get_attribute("fightkill1")+1))
dd = 1
end
if minetest.get_node({x=j*(-1)-1, y=9, z=i*(-1)-1}).name == "castrum:castrum_knight1" and dd == 0 then
minetest.set_node({x=j*(-1)-1, y=9, z=i*(-1)-1}, {name="air"})
player:set_attribute("fightkill1", ""..(player:get_attribute("fightkill1")+1))
dd = 1
end
if minetest.get_node({x=j*(-1), y=9, z=i*(-1)-1}).name == "castrum:castrum_knight1" and dd == 0 then
minetest.set_node({x=j*(-1), y=9, z=i*(-1)-1}, {name="air"})
player:set_attribute("fightkill1", ""..(player:get_attribute("fightkill1")+1))
dd = 1
end
if minetest.get_node({x=j*(-1)+1, y=9, z=i*(-1)+1}).name == "castrum:castrum_knight1" and dd == 0 then
minetest.set_node({x=j*(-1)+1, y=9, z=i*(-1)+1}, {name="air"})
player:set_attribute("fightkill1", ""..(player:get_attribute("fightkill1")+1))
dd = 1
end
if minetest.get_node({x=j*(-1)-1, y=9, z=i*(-1)+1}).name == "castrum:castrum_knight1" and dd == 0 then
minetest.set_node({x=j*(-1)-1, y=9, z=i*(-1)+1}, {name="air"})
player:set_attribute("fightkill1", ""..(player:get_attribute("fightkill1")+1))
dd = 1
end
if minetest.get_node({x=j*(-1), y=9, z=i*(-1)+1}).name == "castrum:castrum_knight1" and dd == 0 then
minetest.set_node({x=j*(-1), y=9, z=i*(-1)+1}, {name="air"})
player:set_attribute("fightkill1", ""..(player:get_attribute("fightkill1")+1))
dd = 1
end
end
if minetest.get_node({x=j*(-1), y=9, z=i*(-1)}).name == "castrum:knight_lv2_dark" and dignum < 3 then
if minetest.get_node({x=j*(-1)+1, y=9, z=i*(-1)}).name == "castrum:knight_lv2" or minetest.get_node({x=j*(-1)+1, y=10, z=i*(-1)}).name == "castrum:knight_lv2_sit" then
player:set_attribute("fightkill2", ""..(player:get_attribute("fightkill2")+1))
dd = 1
if minetest.get_node({x=j*(-1)+1, y=9, z=i*(-1)}).name == "castrum:horse1" then
player:set_attribute("fighthkill1", ""..(player:get_attribute("fighthkill1")+1))
end
minetest.set_node({x=j*(-1)+1, y=9, z=i*(-1)}, {name="air"})
minetest.set_node({x=j*(-1)+1, y=10, z=i*(-1)}, {name="air"})
end
if minetest.get_node({x=j*(-1)-1, y=9, z=i*(-1)}).name == "castrum:knight_lv2" or minetest.get_node({x=j*(-1)-1, y=10, z=i*(-1)}).name == "castrum:knight_lv2_sit" then
player:set_attribute("fightkill2", ""..(player:get_attribute("fightkill2")+1))
dd = 1
if minetest.get_node({x=j*(-1)-1, y=9, z=i*(-1)}).name == "castrum:horse1" then
player:set_attribute("fighthkill1", ""..(player:get_attribute("fighthkill1")+1))
end
minetest.set_node({x=j*(-1)-1, y=9, z=i*(-1)}, {name="air"})
minetest.set_node({x=j*(-1)-1, y=10, z=i*(-1)}, {name="air"})
end
if minetest.get_node({x=j*(-1), y=9, z=i*(-1)}).name == "castrum:knight_lv2" or minetest.get_node({x=j*(-1), y=10, z=i*(-1)}).name == "castrum:knight_lv2_sit" then
player:set_attribute("fightkill2", ""..(player:get_attribute("fightkill2")+1))
dd = 1
if minetest.get_node({x=j*(-1), y=9, z=i*(-1)}).name == "castrum:horse1" then
player:set_attribute("fighthkill1", ""..(player:get_attribute("fighthkill1")+1))
end
minetest.set_node({x=j*(-1), y=9, z=i*(-1)}, {name="air"})
minetest.set_node({x=j*(-1), y=10, z=i*(-1)}, {name="air"})
end
if minetest.get_node({x=j*(-1)+1, y=9, z=i*(-1)-1}).name == "castrum:knight_lv2" or minetest.get_node({x=j*(-1)+1, y=10, z=i*(-1)-1}).name == "castrum:knight_lv2_sit" then
player:set_attribute("fightkill2", ""..(player:get_attribute("fightkill2")+1))
dd = 1
if minetest.get_node({x=j*(-1)+1, y=9, z=i*(-1)-1}).name == "castrum:horse1" then
player:set_attribute("fighthkill1", ""..(player:get_attribute("fighthkill1")+1))
end
minetest.set_node({x=j*(-1)+1, y=9, z=i*(-1)-1}, {name="air"})
minetest.set_node({x=j*(-1)+1, y=10, z=i*(-1)-1}, {name="air"})
end
if minetest.get_node({x=j*(-1)-1, y=9, z=i*(-1)-1}).name == "castrum:knight_lv2" or minetest.get_node({x=j*(-1)-1, y=10, z=i*(-1)-1}).name == "castrum:knight_lv2_sit" then
player:set_attribute("fightkill2", ""..(player:get_attribute("fightkill2")+1))
dd = 1
if minetest.get_node({x=j*(-1)-1, y=9, z=i*(-1)-1}).name == "castrum:horse1" then
player:set_attribute("fighthkill1", ""..(player:get_attribute("fighthkill1")+1))
end
minetest.set_node({x=j*(-1)-1, y=9, z=i*(-1)-1}, {name="air"})
minetest.set_node({x=j*(-1)-1, y=10, z=i*(-1)-1}, {name="air"})
end
if minetest.get_node({x=j*(-1), y=9, z=i*(-1)-1}).name == "castrum:knight_lv2" or minetest.get_node({x=j*(-1), y=10, z=i*(-1)-1}).name == "castrum:knight_lv2_sit" then
player:set_attribute("fightkill2", ""..(player:get_attribute("fightkill2")+1))
dd = 1
if minetest.get_node({x=j*(-1), y=9, z=i*(-1)-1}).name == "castrum:horse1" then
player:set_attribute("fighthkill1", ""..(player:get_attribute("fighthkill1")+1))
end
minetest.set_node({x=j*(-1), y=9, z=i*(-1)-1}, {name="air"})
minetest.set_node({x=j*(-1), y=10, z=i*(-1)-1}, {name="air"})
end
if minetest.get_node({x=j*(-1)-1, y=9, z=i*(-1)+1}).name == "castrum:knight_lv2" or minetest.get_node({x=j*(-1)-1, y=10, z=i*(-1)+1}).name == "castrum:knight_lv2_sit" then
player:set_attribute("fightkill2", ""..(player:get_attribute("fightkill2")+1))
dd = 1
if minetest.get_node({x=j*(-1)-1, y=9, z=i*(-1)+1}).name == "castrum:horse1" then
player:set_attribute("fighthkill1", ""..(player:get_attribute("fighthkill1")+1))
end
minetest.set_node({x=j*(-1)-1, y=9, z=i*(-1)+1}, {name="air"})
minetest.set_node({x=j*(-1)-1, y=10, z=i*(-1)+1}, {name="air"})
end
if minetest.get_node({x=j*(-1)+1, y=9, z=i*(-1)+1}).name == "castrum:knight_lv2" or minetest.get_node({x=j*(-1)+1, y=10, z=i*(-1)+1}).name == "castrum:knight_lv12_sit" then
player:set_attribute("fightkill2", ""..(player:get_attribute("fightkill2")+1))
dd = 1
if minetest.get_node({x=j*(-1)+1, y=9, z=i*(-1)+1}).name == "castrum:horse1" then
player:set_attribute("fighthkill1", ""..(player:get_attribute("fighthkill1")+1))
end
minetest.set_node({x=j*(-1)+1, y=9, z=i*(-1)+1}, {name="air"})
minetest.set_node({x=j*(-1)+1, y=10, z=i*(-1)+1}, {name="air"})
end
if minetest.get_node({x=j*(-1), y=9, z=i*(-1)+1}).name == "castrum:knight_lv2" or minetest.get_node({x=j*(-1), y=10, z=i*(-1)+1}).name == "castrum:knight_lv2_sit" then
player:set_attribute("fightkill2", ""..(player:get_attribute("fightkill2")+1))
dd = 1
if minetest.get_node({x=j*(-1), y=9, z=i*(-1)+1}).name == "castrum:horse1" then
player:set_attribute("fighthkill1", ""..(player:get_attribute("fighthkill1")+1))
end
minetest.set_node({x=j*(-1), y=9, z=i*(-1)+1}, {name="air"})
minetest.set_node({x=j*(-1), y=10, z=i*(-1)+1}, {name="air"})
end
end
dignum = math.random(8)
fight_step3(player,1,1,dignum,5,j,i)
fight_step3(player,1,2,dignum,3,j,i)
fight_step3(player,1,3,dignum,2,j,i)
fight_step3(player,2,1,dignum,7,j,i)
fight_step3(player,2,2,dignum,5,j,i)
fight_step3(player,2,2,dignum,3,j,i)
fight_step3(player,3,1,dignum,8,j,i)
fight_step3(player,3,2,dignum,7,j,i)
fight_step3(player,3,3,dignum,5,j,i)
end
end
while d == 0 and move2 < 167 and dd == 0 and tonumber(chapter) == 1 do
if minetest.get_node(list[move2][2]).name == "castrum:knight_lv1_dark" then
if minetest.get_node(list[move2][2]).name == "castrum:knight_lv1_dark" and minetest.get_node(list[move2][3]).name == "air" then
minetest.set_node(list[move2][2], {name="air"})
minetest.set_node(list[move2][3], {name="castrum:knight_lv1_dark"})
player:set_attribute("fightmove", ""..(move2+1))
@ -862,7 +621,8 @@ function fight_step2(player)
end
end
while d == 0 and move2 < 300 and dd == 0 and tonumber(chapter) == 2 do
if minetest.get_node(list[move2][2]).name == "castrum:knight_lv1_dark" then
if minetest.get_node(list[move2][2]).name == "castrum:knight_lv1_dark" and minetest.get_node(list[move2][3]).name == "air" then
minetest.set_node(list[move2][2], {name="air"})
minetest.set_node(list[move2][3], {name="castrum:knight_lv1_dark"})
player:set_attribute("fightmove", ""..(move2+1))
@ -875,7 +635,7 @@ function fight_step2(player)
end
end
while d == 0 and move2 < 300 and dd == 0 and tonumber(chapter) == 3 do
if minetest.get_node(list[move2][2]).name == "castrum:knight_lv2_dark" then
if minetest.get_node(list[move2][2]).name == "castrum:knight_lv2_dark" and minetest.get_node(list[move2][3]).name == "air" then
minetest.set_node(list[move2][2], {name="air"})
minetest.set_node(list[move2][3], {name="castrum:knight_lv2_dark"})
player:set_attribute("fightmove", ""..(move2+1))
@ -888,7 +648,7 @@ function fight_step2(player)
end
end
while d == 0 and move2 < 430 and dd == 0 and tonumber(chapter) == 4 do
if minetest.get_node(list[move2][2]).name == "castrum:knight_lv2_dark" then
if minetest.get_node(list[move2][2]).name == "castrum:knight_lv2_dark" and minetest.get_node(list[move2][3]).name == "air" then
minetest.set_node(list[move2][2], {name="air"})
minetest.set_node(list[move2][3], {name="castrum:knight_lv2_dark"})
player:set_attribute("fightmove", ""..(move2+1))
@ -899,6 +659,19 @@ function fight_step2(player)
else
move2 = move2+1
end
end
while d == 0 and move2 < 430 and dd == 0 and tonumber(chapter) == 5 do
if minetest.get_node(list[move2][2]).name == "castrum:knight_lv3_dark" and minetest.get_node(list[move2][3]).name == "air" then
minetest.set_node(list[move2][2], {name="air"})
minetest.set_node(list[move2][3], {name="castrum:knight_lv3_dark"})
player:set_attribute("fightmove", ""..(move2+1))
screwdriver_handler(player, {type="node", under=list[move2][3], above=list[move2][3]}, 1)
screwdriver_handler(player, {type="node", under=list[move2][3], above=list[move2][3]}, 1)
screwdriver_handler(player, {type="node", under=list[move2][3], above=list[move2][3]}, 1)
d = 1
else
move2 = move2+1
end
end
local kg = 0
local ky = 0
@ -906,9 +679,9 @@ function fight_step2(player)
local ty = 0
for j=144,174 do
for i=51,81 do
if minetest.get_node({x=j*(-1), y=9, z=i*(-1)}).name == "castrum:knight_lv1_dark" or minetest.get_node({x=j*(-1), y=9, z=i*(-1)}).name == "castrum:knight_lv2_dark" then
if minetest.get_node({x=j*(-1), y=9, z=i*(-1)}).name == "castrum:knight_lv1_dark" or minetest.get_node({x=j*(-1), y=9, z=i*(-1)}).name == "castrum:knight_lv2_dark" or minetest.get_node({x=j*(-1), y=9, z=i*(-1)}).name == "castrum:knight_lv3_dark" then
tg = 1
elseif minetest.get_node({x=j*(-1), y=9, z=i*(-1)}).name == "castrum:knight_lv1" or minetest.get_node({x=j*(-1), y=9, z=i*(-1)}).name == "castrum:knight_lv2" or minetest.get_node({x=j*(-1), y=10, z=i*(-1)}).name == "castrum:knight_lv1_sit" or minetest.get_node({x=j*(-1), y=10, z=i*(-1)}).name == "castrum:knight_lv2_sit" then
elseif minetest.get_node({x=j*(-1), y=9, z=i*(-1)}).name == "castrum:knight_lv1" or minetest.get_node({x=j*(-1), y=9, z=i*(-1)}).name == "castrum:knight_lv2" or minetest.get_node({x=j*(-1), y=9, z=i*(-1)}).name == "castrum:knight_lv3" or minetest.get_node({x=j*(-1), y=10, z=i*(-1)}).name == "castrum:knight_lv1_sit" or minetest.get_node({x=j*(-1), y=10, z=i*(-1)}).name == "castrum:knight_lv2_sit" or minetest.get_node({x=j*(-1), y=10, z=i*(-1)}).name == "castrum:knight_lv3_sit" then
ty = 1
elseif minetest.get_node({x=j*(-1), y=9, z=i*(-1)}).name == "castrum:castrum_knight1" then
ky = 1
@ -923,8 +696,10 @@ function fight_step2(player)
local inv = player:get_inventory()
inv:remove_item("main", "castrum:knight_lv1 80")
inv:remove_item("main", "castrum:knight_lv2 80")
inv:remove_item("main", "castrum:knight_lv3 80")
inv:remove_item("main", "castrum:horse1_item_1 5")
inv:remove_item("main", "castrum:horse1_item_2 5")
inv:remove_item("main", "castrum:horse1_item_3 5")
file = io.open(minetest.get_worldpath().."/SAVE/Chapter.txt", "r")
local chapter = file:read("*l")
file:close()
@ -943,6 +718,12 @@ function fight_step2(player)
file = io.open(minetest.get_worldpath().."/SAVE/Knight_2.txt", "w")
file:write((tonumber(knight_2)-player:get_attribute("fightkill2")))
file:close()
file = io.open(minetest.get_worldpath().."/SAVE/Knight_3.txt", "r")
local knight_3 = file:read("*l")
file:close()
file = io.open(minetest.get_worldpath().."/SAVE/Knight_3.txt", "w")
file:write((tonumber(knight_3)-player:get_attribute("fightkill3")))
file:close()
file = io.open(minetest.get_worldpath().."/SAVE/Horse_1.txt", "r")
local horse_1 = file:read("*l")
file:close()
@ -971,6 +752,12 @@ function fight_step2(player)
file = io.open(minetest.get_worldpath().."/SAVE/Knight_2.txt", "w")
file:write((tonumber(knight_2)-player:get_attribute("fightkill2")))
file:close()
file = io.open(minetest.get_worldpath().."/SAVE/Knight_3.txt", "r")
local knight_3 = file:read("*l")
file:close()
file = io.open(minetest.get_worldpath().."/SAVE/Knight_3.txt", "w")
file:write((tonumber(knight_3)-player:get_attribute("fightkill3")))
file:close()
file = io.open(minetest.get_worldpath().."/SAVE/Horse_1.txt", "r")
local horse_1 = file:read("*l")
file:close()
@ -1038,6 +825,7 @@ minetest.register_on_player_receive_fields(function(player, formname, fields)
if v == "Yes" then
local k1 = player:get_attribute("fightkill1")
local k2 = player:get_attribute("fightkill2")
local k3 = player:get_attribute("fightkill3")
local h1 = player:get_attribute("fighthkill1")
for j=144,174 do
for i=51,81 do
@ -1047,6 +835,9 @@ minetest.register_on_player_receive_fields(function(player, formname, fields)
if minetest.get_node({x=j*(-1), y=9, z=i*(-1)}).name == "castrum:knight_lv2" or minetest.get_node({x=j*(-1), y=10, z=i*(-1)}).name == "castrum:knight_lv2_sit" then
k2 = k2+1
end
if minetest.get_node({x=j*(-1), y=9, z=i*(-1)}).name == "castrum:knight_lv3" or minetest.get_node({x=j*(-1), y=10, z=i*(-1)}).name == "castrum:knight_lv3_sit" then
k3 = k3+1
end
if minetest.get_node({x=j*(-1), y=9, z=i*(-1)}).name == "castrum:horse1" then
h1 = h1+1
end
@ -1064,6 +855,12 @@ minetest.register_on_player_receive_fields(function(player, formname, fields)
file = io.open(minetest.get_worldpath().."/SAVE/Knight_2.txt", "w")
file:write((tonumber(knight_2)-k2))
file:close()
file = io.open(minetest.get_worldpath().."/SAVE/Knight_3.txt", "r")
local knight_3 = file:read("*l")
file:close()
file = io.open(minetest.get_worldpath().."/SAVE/Knight_3.txt", "w")
file:write((tonumber(knight_3)-k3))
file:close()
file = io.open(minetest.get_worldpath().."/SAVE/Horse_1.txt", "r")
local horse_1 = file:read("*l")
file:close()
@ -1076,10 +873,11 @@ minetest.register_on_player_receive_fields(function(player, formname, fields)
local inv = player:get_inventory()
inv:remove_item("main", "castrum:knight_lv1 80")
inv:remove_item("main", "castrum:knight_lv2 80")
inv:remove_item("main", "castrum:knight_lv3 80")
inv:remove_item("main", "castrum:horse1_item 5")
inv:remove_item("main", "castrum:horse1_item_1 5")
inv:remove_item("main", "castrum:horse1_item_2 5")
inv:remove_item("main", "castrum:horse1_item_3 5")
minetest.show_formspec(player:get_player_name(), "", "")
elseif v == "No" then
minetest.show_formspec(player:get_player_name(), "", "")

File diff suppressed because it is too large Load Diff

Binary file not shown.

After

Width:  |  Height:  |  Size: 2.9 KiB