mirror of
https://github.com/godotengine/godot.git
synced 2024-11-21 03:18:37 +08:00
Remove some unused variables
This commit is contained in:
parent
8c0a050d49
commit
046f94d3ac
@ -431,7 +431,7 @@ public:
|
||||
RID lightaux = vs->light_create( VisualServer::LIGHT_DIRECTIONAL );
|
||||
//vs->light_set_color( lightaux, VisualServer::LIGHT_COLOR_AMBIENT, Color(0.0,0.0,0.0) );
|
||||
//vs->light_set_shadow( lightaux, true );
|
||||
RID light = vs->instance_create2( lightaux,scenario );
|
||||
vs->instance_create2( lightaux,scenario );
|
||||
|
||||
//rot_a=Transform(Matrix3(Vector3(1,0,0),Math_PI/2.0),Vector3());
|
||||
rot_b=Transform(Matrix3(),Vector3(2,0,0));
|
||||
|
@ -609,7 +609,7 @@ public:
|
||||
//t.basis.rotate(Vector3(-1,0,0),Math_PI/4*i);
|
||||
|
||||
|
||||
RID b = create_body(type,PhysicsServer::BODY_MODE_RIGID,t);
|
||||
create_body(type,PhysicsServer::BODY_MODE_RIGID,t);
|
||||
//RID b = create_body(type,i==0?PhysicsServer::BODY_MODE_STATIC:PhysicsServer::BODY_MODE_RIGID,t);
|
||||
|
||||
}
|
||||
|
@ -410,7 +410,7 @@ public:
|
||||
|
||||
Physics2DServer::ShapeType type = types[i%4];
|
||||
// type=Physics2DServer::SHAPE_SEGMENT;
|
||||
RID b = _add_body(type,Matrix32(i*0.8,Point2(152+i*40,100-40*i)));
|
||||
_add_body(type,Matrix32(i*0.8,Point2(152+i*40,100-40*i)));
|
||||
//if (i==0)
|
||||
// ps->body_set_mode(b,Physics2DServer::BODY_MODE_STATIC);
|
||||
}
|
||||
|
@ -849,21 +849,14 @@ MethodBind* ObjectTypeDB::bind_methodfi(uint32_t p_flags, MethodBind *p_bind , c
|
||||
|
||||
Vector<Variant> defvals;
|
||||
|
||||
#define PARSE_DEFVAL(m_defval)\
|
||||
if (d##m_defval.used) defvals.insert(0,d##m_defval.val);\
|
||||
else goto set_defvals;
|
||||
|
||||
defvals.resize(p_defcount);
|
||||
for(int i=0;i<p_defcount;i++) {
|
||||
|
||||
defvals[i]=*p_defs[p_defcount-i-1];
|
||||
}
|
||||
|
||||
set_defvals:
|
||||
|
||||
p_bind->set_default_arguments(defvals);
|
||||
p_bind->set_hint_flags(p_flags);
|
||||
#undef PARSE_DEFVAL
|
||||
return p_bind;
|
||||
|
||||
}
|
||||
|
@ -390,7 +390,7 @@ Error OS_Unix::execute(const String& p_path, const List<String>& p_arguments,boo
|
||||
if (p_blocking) {
|
||||
|
||||
int status;
|
||||
pid_t rpid = waitpid(pid,&status,0);
|
||||
waitpid(pid,&status,0);
|
||||
if (r_exitcode)
|
||||
*r_exitcode=WEXITSTATUS(status);
|
||||
} else {
|
||||
|
@ -2067,7 +2067,7 @@ Error GDScriptLanguage::complete_code(const String& p_code, const String& p_base
|
||||
|
||||
GDParser p;
|
||||
|
||||
Error err = p.parse(p_code,p_base_path,false,"",true);
|
||||
p.parse(p_code,p_base_path,false,"",true);
|
||||
bool isfunction=false;
|
||||
Set<String> options;
|
||||
|
||||
|
@ -660,7 +660,7 @@ void EditorExportPlatformAndroid::_fix_manifest(Vector<uint8_t>& p_manifest,bool
|
||||
uint32_t filesize = decode_uint32(&p_manifest[ofs+4]);
|
||||
ofs+=8;
|
||||
|
||||
// print_line("FILESIZE: "+itos(filesize)+" ACTUAL: "+itos(p_manifest.size()));
|
||||
//print_line("FILESIZE: "+itos(filesize)+" ACTUAL: "+itos(p_manifest.size()));
|
||||
|
||||
uint32_t string_count;
|
||||
uint32_t styles_count;
|
||||
@ -687,7 +687,7 @@ void EditorExportPlatformAndroid::_fix_manifest(Vector<uint8_t>& p_manifest,bool
|
||||
|
||||
string_count=decode_uint32(&p_manifest[iofs]);
|
||||
styles_count=decode_uint32(&p_manifest[iofs+4]);
|
||||
uint32_t string_flags=decode_uint32(&p_manifest[iofs+8]);
|
||||
string_flags=decode_uint32(&p_manifest[iofs+8]);
|
||||
string_data_offset=decode_uint32(&p_manifest[iofs+12]);
|
||||
styles_offset=decode_uint32(&p_manifest[iofs+16]);
|
||||
/*
|
||||
@ -1355,7 +1355,7 @@ Error EditorExportPlatformAndroid::export_project(const String& p_path, bool p_d
|
||||
args.push_back(unaligned_path);
|
||||
args.push_back(user);
|
||||
int retval;
|
||||
int err = OS::get_singleton()->execute(jarsigner,args,true,NULL,NULL,&retval);
|
||||
OS::get_singleton()->execute(jarsigner,args,true,NULL,NULL,&retval);
|
||||
if (retval) {
|
||||
EditorNode::add_io_error("'jarsigner' returned with error #"+itos(retval));
|
||||
return ERR_CANT_CREATE;
|
||||
@ -1368,7 +1368,7 @@ Error EditorExportPlatformAndroid::export_project(const String& p_path, bool p_d
|
||||
args.push_back(unaligned_path);
|
||||
args.push_back("-verbose");
|
||||
|
||||
err = OS::get_singleton()->execute(jarsigner,args,true,NULL,NULL,&retval);
|
||||
OS::get_singleton()->execute(jarsigner,args,true,NULL,NULL,&retval);
|
||||
if (retval) {
|
||||
EditorNode::add_io_error("'jarsigner' verification of APK failed. Make sure to use jarsigner from Java 6.");
|
||||
return ERR_CANT_CREATE;
|
||||
@ -1515,7 +1515,7 @@ void EditorExportPlatformAndroid::_device_poll_thread(void *ud) {
|
||||
List<String> args;
|
||||
args.push_back("devices");
|
||||
int ec;
|
||||
Error err = OS::get_singleton()->execute(adb,args,true,NULL,&devices,&ec);
|
||||
OS::get_singleton()->execute(adb,args,true,NULL,&devices,&ec);
|
||||
Vector<String> ds = devices.split("\n");
|
||||
Vector<String> ldevices;
|
||||
for(int i=1;i<ds.size();i++) {
|
||||
@ -1574,7 +1574,7 @@ void EditorExportPlatformAndroid::_device_poll_thread(void *ud) {
|
||||
int ec;
|
||||
String dp;
|
||||
|
||||
Error err = OS::get_singleton()->execute(adb,args,true,NULL,&dp,&ec);
|
||||
OS::get_singleton()->execute(adb,args,true,NULL,&dp,&ec);
|
||||
|
||||
Vector<String> props = dp.split("\n");
|
||||
String vendor;
|
||||
|
@ -445,7 +445,7 @@ Error EditorExportPlatformOSX::export_project(const String& p_path, bool p_debug
|
||||
{
|
||||
//write datapack
|
||||
|
||||
int err = zipOpenNewFileInZip(dpkg,
|
||||
zipOpenNewFileInZip(dpkg,
|
||||
(pkg_name+".app/Contents/Resources/data.pck").utf8().get_data(),
|
||||
NULL,
|
||||
NULL,
|
||||
|
@ -290,9 +290,6 @@ RID Rasterizer::_create_shader(const FixedMaterialShaderKey& p_key) {
|
||||
|
||||
//print_line("**VERTEX SHADER GENERATED code: \n"+vcode);
|
||||
|
||||
double tf = (OS::get_singleton()->get_ticks_usec()-t)/1000.0;
|
||||
// print_line("generate: "+rtos(tf));
|
||||
|
||||
shader_set_code(fms.shader,vcode,code,lcode,0,0);
|
||||
|
||||
fixed_material_shaders[p_key]=fms;
|
||||
|
Loading…
Reference in New Issue
Block a user