Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Help Modifying plugin
#1
How I can modify this plugin to work in teknomw3

Code:
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using InfinityScript;
using System.IO;

namespace ManualMapEdit
{
    public class ManualMapEdit : BaseScript
    {
        bool creating = false;
        float startx;
        float starty;
        float startz;
        float endx;
        float endy;
        float endz;

        public ManualMapEdit()
            : base()
        {
            PlayerConnected += new Action<Entity>(player =>
            {
                player.Call("notifyonplayercommand", "fly", "+frag");
                player.OnNotify("fly", (ent) =>
                {
                    if (player.GetField<string>("sessionstate") != "spectator")
                    {
                        player.Call("allowspectateteam", "freelook", true);
                        player.SetField("sessionstate", "spectator");
                        player.Call("setcontents", 0);
                    }
                    else
                    {
                        player.Call("allowspectateteam", "freelook", false);
                        player.SetField("sessionstate", "playing");
                        player.Call("setcontents", 100);
                    }
                });
            });
        }
        public override void OnSay(Entity player, string playerName, string text)
        {
            var mapname = Call<string>("getdvar", "mapname");

            string[] msg = text.Split(' ');


            if (msg[0] == "!restart")
            {
                Call("setdvar", "map_restart", "1");
            }

            if (msg[0] == "!wall" && !creating)
            {
                player.Call("iprintlnbold", "^2START SET: " + player.Origin);
                startx = player.Origin.X;
                starty = player.Origin.Y;
                startz = player.Origin.Z;
                creating = true;
            }
            else if (msg[0] == "!wall" && creating)
            {
                player.Call("iprintlnbold", "^2END SET: "+player.Origin);
                endx = player.Origin.X;
                endy = player.Origin.Y;
                endz = player.Origin.Z;
                creating = false;
                File.AppendAllText("scripts\\maps\\" + mapname + ".txt", Environment.NewLine + "wall: (" + startx + "," + starty + "," + startz + ") ; (" + endx + "," + endy + "," + endz + ")");
            }

            if (msg[0] == "!ramp" && !creating)
            {
                player.Call("iprintlnbold", "^2START SET: " + player.Origin);
                startx = player.Origin.X;
                starty = player.Origin.Y;
                startz = player.Origin.Z;
                creating = true;
            }
            else if (msg[0] == "!ramp" && creating)
            {
                player.Call("iprintlnbold", "^2END SET: " + player.Origin);
                endx = player.Origin.X;
                endy = player.Origin.Y;
                endz = player.Origin.Z;
                creating = false;
                File.AppendAllText("scripts\\maps\\" + mapname + ".txt", Environment.NewLine + "ramp: (" + startx + "," + starty + "," + startz + ") ; (" + endx + "," + endy + "," + endz + ")");
            }

            if (msg[0] == "!tp" && !creating)
            {
                player.Call("iprintlnbold", "^2START SET: " + player.Origin);
                startx = player.Origin.X;
                starty = player.Origin.Y;
                startz = player.Origin.Z;
                creating = true;
            }
            else if (msg[0] == "!tp" && creating)
            {
                player.Call("iprintlnbold", "^2END SET: " + player.Origin);
                endx = player.Origin.X;
                endy = player.Origin.Y;
                endz = player.Origin.Z;
                creating = false;
                File.AppendAllText("scripts\\maps\\" + mapname + ".txt", Environment.NewLine + "elevator: (" + startx + "," + starty + "," + startz + ") ; (" + endx + "," + endy + "," + endz + ")");
            }

            if (msg[0] == "!htp" && !creating)
            {
                player.Call("iprintlnbold", "^2START SET: " + player.Origin);
                startx = player.Origin.X;
                starty = player.Origin.Y;
                startz = player.Origin.Z;
                creating = true;
            }
            else if (msg[0] == "!htp" && creating)
            {
                player.Call("iprintlnbold", "^2END SET: " + player.Origin);
                endx = player.Origin.X;
                endy = player.Origin.Y;
                endz = player.Origin.Z;
                creating = false;
                File.AppendAllText("scripts\\maps\\" + mapname + ".txt", Environment.NewLine + "HiddenTP: (" + startx + "," + starty + "," + startz + ") ; (" + endx + "," + endy + "," + endz + ")");
            }

            if (msg[0] == "!floor" && !creating)
            {
                player.Call("iprintlnbold", "^2START SET: " + player.Origin);
                startx = player.Origin.X;
                starty = player.Origin.Y;
                startz = player.Origin.Z;
                creating = true;
            }
            else if (msg[0] == "!floor" && creating)
            {
                player.Call("iprintlnbold", "^2END SET: " + player.Origin);
                endx = player.Origin.X;
                endy = player.Origin.Y;
                endz = player.Origin.Z;
                creating = false;
                File.AppendAllText("scripts\\maps\\" + mapname + ".txt", Environment.NewLine + "floor: (" + startx + "," + starty + "," + startz + ") ; (" + endx + "," + endy + "," + endz + ")");
            }

        }
    }
}

Please help me Tongue
Reply

#2
You can't make the damn MapEdit that we created for TeknoShit as the API's are different plus IW5M contains the Script coding in the dll, not in infinityscript kbai

Actually that's some other leechers work who got our old source and made his own l0l
Do not take life too seriously. You will never get out of it alive.
[Image: UGPjFJa.jpg]
Reply

#3
then I can not modify a plugin that is iw5m to work in teknomw3 ??
Reply

#4
This isnt a forum for either of those versions of MW3. My suggestion is that you should ask on those sites for help regarding non retail versions of MW3. This forum is for the retail (legal and legit) version of MW3.
Reply

#5
(10-19-2013, 00:44)maverigh Wrote: then I can not modify a plugin that is iw5m to work in teknomw3 ??
Obviously not, now screw off with your shitty crack.



inb4shitty4d1commentsby@sailrmoon
Do not take life too seriously. You will never get out of it alive.
[Image: UGPjFJa.jpg]
Reply

#6
Don't listen to idiots like @DidUknowiPwn .
And it is not supported.. ( maybe it isn't even possible ).
C++/Obj-Cdeveloper. Neko engine wip
Steam: Click
Reply



Possibly Related Threads…
Thread Author Replies Views Last Post
Wink Plugin with !ban !kick and !tampban clemi555 3 4,161 11-09-2013, 09:21
Last Post: clemi555
  AntiNoScope Plugin clemi555 5 4,741 11-08-2013, 19:13
Last Post: clemi555
  [Release] Bunker Plugin 1.3 archit 68 41,483 10-30-2013, 11:59
Last Post: clacki
Shocked [Request] Switch plugin axel-le-meilleur 6 5,170 10-19-2013, 06:59
Last Post: iRoNinja
  [Release] Yurio Map Plugin Yurio 101 62,183 09-26-2013, 13:38
Last Post: First_Semyon
Brick [Release] v1.1 ChangeMap/NextMap Plugin without any configuration milchshake 23 18,618 09-23-2013, 13:18
Last Post: SgtLegend
  Help !say Plugin (like the !say from GodPlugin) Hallla 0 2,709 09-13-2013, 09:31
Last Post: Hallla
Rainbow [Release] MW3: Random Weapon Plugin V1 Nekochan 50 33,253 09-11-2013, 15:11
Last Post: EnVi Sweden Rocks
  Search Plugin Fluid Killcam N3xT_974 1 3,063 09-10-2013, 20:27
Last Post: Nekochan
  [Release] AntiCamp Plugin zxz0O0 34 29,269 09-07-2013, 22:34
Last Post: axel-le-meilleur

Forum Jump:


Users browsing this thread:
4 Guest(s)

Forum Powered By MyBB, Theme by © 2002-2024 Melroy van den Berg.