本文整理汇总了C++中ContentFeatures::setAllTextureFlags方法的典型用法代码示例。如果您正苦于以下问题:C++ ContentFeatures::setAllTextureFlags方法的具体用法?C++ ContentFeatures::setAllTextureFlags怎么用?C++ ContentFeatures::setAllTextureFlags使用的例子?那么, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类ContentFeatures
的用法示例。
在下文中一共展示了ContentFeatures::setAllTextureFlags方法的1个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C++代码示例。
示例1: content_mapnode_plants
//.........这里部分代码省略.........
f->special_alternate_node = CONTENT_APPLE_LEAVES;
f->fuel_time = 20;
f->type = CMT_TREE;
f->hardness = 1.0;
f->suffocation_per_second = 0;
lists::add("creative",i);
i = CONTENT_YOUNG_CONIFER_TREE;
f = &content_features(i);
f->description = wgettext("Young Conifer Tree");
f->setAllTextures("conifer_tree.png");
f->setTexture(0, "conifer_tree_top.png");
f->setTexture(1, "conifer_tree_top.png");
f->draw_type = CDT_NODEBOX;
f->solidness = 0; // drawn separately, makes no faces
f->param_type = CPT_LIGHT;
f->light_propagates = true;
content_nodebox_youngtree(f);
f->setInventoryTextureNodeBox(i,"conifer_tree_top.png", "conifer_tree.png", "conifer_tree.png");
f->flammable = 1; // can be replaced by fire if the node under it is set on fire
f->dug_item = std::string("MaterialItem2 ")+itos(i)+" 1";
f->special_alternate_node = CONTENT_CONIFER_LEAVES;
f->fuel_time = 20;
f->type = CMT_TREE;
f->hardness = 1.0;
f->suffocation_per_second = 0;
lists::add("creative",i);
i = CONTENT_JUNGLEGRASS;
f = &content_features(i);
f->description = wgettext("Jungle Grass");
f->setInventoryTexture("junglegrass.png");
f->setAllTextures("junglegrass.png");
f->setAllTextureFlags(0);
f->light_propagates = true;
f->param_type = CPT_LIGHT;
f->draw_type = CDT_PLANTLIKE_LGE;
//f->is_ground_content = true;
f->air_equivalent = true;
f->dug_item = std::string("MaterialItem2 ")+itos(i)+" 1";
f->solidness = 0; // drawn separately, makes no faces
f->walkable = false;
f->flammable = 1; // can be replaced by fire if the node under it is set on fire
f->fuel_time = 30/32;
f->type = CMT_PLANT;
f->hardness = 0.20;
f->pressure_type = CST_CRUSHABLE;
f->suffocation_per_second = 0;
lists::add("creative",i);
i = CONTENT_LEAVES;
f = &content_features(i);
f->description = wgettext("Leaves");
f->light_propagates = true;
f->air_equivalent = true;
f->walkable = false;
f->climbable = true;
f->param_type = CPT_LIGHT;
//f->is_ground_content = true;
if (new_style_leaves) {
f->draw_type = CDT_LEAFLIKE;
f->solidness = 0; // drawn separately, makes no faces
f->setAllTextures("leaves.png");
#ifndef SERVER
f->setAllTextureTypes(MATERIAL_ALPHA_SIMPLE);
f->setAllTextureFlags(0);