This forum is going to be locked at the end of this year and eventually going offline. If you have feedback to share you can find us in our Discord channel "MythoLogic Interactive" https://discord.gg/nECKnbT7gk

Make sure to read the rules.

Broken Map Script Thing

Did you encounter a problem, exploit, glitch or bug while playing the game or running the dedicated server software? Tell us about it here.
Forum rules
By using the forum you agree to the following rules. For this forum you also need to follow these additional rules.
Post Reply
User avatar
Proxmin-O
Fighter
Fighter
Posts: 21
Joined: Fri Jul 27, 2018 5:07 am
SFD Account: Proxmin
Started SFD: August 2016

Broken Map Script Thing

Post by Proxmin-O » Fri Jul 27, 2018 5:13 am

As the title says,when i open a map with script on it (some maps works) and open the Script API and then close it. this error occurs:Superfighters Deluxe has not responding,is there any way to fix it,i tried uninstall but never work.
thanks anyways.
0 x
"Spriting at it's finest"

User avatar
Gurt
Lead Programmer
Lead Programmer
Posts: 1885
Joined: Sun Feb 28, 2016 3:22 pm
Title: Lead programmer
Started SFD: Made it!
Location: Sweden
Gender:
Age: 35

Post by Gurt » Sun Jul 29, 2018 5:53 pm

If the bug is related to custom map-making then include a download link to the map illustrating the problem.
The map should be bare-bone - only include what's necessary in the map to illustrate the problem.

If the problem is not related to a specific map please provide some more details what you mean.
1 x
Gurt

User avatar
Proxmin-O
Fighter
Fighter
Posts: 21
Joined: Fri Jul 27, 2018 5:07 am
SFD Account: Proxmin
Started SFD: August 2016

Post by Proxmin-O » Wed Aug 08, 2018 6:23 am

btw i know whats the problem,The problem is this script:
Public void cot1(TriggerArgs args)
{
IPlayer immabutcher = (IPlayer)args.Sender;
immaButcher.SetProfile(((IObjectPlayerProfileInfo)Game.GetSingleObjectByCustomId(“cot1”)).GetProfile());
}
im sure that all maps containing this script is a problem.
btw its a custom map(or versus maps if available)
tried copy through microsoft word and paste it to script tab but problem occurs.
thanks anyways.

btw its a profile change script (when press or trigger the script,it changes your profile body)

and btw when i use this alternative script:
public void pro13(TriggerArgs args){
IPlayer ply = (IPlayer)args.Sender;
ply.SetProfile(((IObjectPlayerProfileInfo)Game.GetSingleObjectByCustomId("pro13")).GetProfile());
}
i dont have problem with this one
Last edited by KliPeH on Wed Aug 08, 2018 2:42 pm, edited 1 time in total.
Reason: Merged a triple-post.
0 x
"Spriting at it's finest"

User avatar
Gurt
Lead Programmer
Lead Programmer
Posts: 1885
Joined: Sun Feb 28, 2016 3:22 pm
Title: Lead programmer
Started SFD: Made it!
Location: Sweden
Gender:
Age: 35

Post by Gurt » Wed Aug 08, 2018 3:14 pm

The first code contains syntax errors. Ask the author of the code to fix said problems. I would have written it something like this:

Code: Select all

public void cot1(TriggerArgs args) 
{
   if (args.Sender is IPlayer) {
      IPlayer plr = (IPlayer)args.Sender;
      IObjectPlayerProfileInfo objProfileInfo = Game.GetSingleObjectByCustomID<IObjectPlayerProfileInfo>("cot1");
      if (objProfileInfo != null) {
         plr.SetProfile(objProfileInfo.GetProfile());
      }
   }
}
0 x
Gurt

User avatar
Sree
Superfighter
Superfighter
Posts: 325
Joined: Sun May 08, 2016 8:19 pm
SFD Account: phasmic
SFD Alias: sree
Gender:
Age: 25

Post by Sree » Wed Aug 08, 2018 4:03 pm

C# is case sensitive.

if you are wondering what the errors are in your script
Proxmin-O wrote:
Wed Aug 08, 2018 6:23 am
Public void cot1(TriggerArgs args)
Proxmin-O wrote:
Wed Aug 08, 2018 6:23 am
IPlayer immabutcher = (IPlayer)args.Sender;
immaButcher.SetProfile(((IObjectPlayerProfileInfo)Game.GetSingleObjectByCustomId(“cot1”)).GetProfile());
Proxmin-O wrote:
Wed Aug 08, 2018 6:23 am
immaButcher.SetProfile(((IObjectPlayerProfileInfo)Game.GetSingleObjectByCustomId(“cot1”)).GetProfile());
0 x

User avatar
Proxmin-O
Fighter
Fighter
Posts: 21
Joined: Fri Jul 27, 2018 5:07 am
SFD Account: Proxmin
Started SFD: August 2016

Post by Proxmin-O » Thu Aug 09, 2018 11:59 am

Thanks for all your comments
0 x
"Spriting at it's finest"

Post Reply