예제 #1
0
def ZoomCamera(scale, duration, repeat, tm = 0.0):
    if scale <= 0 or repeat == 0 or duration <= 0:
        return
    if repeat < 0:
        repeat = IFINIT_LOOP_NUM
    oldValue = [NBGM_SCRIPT_CONTEX.queryInfo('GetViewPointDistance')]
    newValue = [oldValue[0]*scale]
    action = [SetViewPointDistance]
    __start_animation__(oldValue, newValue, duration, repeat, tm, action)
예제 #2
0
def RotateCamera(delta_angle, duration, repeat, tm = 0.0):
    if repeat == 0 or duration <= 0:
        return
    if repeat < 0:
        repeat = IFINIT_LOOP_NUM
    oldValue = [NBGM_SCRIPT_CONTEX.queryInfo('GetRotateAngle')]
    newValue = [oldValue[0] + delta_angle]
    action = [SetRotateAngle]
    __start_animation__(oldValue, newValue, duration, repeat, tm, action)
예제 #3
0
def GetTiltAngle():
    return NBGM_SCRIPT_CONTEX.queryInfo('GetTiltAngle')
예제 #4
0
def SetBackground(background, tm = 0.0):
    NBGM_SCRIPT_CONTEX.addTask('SetBackground', [background], tm)
예제 #5
0
def SetAvatarMode(mode, tm = 0.0):
    NBGM_SCRIPT_CONTEX.addTask('SetAvatarMode', [mode], tm)
예제 #6
0
def SetAvatarScale(scaleValue, tm = 0.0):
    NBGM_SCRIPT_CONTEX.addTask('SetAvatarScale', [scaleValue], tm)
예제 #7
0
def SetViewSize(x, y, width, height, tm = 0.0):
    NBGM_SCRIPT_CONTEX.addTask('SetViewPointDistance', (x, y, width, height), tm)
예제 #8
0
def SetHorizonDistance(horizonDistance, tm = 0.0):
    NBGM_SCRIPT_CONTEX.addTask('SetHorizonDistance', [horizonDistance], tm)
예제 #9
0
def Tilt(angle, tm = 0.0):
    NBGM_SCRIPT_CONTEX.addTask('Tilt', [angle], tm)
예제 #10
0
def UnLoadTile(nbmName, autoerease = True, tm = 0.0):
    NBGM_SCRIPT_CONTEX.addTask('UnLoadTile', [nbmName], tm)
    if autoerease:
        NBGM_SCRIPT_CONTEX.loaded_tiles.remove(nbmName)
예제 #11
0
def WaitForSeconds(seconds):
    if seconds <= 0:
        return
    NBGM_SCRIPT_CONTEX.WaitForSeconds(seconds)
예제 #12
0
def LoadNBMTile(nbmName, baseDrawOrder, labelDrawOrder, filePath, tm = 0.0):
    NBGM_SCRIPT_CONTEX.addTask('LoadNBMTile', (nbmName, baseDrawOrder, labelDrawOrder, filePath), tm)
    NBGM_SCRIPT_CONTEX.loaded_tiles.add(nbmName)
예제 #13
0
def SetCurrentCommonMaterial(materialName, tm = 0.0):
    NBGM_SCRIPT_CONTEX.addTask('SetCurrentCommonMaterial', [materialName], tm)
예제 #14
0
def LoadCommonMaterial(materialName, filePath, tm = 0.0):
    NBGM_SCRIPT_CONTEX.addTask('LoadCommonMaterial', (materialName, filePath), tm)
예제 #15
0
def Move(dx, dy, tm = 0.0):
    NBGM_SCRIPT_CONTEX.addTask('Move', (dx, dy), tm)
예제 #16
0
def SetTiltAngle(angle, tm = 0.0):
    NBGM_SCRIPT_CONTEX.addTask('SetTiltAngle', [angle], tm)
    NBGM_SCRIPT_CONTEX.tilt_angle = float(angle)
예제 #17
0
def SetViewCenter(mercatorX, mercatorY, tm = 0.0):
    NBGM_SCRIPT_CONTEX.addTask('SetViewCenter', (mercatorX, mercatorY), tm)
예제 #18
0
def Rotate(angle, tm = 0.0):
    NBGM_SCRIPT_CONTEX.addTask('Rotate', [angle], tm)
예제 #19
0
def SetViewPointDistance(distance, tm = 0.0):
    NBGM_SCRIPT_CONTEX.addTask('SetViewPointDistance', [distance], tm)
    NBGM_SCRIPT_CONTEX.viewpoint_distance = float(distance)
예제 #20
0
def SetRotateAngle(angle, tm = 0.0):
    NBGM_SCRIPT_CONTEX.addTask('SetRotateAngle', [angle], tm)
    NBGM_SCRIPT_CONTEX.rotate_angle = float(angle)
예제 #21
0
def SetPerspective(fov, aspect, tm = 0.0):
    NBGM_SCRIPT_CONTEX.addTask('SetPerspective', (fov, aspect), tm)
예제 #22
0
def SetRotateCenter(screenX, screenY, tm = 0.0):
    NBGM_SCRIPT_CONTEX.addTask('SetRotateCenter', (screenX, screenY), tm)
예제 #23
0
def SetAvatarState(state, tm = 0.0):
    NBGM_SCRIPT_CONTEX.addTask('SetAvatarState', [state], tm)
예제 #24
0
def OnTouchEvent(screenX, screenY, tm = 0.0):
    NBGM_SCRIPT_CONTEX.addTask('OnTouchEvent', (screenX, screenY), tm)
예제 #25
0
def SelectAndTrackAvatar(x, y, tm = 0.0):
    NBGM_SCRIPT_CONTEX.addTask('SelectAndTrackAvatar', (x, y), tm)
예제 #26
0
def OnPaning(screenX, screenY, tm = 0.0):
    NBGM_SCRIPT_CONTEX.addTask('OnPaning', (screenX, screenY), tm)
예제 #27
0
def SetSkyDayNight(isDay, tm = 0.0):
    NBGM_SCRIPT_CONTEX.addTask('SetSkyDayNight', [isDay], tm)
예제 #28
0
def Zoom(deltaH, tm = 0.0):
    NBGM_SCRIPT_CONTEX.addTask('Zoom', [deltaH], tm)
예제 #29
0
def GetRotateAngle():
    return NBGM_SCRIPT_CONTEX.queryInfo('GetRotateAngle')
예제 #30
0
def RenderFrame(tm = 0.0):
    NBGM_SCRIPT_CONTEX.addTask('RenderFrame', [], tm)