Jump to content
  • 0

Question

13 answers to this question

Recommended Posts

  • 0
Posted (edited)

hello there can you give me code for make my server when someone death and when they press to vilage to go my location where i set.

Give a try here...

 

network/clientpackets/RequestRestartPoint.java

                            loc = new Location(17836, 170178, -3507);// Floran Village
                            break;
                        }
-                        loc = MapRegionTable.getInstance().getTeleToLocation(activeChar, MapRegionTable.TeleportWhereType.Town);
-                            break;
-                        }
+                        if (Config.CUSTOM_RESPAWN)
+                            loc = new Location(Config.CSPAWN_X, Config.CSPAWN_Y, Config.CSPAWN_Z);
+                        else
+                            loc = MapRegionTable.getInstance().getTeleToLocation(activeChar, MapRegionTable.TeleportWhereType.Town);
+                        break;
+                }

Config.java

    public static boolean CUSTOM_RESPAWN;
    public static int CSPAWN_X;
    public static int CSPAWN_Y;
    public static int CSPAWN_Z;
 
        CUSTOM_RESPAWN = Boolean.parseBoolean(altSettings.getProperty("RespawnAfterDeath", "false"));
        CSPAWN_X = Double.parseDouble(altSettings.getProperty("SpawnX", "your choose"));
        CSPAWN_Y = Double.parseDouble(altSettings.getProperty("SpawnY", "your choose"));
        CSPAWN_Z = Double.parseDouble(altSettings.getProperty("SpawnZ", "your choose"));

config.property

# Custom Respawn When You Die.
RespawnAfterDeath = false
SpawnX = your choose
SpawnY = your choose
SpawnZ = your choose
Edited by 'Baggos'
  • 0
Posted (edited)

clientpackets/requestrestartpoint.java

 

check the 'default' value, in _requestedpointtype switch method.

Edited by Klay
  • 0
Posted

i dont understand you can you give me code to add or remove 

i try this http://www.maxcheaters.com/topic/180110-respawn-location-after-death/ butits not working

that's what i'm talking about..

 

you probably put that in different case,because it seems fine to me.

  • 0
Posted

 

Give a try here...

 

network/clientpackets/RequestRestartPoint.java

                            loc = new Location(17836, 170178, -3507);// Floran Village
                            break;
                        }
-                        loc = MapRegionTable.getInstance().getTeleToLocation(activeChar, MapRegionTable.TeleportWhereType.Town);
-                            break;
-                        }
+                        if (Config.CUSTOM_RESPAWN)
+                        {
+                            loc = new Location(Config.CSPAWN_X, Config.CSPAWN_Y, Config.CSPAWN_Z);
+                            break;
+                        }
+                }

Config.java

    public static boolean CUSTOM_RESPAWN;
    public static int CSPAWN_X;
    public static int CSPAWN_Y;
    public static int CSPAWN_Z;
 
        CUSTOM_RESPAWN = Boolean.parseBoolean(altSettings.getProperty("RespawnAfterDeath", "false"));
        CSPAWN_X = Double.parseDouble(altSettings.getProperty("SpawnX", "your choose"));
        CSPAWN_Y = Double.parseDouble(altSettings.getProperty("SpawnY", "your choose"));
        CSPAWN_Z = Double.parseDouble(altSettings.getProperty("SpawnZ", "your choose"));

config.property

# Custom Respawn When You Die.
RespawnAfterDeath = false
SpawnX = your choose
SpawnY = your choose
SpawnZ = your choose

that's totally wrong,

what if someone set this config as false?

 

NPE.

 

it needs to be like

 

if (Config.CUSTOM_RESPAWN)
+                            loc = new Location(Config.CSPAWN_X, Config.CSPAWN_Y, Config.CSPAWN_Z);
+else
+                             loc = MapRegionTable.getInstance().getTeleToLocation(activeChar, MapRegionTable.TeleportWhereType.Town);
+
+       break;

 

plus,the code author posted above its correct,but he probably put it in another case,as I said.

  • 0
Posted (edited)

well thank you but i dont understand where to put this where is this files Config.java and config.property

 public static boolean CUSTOM_RESPAWN;
    public static int CSPAWN_X;
    public static int CSPAWN_Y;
    public static int CSPAWN_Z;
 
        CUSTOM_RESPAWN = Boolean.parseBoolean(altSettings.getProperty("RespawnAfterDeath", "false"));
        CSPAWN_X = Double.parseDouble(altSettings.getProperty("SpawnX", "your choose"));
        CSPAWN_Y = Double.parseDouble(altSettings.getProperty("SpawnY", "your choose"));
        CSPAWN_Z = Double.parseDouble(altSettings.getProperty("SpawnZ", "your choose"));

and this

# Custom Respawn When You Die.
RespawnAfterDeath = false
SpawnX = your choose
SpawnY = your choose
SpawnZ = your choose
Edited by haskovo
  • 0
Posted (edited)

Everywhere you want...

Juts change later the "altsettings" if you add the code in another property..

 

or under from 

    public static boolean ALT_PETS_STATS_BONUS;
+    public static boolean CUSTOM_RESPAWN;
+    public static int CSPAWN_X;
+    public static int CSPAWN_Y;
+    public static int CSPAWN_Z;
 
            ALT_PETS_STATS_BONUS = Boolean.parseBoolean(altSettings.getProperty("AltPetsStatsBonus", "True"));
+            CUSTOM_RESPAWN = Boolean.parseBoolean(altSettings.getProperty("RespawnAfterDeath", "false"));
+            CSPAWN_X = Double.parseDouble(altSettings.getProperty("SpawnX", "your choose"));
+            CSPAWN_Y = Double.parseDouble(altSettings.getProperty("SpawnY", "your choose"));
+            CSPAWN_Z = Double.parseDouble(altSettings.getProperty("SpawnZ", "your choose"));

Don't forget to change the "your choose"

 

altsettings.property

AltPetsStatsBonus = True
+
+# Custom Respawn When You Die.
+RespawnAfterDeath = false
+SpawnX = your choose
+SpawnY = your choose
+SpawnZ = your choose

Don't forget to change the "your choose"

Edited by 'Baggos'
  • 0
Posted

Put this

 

            CSPAWN_X = Integer.parseInt(altSettings.getProperty("SpawnX", "your choose"));
            CSPAWN_Y = Integer.parseInt(altSettings.getProperty("SpawnY", "your choose"));
            CSPAWN_Z = Integer.parseInt(altSettings.getProperty("SpawnZ", "your choose"));

and don't forget to change the "your choose".

Guest
This topic is now closed to further replies.


  • Posts

    • just with this extender that I have shared it is not possible to start with c4 client, you have to make some changes to the extender and it works with c4 client perfectly. regarding the updates in this last revision   🔹dll is not packaged with vmprotect   New custom zone types have been added: 🔹 NO_NOBLESS begin MinX=84638 MaxX=92616 MinY=-87170 MaxY=-82018 MinZ=-6000 MaxZ=0 Type=NO_NOBLESS KickOutPos=83007/148057/-3464 end   ▶️ This zone checks if the character is noble. If it does not meet the condition, it will be automatically kicked to the indicated position (KickOutPos). 🔹 CUSTOM_SPAWN_ZONE begin MinX=77275 MaxX=85704 MinY=10122 MaxY=18066 MinZ=-8000 MaxZ=5000 Type=CUSTOM_SPAWN_ZONE OutPos=83007/148057/-3464 Spawns={{82984/18066/-5256}};{{79275/15147/-5248}};{{82922/14263/-5256}};{{83704/10122/-5288}} end ▶️ This zone allows characters, upon death, to respawn with full buff, CP, HP and MP if they press “Fixed”. They will only be able to revive in one of the positions defined in Spawns. 🔧 Both zones are fully configurable from territorydata.txt
    • Could you tell me what changed in this update?   more one question: Is it possible to log in through the c4 client instead of interlude? That would be great  
    • ➡ Discount for your purchase: JULY2025 (11% discount) ➡ Our Online Shop: https://socnet.store  ➡ Our SMM-Boosting Panel: https://socnet.pro  ➡ Telegram Shop Bot: https://socnet.shop  ➡ Telegram Support: https://t.me/solomon_bog  ➡ Telegram Channel: https://t.me/accsforyou_shop  ➡ Discord Support: @AllSocialNetworksShop  ➡ Discord Server: https://discord.gg/y9AStFFsrh  ➡ WhatsApp Support: https://wa.me/79051904467 ➡ WhatsApp Channel: https://whatsapp.com/channel/0029Vau0CMX002TGkD4uHa2n  ➡ Email Support: solomonbog@socnet.store 
    • ➡ Discount for your purchase: JULY2025 (11% discount) ➡ Our Online Shop: https://socnet.store  ➡ Our SMM-Boosting Panel: https://socnet.pro  ➡ Telegram Shop Bot: https://socnet.shop  ➡ Telegram Support: https://t.me/solomon_bog  ➡ Telegram Channel: https://t.me/accsforyou_shop  ➡ Discord Support: @AllSocialNetworksShop  ➡ Discord Server: https://discord.gg/y9AStFFsrh  ➡ WhatsApp Support: https://wa.me/79051904467 ➡ WhatsApp Channel: https://whatsapp.com/channel/0029Vau0CMX002TGkD4uHa2n  ➡ Email Support: solomonbog@socnet.store 
  • Topics

×
×
  • Create New...

AdBlock Extension Detected!

Our website is made possible by displaying online advertisements to our members.

Please disable AdBlock browser extension first, to be able to use our community.

I've Disabled AdBlock