Please login or register.

Login with username, password and session length
Advanced search  

News:

IRC channel - server: waelisch.de  channel: #wme (read more)

Author Topic: Exchange Actor at runtime  (Read 2545 times)

0 Members and 1 Guest are viewing this topic.

smushi

  • Lurker
  • *
  • Karma: 0
  • Offline Offline
  • Posts: 2
    • View Profile
Exchange Actor at runtime
« on: June 16, 2011, 04:42:00 PM »

Hi, we've been working on our game for a while now and are coming closer to our release date.

I just realized there's still one major problem in one of our prototype's scenes.

During the scene the actor puts on some clothes. We created the needed sprites, but right now I can not figure out how to exchange the actor -.-

Couldn't find help in Search and Documentation.

Can you help me :)?
Logged

Mnemonic

  • WME developer
  • Administrator
  • Addicted to WME forum
  • *
  • Karma: 41
  • Offline Offline
  • Gender: Male
  • Posts: 5683
    • View Profile
    • Dead:Code Site
Re: Exchange Actor at runtime
« Reply #1 on: June 16, 2011, 04:58:16 PM »

Simply unload the old one and load the new one.

Code: WME Script
  1. actor = Game.LoadActor("path\file.actor");
  2. Game.MainObject = actor;
  3.  
Logged
Yes, I do have a twitter account
Please don't send me technical questions in private messages, use the forum. ::wave

smushi

  • Lurker
  • *
  • Karma: 0
  • Offline Offline
  • Posts: 2
    • View Profile
Re: Exchange Actor at runtime
« Reply #2 on: June 16, 2011, 05:56:23 PM »

thank you so much!
Logged
 

Page created in 0.057 seconds with 25 queries.