Posted By: vasco
accessing model properties - 10/20/09 16:13
I have few models created in WED say m1, m2.
How can I access their properties like x,y,z co-ordinates ( world co-ords) from my WDL script ?
Posted By: MPQ
Re: accessing model properties - 10/20/09 16:30
you cannot move level blocks unless you export your model to a mdl file (File --> Export --> export mdl7) or you use your wmp-level as a map entity.
Posted By: vasco
Re: accessing model properties - 10/20/09 16:32
Thanks..
Yes, they are MDL files. How can i access them ?
Posted By: testDummy
Re: accessing model properties - 10/20/09 17:13
ENTITY* e1;
function fn() {
// assuming that "m1" is the ("WED-assigned") name of some ENTITY placed in WED
//...and ENTITY "m1" is present in the currently loaded level
e1 = ent_for_name("m1");
if (e1 != NULL) {
e1.x += 5;
e1.y -= 5;
}
}
see manual entry for term "ent_for_name"
Posted By: vasco
Re: accessing model properties - 10/22/09 07:00
how to detect the fall of a ball over the ground(block)??? can it be done using z- coordinate comparison ? can u give me a sample code ?
Posted By: delinkx
Re: accessing model properties - 10/22/09 08:34
u can check that through the collision event triggers or comparing z-coordinates.
if u using c-move, then u can check the event trigger. if u using physics, then use z-cordinates to check.