31.03.2009, 01:26
|
#19
|
Зануда с интернетом
Регистрация: 04.09.2005
Сообщений: 14,014
Написано 6,798 полезных сообщений (для 20,935 пользователей)
|
Ответ: Проблемы LoadAnimMesh
EntityClass$( entity )
Parameters
entity - a valid entity handle
|
Description
Returns a string containing the class of the specified entity.
Possible return values are:
Pivot
Light
Camera
Mirror
Listener
Sprite
Terrain
Plane
Mesh
MD2
BSP
Note that the command will fail if a valid entity handle is not supplied, and will not just return an empty string.
|
Example
; EntityClass Example
; -------------------
Graphics3D 640,480,16
SetBuffer BackBuffer()
SeedRnd MilliSecs()
; Select a random number between 0 and 7 then create a certain class of entity depending on the number selected
i=Rand(0,7)
Select i
Case 0 ent=CreatePivot()
Case 1 ent=CreateLight()
Case 2 ent=CreateCamera()
Case 3 ent=CreateMirror()
Case 4 ent=CreateSprite()
Case 5 ent=CreateTerrain(32)
Case 6 ent=CreatePlane()
Case 7 ent=CreateMesh()
;Case 8 ent=CreateListener(parent)
;Case 9 ent=LoadMD2(md2_file$)
;Case 10 ent=LoadBSP(bsp_file$)
End Select
; Get the class of the entity
class$=EntityClass$(ent)
; Output the class to the screen
Text 0,0,"A "+class$+" was created."
Text 0,20,"Press a key."
WaitKey()
End
|
хелп 1.88
__________________
http://nabatchikov.com
Мир нужно делать лучше и чище. Иначе, зачем мы живем? tormoz
А я растила сына на преданьях
о принцах, троллях, потайных свиданьях,
погонях, похищениях невест.
Да кто же знал, что сказка душу съест?
|
(Offline)
|
|